A new request with request id 7026 has been created by koha-devel-request@lists.koha-community.org. Short info on the request is :

Title : Koha-devel Digest, Vol 205, Issue 16
Category :
Description :
Send Koha-devel mailing list submissions to
    koha-devel@lists.koha-community.org

To subscribe or unsubscribe via the World Wide Web, visit
    https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel
or, via email, send a message with subject or body 'help' to
    koha-devel-request@lists.koha-community.org

You can reach the person managing the list at
    koha-devel-owner@lists.koha-community.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Koha-devel digest..."


Today's Topics:

1. What's the definitive way to use Perl tidy in
koha-testing-docker? (David Cook)
2. MySQL/MariaDB index prefix length (David Cook)


----------------------------------------------------------------------

Message: 1
Date: Fri, 9 Dec 2022 14:26:54 +1100
From: "David Cook" <dcook@prosentient.com.au>
To: "'koha-devel'" <koha-devel@lists.koha-community.org>
Subject: [Koha-devel] What's the definitive way to use Perl tidy in
    koha-testing-docker?
Message-ID: <001a01d90b7e$17e4dd80$47ae9880$@prosentient.com.au>
Content-Type: text/plain; charset="utf-8"

Hi all,



I've heard a few people saying lately that they wish people would use Perl
tidy more.



So I used the ":Tidy" command in koha-testing-docker on my visual selection
and I got the following:



+ $this_item->{shelves} =

+ Koha::Virtualshelves->get_shelves_containing_record(

+ {

+ biblionumber => $biblionumber,

+ borrowernumber => $loggedinuser,

+ }

+ );



But that goes against the Indentation coding guidelines from
https://wiki.koha-community.org/wiki/Coding_Guidelines#Indentation



So. what are we supposed to be doing these days?



David Cook

Senior Software Engineer

Prosentient Systems

Suite 7.03

6a Glen St

Milsons Point NSW 2061

Australia



Office: 02 9212 0899

Online: 02 8005 0595



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.koha-community.org/pipermail/koha-devel/attachments/20221209/8d4d428f/attachment-0001.htm>

------------------------------

Message: 2
Date: Fri, 9 Dec 2022 17:25:41 +1100
From: "David Cook" <dcook@prosentient.com.au>
To: "'koha-devel'" <koha-devel@lists.koha-community.org>
Subject: [Koha-devel] MySQL/MariaDB index prefix length
Message-ID: <002701d90b97$11303700$3390a500$@prosentient.com.au>
Content-Type: text/plain; charset="utf-8"

Hi all,



We often create indexes with a prefix length of 191 because we use 4 byte
encoded fields. 191 * 4 = 764, which comes in under the prefix index length
threshold of 767.



But that looks like a limit that was imposed due to the COMPACT row format.
Most newer MySQL/MariaDB databases will be using the DYNAMIC row format,
which can support an index key prefix limit of 3072 bytes (or 768 4-byte
encoded characters).



On Bugzilla, there have been times where I've speculated that maybe it's the
sysadmin's job to update the database row format, but perhaps we should take
a more proactive effort to move row format from COMPACT to DYNAMIC, so that
we can more systematically take advantage of longer index prefixes.



I often think about how to index URLs, since the maximum length of URLs are
very large. Web browsers hover around the 2000 character mark while web
servers can be much higher than that. Of course, even with 3072 bytes, that
still wouldn't be enough for a full URL. But it would get a person a lot
farther than 191 characters.



David Cook

Senior Software Engineer

Prosentient Systems

Suite 7.03

6a Glen St

Milsons Point NSW 2061

Australia



Office: 02 9212 0899

Online: 02 8005 0595



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.koha-community.org/pipermail/koha-devel/attachments/20221209/41966a53/attachment-0001.htm>

------------------------------

Subject: Digest Footer

_______________________________________________
Koha-devel mailing list
Koha-devel@lists.koha-community.org
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel
website : https://www.koha-community.org/
git : https://git.koha-community.org/
bugs : https://bugs.koha-community.org/


------------------------------

End of Koha-devel Digest, Vol 205, Issue 16
*******************************************


NOTE: You are receiving this mail because, the Requester/Technician wanted you to get notified on this request creation.