Bugzilla – Attachment 74607 Details for
Bug 18342
Set memcached as 'enabled' by default
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18342: Enable memcached by default for new installs
Bug-18342-Enable-memcached-by-default-for-new-inst.patch (text/plain), 6.43 KB, created by
Kyle M Hall (khall)
on 2018-04-20 10:19:40 UTC
(
hide
)
Description:
Bug 18342: Enable memcached by default for new installs
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2018-04-20 10:19:40 UTC
Size:
6.43 KB
patch
obsolete
>From e3851111e82cd1118289a4339ef5687095337054 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Wed, 27 Sep 2017 16:19:07 -0300 >Subject: [PATCH] Bug 18342: Enable memcached by default for new installs > >Note that there is no way to create an install without memcached. >As it is now considered as stable, there is no point to not use it. > >Test plan: >Create a new Koha install and make sure memcached is enabled by default > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > Makefile.PL | 2 +- > debian/docs/koha-create.xml | 15 --------------- > debian/scripts/koha-create | 27 +++------------------------ > debian/templates/koha-sites.conf | 4 ++-- > rewrite-config.PL | 2 +- > 5 files changed, 7 insertions(+), 43 deletions(-) > >diff --git a/Makefile.PL b/Makefile.PL >index ecd4297460..0068424a9d 100644 >--- a/Makefile.PL >+++ b/Makefile.PL >@@ -483,7 +483,7 @@ my %config_defaults = ( > 'PAZPAR2_PORT' => '11002', > 'RUN_DATABASE_TESTS' => 'no', > 'PATH_TO_ZEBRA' => '', >- 'USE_MEMCACHED' => 'no', >+ 'USE_MEMCACHED' => 'yes', > 'MEMCACHED_SERVERS' => '127.0.0.1:11211', > 'MEMCACHED_NAMESPACE' => 'KOHA', > 'TEMPLATE_CACHE_DIR' => '/tmp/koha', >diff --git a/debian/docs/koha-create.xml b/debian/docs/koha-create.xml >index 632140d471..d4bbadb40d 100644 >--- a/debian/docs/koha-create.xml >+++ b/debian/docs/koha-create.xml >@@ -29,7 +29,6 @@ > <arg><option>--zebralang</option> en|es|fr|gr|nb|ru|uk</arg> > <arg><option>--auth-idx</option> dom|grs1</arg> > <arg><option>--biblio-idx</option> dom|grs1</arg> >- <arg><option>--use-memcached</option></arg> > <arg><option>--memcached-servers</option> server:port</arg> > <arg><option>--memcached-prefix</option> namespace_prefix</arg> > <arg><option>--defaultsql</option> /path/to/some.sql</arg> >@@ -150,13 +149,6 @@ > </listitem> > </varlistentry> > >- <varlistentry> >- <term><option>--use-memcached</option></term> >- <listitem> >- <para>Make the Koha instance use memcached. <option>Disabled by default</option>.</para> >- </listitem> >- </varlistentry> >- > <varlistentry> > <term><option>--memcached-servers</option></term> > <listitem> >@@ -286,13 +278,6 @@ > </listitem> > </varlistentry> > >- <varlistentry> >- <term><option>USE_MEMCACHED</option></term> >- <listitem> >- <para>Valid values are <option>yes</option> and <option>no</option>. If not present koha-create will default to <option>no</option>. Also, this will be overriden by the <option>--use-memcached</option> switch.</para> >- </listitem> >- </varlistentry> >- > <varlistentry> > <term><option>MEMCACHED_SERVERS</option></term> > <listitem> >diff --git a/debian/scripts/koha-create b/debian/scripts/koha-create >index cdfa63d813..e0fd5cdd77 100755 >--- a/debian/scripts/koha-create >+++ b/debian/scripts/koha-create >@@ -57,7 +57,6 @@ Options: > values are dom (default) and grs1. > --biblio-idx idx_mode Set the indexing mode for bibliographic records. > Valid values are dom (default) and grs1. >- --use-memcached Set the instance to make use of memcache. > --memcached-servers str Set a comma-separated list of host:port memcached servers. > --memcached-prefix str Set the desired prefix for the instance memcached namespace. > --enable-sru Enable the Z39.50/SRU server (default: disabled). >@@ -404,7 +403,7 @@ ADMINUSER="1" > PASSWDFILE="/etc/koha/passwd" > > # memcached variables >-USE_MEMCACHED="no" >+USE_MEMCACHED="yes" > MEMCACHED_SERVERS="" > MEMCACHED_PREFIX="" > # hardcoded memcached defaults >@@ -444,7 +443,7 @@ fi > > [ $# -ge 1 ] && [ $# -le 16 ] || ( usage ; die "Error: wrong parameters" ) > >-TEMP=`getopt -o chrpm:l:d:f:b:a: -l create-db,request-db,populate-db,use-db,use-memcached,enable-sru,sru-port:,help,marcflavor:,auth-idx:,biblio-idx:,zebralang:,defaultsql:,configfile:,passwdfile:,dbhost:,database:,adminuser:,memcached-servers:,memcached-prefix:,template-cache-dir:,upload-path:,letsencrypt, \ >+TEMP=`getopt -o chrpm:l:d:f:b:a: -l create-db,request-db,populate-db,use-db,enable-sru,sru-port:,help,marcflavor:,auth-idx:,biblio-idx:,zebralang:,defaultsql:,configfile:,passwdfile:,dbhost:,database:,adminuser:,memcached-servers:,memcached-prefix:,template-cache-dir:,upload-path:,letsencrypt, \ > -n "$0" -- "$@"` > > # Note the quotes around `$TEMP': they are essential! >@@ -473,8 +472,6 @@ while true ; do > op=populate ; shift ;; > -u|--use-db) > op=use ; shift ;; >- --use-memcached) >- USE_MEMCACHED="yes" ; shift ;; > --memcached-servers) > CLO_MEMCACHED_SERVERS="$2" ; shift 2 ;; > --memcached-prefix) >@@ -586,25 +583,7 @@ NO_DB > die; > fi > >-if [ "$USE_MEMCACHED" = "yes" ]; then >- set_memcached $name >-elif [ "$CLO_MEMCACHED_SERVERS" != "" ] || \ >- [ "$CLO_MEMCACHED_PREFIX" != "" ]; then >- >- MSG=`cat <<EOF >- >-Error: you provided memcached configuration switches but memcached is not enabled. >-Please set USE_MEMCACHED="yes" on /etc/koha/koha-sites.conf or use the >---use-memcached option switch to enable it. >- >-EOF` >- >- usage ; die $MSG >-else >- # Unset memcached-related variables >- MEMCACHED_SERVERS="" >- MEMCACHED_PREFIX="" >-fi >+set_memcached $name > > # Set template cache dir > if [ "$CLO_TEMPLATE_CACHE_DIR" != "" ]; then >diff --git a/debian/templates/koha-sites.conf b/debian/templates/koha-sites.conf >index c954a0495c..863accbcfd 100644 >--- a/debian/templates/koha-sites.conf >+++ b/debian/templates/koha-sites.conf >@@ -46,8 +46,8 @@ AUTHORITIES_INDEXING_MODE="dom" > # > # USE_MEMCACHED: 'yes' | 'no' > # Make the created instance use memcached. Can be altered later. >-# default: 'no' >-USE_MEMCACHED="no" >+# default: 'yes' >+USE_MEMCACHED="yes" > > # MEMCACHED_SERVERS: comma separated list of memcached servers (ip:port) > # Specify a list of memcached servers for the Koha instance >diff --git a/rewrite-config.PL b/rewrite-config.PL >index 5366493a18..d2f974b971 100644 >--- a/rewrite-config.PL >+++ b/rewrite-config.PL >@@ -149,7 +149,7 @@ $prefix = $ENV{'INSTALL_BASE'} || "/usr"; > "__BIB_INDEX_MODE__" => 'grs1', > "__RUN_DATABASE_TESTS__" => 'no', > "__PATH_TO_ZEBRA__" => "", >- "__USE_MEMCACHED__" => 'no', >+ "__USE_MEMCACHED__" => 'yes', > "__MEMCACHED_SERVERS__" => "", > "__MEMCACHED_NAMESPACE__" => "", > "__FONT_DIR__" => "/usr/share/fonts/truetype/ttf-dejavu", >-- >2.15.1 (Apple Git-101)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18342
:
67414
|
73216
|
73217
|
74607
|
74608
|
74904
|
74905