( ! ) Deprecated: Function WP_Dependencies-&gt;add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers. in /var/www/html/wp-includes/functions.php on line 6131
Call Stack
#TimeMemoryFunctionLocation
10.0000484224{main}( ).../index.php:0
20.0005484576require( '/var/www/html/wp-blog-header.php ).../index.php:17
30.27314111072require_once( '/var/www/html/wp-includes/template-loader.php ).../wp-blog-header.php:19
40.27974140176include( '/var/www/html/wp-content/themes/twentyfifteen/archive.php ).../template-loader.php:125
50.27974140176get_header( $name = ???, $args = ??? ).../archive.php:19
60.27974140392locate_template( $template_names = [0 => 'header.php'], $load = TRUE, $load_once = TRUE, $args = [] ).../general-template.php:48
70.27974140488load_template( $_template_file = '/var/www/html/wp-content/themes/twentyfifteen/header.php', $load_once = TRUE, $args = [] ).../template.php:749
80.28014141032require_once( '/var/www/html/wp-content/themes/twentyfifteen/header.php ).../template.php:814
90.28034148440wp_head( ).../header.php:18
100.28034148440do_action( $hook_name = 'wp_head' ).../general-template.php:3197
110.28034148656WP_Hook->do_action( $args = [0 => ''] ).../plugin.php:522
120.28034148656WP_Hook->apply_filters( $value = '', $args = [0 => ''] ).../class-wp-hook.php:365
130.28064152072wp_enqueue_scripts( '' ).../class-wp-hook.php:341
140.28064152072do_action( $hook_name = 'wp_enqueue_scripts' ).../script-loader.php:2311
150.28064152288WP_Hook->do_action( $args = [0 => ''] ).../plugin.php:522
160.28064152288WP_Hook->apply_filters( $value = '', $args = [0 => ''] ).../class-wp-hook.php:365
170.28084278592twentyfifteen_scripts( '' ).../class-wp-hook.php:341
180.28114280112wp_style_add_data( $handle = 'twentyfifteen-ie', $key = 'conditional', $value = 'lt IE 9' ).../functions.php:440
190.28114280112WP_Styles->add_data( $handle = 'twentyfifteen-ie', $key = 'conditional', $value = 'lt IE 9' ).../functions.wp-styles.php:245
200.28114280112WP_Dependencies->add_data( $handle = 'twentyfifteen-ie', $key = 'conditional', $value = 'lt IE 9' ).../class-wp-styles.php:385
210.28114280112_deprecated_argument( $function_name = 'WP_Dependencies->add_data()', $version = '6.9.0', $message = 'IE conditional comments are ignored by all supported browsers.' ).../class-wp-dependencies.php:317
220.28114280432wp_trigger_error( $function_name = '', $message = 'Function WP_Dependencies->add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers.', $error_level = 16384 ).../functions.php:5925
230.28124281184trigger_error( $message = 'Function WP_Dependencies-&gt;add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers.', $error_level = 16384 ).../functions.php:6131

( ! ) Deprecated: Function WP_Dependencies-&gt;add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers. in /var/www/html/wp-includes/functions.php on line 6131
Call Stack
#TimeMemoryFunctionLocation
10.0000484224{main}( ).../index.php:0
20.0005484576require( '/var/www/html/wp-blog-header.php ).../index.php:17
30.27314111072require_once( '/var/www/html/wp-includes/template-loader.php ).../wp-blog-header.php:19
40.27974140176include( '/var/www/html/wp-content/themes/twentyfifteen/archive.php ).../template-loader.php:125
50.27974140176get_header( $name = ???, $args = ??? ).../archive.php:19
60.27974140392locate_template( $template_names = [0 => 'header.php'], $load = TRUE, $load_once = TRUE, $args = [] ).../general-template.php:48
70.27974140488load_template( $_template_file = '/var/www/html/wp-content/themes/twentyfifteen/header.php', $load_once = TRUE, $args = [] ).../template.php:749
80.28014141032require_once( '/var/www/html/wp-content/themes/twentyfifteen/header.php ).../template.php:814
90.28034148440wp_head( ).../header.php:18
100.28034148440do_action( $hook_name = 'wp_head' ).../general-template.php:3197
110.28034148656WP_Hook->do_action( $args = [0 => ''] ).../plugin.php:522
120.28034148656WP_Hook->apply_filters( $value = '', $args = [0 => ''] ).../class-wp-hook.php:365
130.28064152072wp_enqueue_scripts( '' ).../class-wp-hook.php:341
140.28064152072do_action( $hook_name = 'wp_enqueue_scripts' ).../script-loader.php:2311
150.28064152288WP_Hook->do_action( $args = [0 => ''] ).../plugin.php:522
160.28064152288WP_Hook->apply_filters( $value = '', $args = [0 => ''] ).../class-wp-hook.php:365
170.28084278592twentyfifteen_scripts( '' ).../class-wp-hook.php:341
180.30804282288wp_style_add_data( $handle = 'twentyfifteen-ie7', $key = 'conditional', $value = 'lt IE 8' ).../functions.php:444
190.30804282288WP_Styles->add_data( $handle = 'twentyfifteen-ie7', $key = 'conditional', $value = 'lt IE 8' ).../functions.wp-styles.php:245
200.30804282288WP_Dependencies->add_data( $handle = 'twentyfifteen-ie7', $key = 'conditional', $value = 'lt IE 8' ).../class-wp-styles.php:385
210.30804282288_deprecated_argument( $function_name = 'WP_Dependencies->add_data()', $version = '6.9.0', $message = 'IE conditional comments are ignored by all supported browsers.' ).../class-wp-dependencies.php:317
220.30804282608wp_trigger_error( $function_name = '', $message = 'Function WP_Dependencies->add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers.', $error_level = 16384 ).../functions.php:5925
230.30814282832trigger_error( $message = 'Function WP_Dependencies-&gt;add_data() was called with an argument that is <strong>deprecated</strong> since version 6.9.0! IE conditional comments are ignored by all supported browsers.', $error_level = 16384 ).../functions.php:6131

破解resin-pro-3.1

在网上查看了很多关于resin性能的文章,比较公认的说法是resin比tomcat的性能要高很多。


但最近在csdn上看了一篇文章,说resin 3.x的免费版与tomcat性能已经不相上下了。原因有两个:


1、tomcat从5.0后就开始在性能上不断改进,以达到生产环境的要求;


2、resin从3.0开始分为免费版与pro版,更多的性能改进被放到了pro版中了,所以免费版的性能就下降了。


基于这样的一些原因,更由于resin的pro版支持session持久化存储、负载均衡及cache等高端特性,于是对破解resin pro版产生了兴趣。


经过N个夜晚的奋战,终于把这个pro版给破解了。


网上也有人说破解得不好的resin pro版可能会使性能下降,个人感觉不存在这样的问题,只要破解了即可享用pro版的各种特性,性能也有大幅提高。


以下的resin启动的部分输出:


Resin Professional 3.1.4 (built Tue, 04 Dec 2007 11:27:12 PST)
Copyright(c) 1998-2007 Caucho Technology.  All rights reserved.


Starting Resin on Mon, 31 Dec 2007 17:18:52 +0800 (CST)


[17:18:53.640] {main} Proxy Cache disk-size=1024M memory-size=64M
[17:18:53.656] {main} PingThread[] starting, checking []
[17:18:54.109] {main}
[17:18:54.234] {main} Windows XP 5.1 x86
[17:18:54.343] {main} Java 1.5.0_11-b03, 32, mixed mode, GBK, zh, Sun Microsystems Inc.
[17:18:54.468] {main} user.name: dingl
[17:18:54.593] {main} resin.home = C:\resin-pro-3.1.4
[17:18:54.718] {main} resin.root = C:\resin-pro-3.1.4
[17:18:54.828] {main} resin.conf = /D:/workspace/project/resin-3.1.conf
[17:18:54.828] {main}
[17:18:55.734] {main} WebApp[http://localhost:80] Set web app root system property: ‘webapp.root’ = [D:\workspace\project\WebContent\]
[17:18:59.515] {main} WebApp[http://localhost:80] active
[17:19:00.171] {main} WebApp[http://localhost:80/resin-doc] active
[17:19:00.390] {main} WebApp[http://localhost:80/resin-admin] active
[17:19:00.500] {main} Host[] active
[17:19:00.640] {main} Socket JNI library is not available.
[17:19:00.640] {main} Resin will still run but performance will be slower.
[17:19:00.640] {main} To compile the Socket JNI library on Unix, use ./configure; make; make install.
[17:19:00.796] {main} hmux listening to localhost:6800
[17:19:00.921] {main} http listening to *:80
[17:19:01.140] {main} Server[id=,cluster=app-tier] active
[17:19:01.281] {main} Resin started in 9547ms


 可以看到已经没有关于license的提示了,并且增加了Proxy Cache disk-size=1024M memory-size=64M的输出,说明已经使用了cache来提高性能。


 值得一提的是,要想获得更好的性能,请使用linux/unix系统,因为在windows下,默认安装的resin是不能使用JNI库的,需要手工编译。而在linux/unix下,make源码后就已经将JNI库编译好了。这个特性可以从输出中看出来:


[17:19:00.640] {main} Socket JNI library is not available.
[17:19:00.640] {main} Resin will still run but performance will be slower.


linux/unix系统中没有这样的提示。


目前本blog提供resin-pro-3.1.3版的下载,地址为:


resin-pro-3.1.3 for windows 下载


resin-pro-3.1.3 for linux/unix 下载


resin-pro-3.1.4由于目前标记为dev,暂不破解此版本。3.1.5目前正在开发,尚未发布,目前已经可以看到3.1.5的change log了。


使用ping功能使resin更健壮

由于种种原因,resin有时会遇到resin down机的情况,比如:java.lang.OutOfMemoryError。这样的问题如果从代码角度来解决问题,也不是一时半会能解决的,应急解决方案是启用resin-pro的ping功能。
    <resin:if test=”${isResinProfessional}”>
      <ping>
        <url>http://localhost:8080/ping.jsp</url>
        <sleep-time>1m</sleep-time>
        <try-count>5</try-count>
        <socket-timeout>30s</socket-timeout>
      </ping>
    </resin:if>


ping.jsp可随意写一些代码,纯html代码也行,只能服务器能响应返回200。


如果访问resin访问http://localhost:8080/ping.jsp返回不是200 code,然后再重试try-count次,如果依然不响应200,则将自动重启resin服务。


如果在resin tag下配置了:


  <system-property mail.smtp.host=”127.0.0.1″/>
  <system-property mail.smtp.port=”25″/>


还可以让resin自动给你发个邮件通知你它自动重启过了:


    <ping resin:type=”com.caucho.server.admin.PingMailer”>
      <url>http://localhost:8080/ping.jsp</url>
      <mail-to>[email protected]</mail-to>
      <mail-from>[email protected]</mail-from>
      <mail-subject>Resin ping has failed for server ${’${’}server.name}</mail-subject>
    </ping>


这样配置好了,不管resin出现什么故障,只要resin进程不死,就可以放心睡大觉了。


如果还启用了resin的session持久化存储,用户基本感觉不到服务已经重启过了。


如果启用了resin的cluster,那么请修改httpd.sh,将-server参数加上,不然重启resin后是没有cluster的。