Disabling APC with the next update
authorAlexander Ebert <ebert@woltlab.com>
Sat, 21 Dec 2013 12:11:54 +0000 (13:11 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Sat, 21 Dec 2013 12:11:54 +0000 (13:11 +0100)
com.woltlab.wcf/option.xml
wcfsetup/install/files/acp/update_2.0.0.php [deleted file]
wcfsetup/install/files/acp/update_com.woltlab.wcf_2.0.1.php [new file with mode: 0644]

index 5c419f5b03c48b1f9c73af26a18f478a2b6ed6ef..b9053f60d4bfa610e44ed32941f80b659c2c0219 100644 (file)
@@ -650,12 +650,12 @@ debug:mail_debug_logfile_path,!mail_use_f_param,!mail_smtp_host,!mail_smtp_port,
                                <defaultvalue><![CDATA[disk]]></defaultvalue>
                                <selectoptions><![CDATA[disk:wcf.acp.option.cache_source_type.disk
 memcached:wcf.acp.option.cache_source_type.memcached
-apc:wcf.acp.option.cache_source_type.apc
 no:wcf.acp.option.cache_source_type.no]]></selectoptions>
+                               <!-- apc:wcf.acp.option.cache_source_type.apc -->
                                <enableoptions><![CDATA[disk:!cache_source_memcached_host
 memcached:cache_source_memcached_host
-apc:!cache_source_memcached_host
 no:!cache_source_memcached_host]]></enableoptions>
+                               <!-- apc:!cache_source_memcached_host -->
                        </option>
                        
                        <option name="cache_source_memcached_host">
diff --git a/wcfsetup/install/files/acp/update_2.0.0.php b/wcfsetup/install/files/acp/update_2.0.0.php
deleted file mode 100644 (file)
index 17b73ea..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-<?php
-use wcf\system\WCF;
-
-/**
- * @author     Alexander Ebert
- * @copyright  2001-2013 WoltLab GmbH
- * @license    GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
- * @package    com.woltlab.wcf
- * @category   Community Framework
- */
-
-// remove log files used during Beta/RC
-@unlink(WCF_DIR.'__installPerformance.log');
-@unlink(WCF_DIR.'__wcfSetupPerformance.log');
diff --git a/wcfsetup/install/files/acp/update_com.woltlab.wcf_2.0.1.php b/wcfsetup/install/files/acp/update_com.woltlab.wcf_2.0.1.php
new file mode 100644 (file)
index 0000000..e5d9ad5
--- /dev/null
@@ -0,0 +1,21 @@
+<?php
+use wcf\system\WCF;
+/**
+ * @author     Alexander Ebert
+ * @copyright  2001-2013 WoltLab GmbH
+ * @license    GNU Lesser General Public License <http://opensource.org/licenses/lgpl-license.php>
+ * @package    com.woltlab.wcf
+ * @category   Community Framework
+ */
+
+// disable APC if applicable
+$sql = "UPDATE wcf".WCF_N."_option
+       SET     optionValue = ?
+       WHERE   optionName = ?
+               AND optionValue = ?";
+$statement = WCF::getDB()->prepareStatement($sql);
+$statement->execute(array(
+       'disk',
+       'cache_source_type',
+       'apc'
+));