You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by rj...@apache.org on 2010/10/21 20:53:42 UTC

svn commit: r1026100 - in /tomcat/jk/trunk/native: apache-1.3/mod_jk.c apache-2.0/mod_jk.c common/jk_status.c common/jk_version.h iis/jk_isapi_plugin.c netscape/jk_nsapi_plugin.c

Author: rjung
Date: Thu Oct 21 18:53:41 2010
New Revision: 1026100

URL: http://svn.apache.org/viewvc?rev=1026100&view=rev
Log:
Remove revision from JK_EXPOSED_VERSION.

New define JK_FULL_EXPOSED_VERSION contains
the revision number, but only if release
script is used. Keyword substitution doesn't
work, because svn doesn't allow to retrieve
the revision number without any decoration.

The new JK_FULL_EXPOSED_VERSION is used during
init/startup/shutdown logging, not for the short
version numbers.

Modified:
    tomcat/jk/trunk/native/apache-1.3/mod_jk.c
    tomcat/jk/trunk/native/apache-2.0/mod_jk.c
    tomcat/jk/trunk/native/common/jk_status.c
    tomcat/jk/trunk/native/common/jk_version.h
    tomcat/jk/trunk/native/iis/jk_isapi_plugin.c
    tomcat/jk/trunk/native/netscape/jk_nsapi_plugin.c

Modified: tomcat/jk/trunk/native/apache-1.3/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-1.3/mod_jk.c?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/apache-1.3/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-1.3/mod_jk.c Thu Oct 21 18:53:41 2010
@@ -2902,7 +2902,7 @@ static void jk_init(server_rec * s, ap_p
 #endif
         jk_log(conf->log, JK_LOG_INFO,
                "%s initialized",
-               JK_EXPOSED_VERSION);
+               JK_FULL_EXPOSED_VERSION);
     }
     else {
         jk_error_exit(APLOG_MARK, APLOG_EMERG | APLOG_NOERRNO, s, p,

Modified: tomcat/jk/trunk/native/apache-2.0/mod_jk.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-2.0/mod_jk.c?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-2.0/mod_jk.c Thu Oct 21 18:53:41 2010
@@ -3079,7 +3079,7 @@ static void jk_child_init(apr_pool_t * p
                jk_shm_name(), rc);
 
     if (JK_IS_DEBUG_LEVEL(conf->log))
-        jk_log(conf->log, JK_LOG_DEBUG, "Initialized %s", JK_EXPOSED_VERSION);
+        jk_log(conf->log, JK_LOG_DEBUG, "Initialized %s", JK_FULL_EXPOSED_VERSION);
     JK_TRACE_EXIT(conf->log);
 }
 
@@ -3197,7 +3197,7 @@ static int init_jk(apr_pool_t * pconf, j
         ap_add_version_component(pconf, JK_EXPOSED_VERSION);
         jk_log(conf->log, JK_LOG_INFO,
                "%s initialized",
-               JK_EXPOSED_VERSION);
+               JK_FULL_EXPOSED_VERSION);
     }
     else {
         ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s,

Modified: tomcat/jk/trunk/native/common/jk_status.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/common/jk_status.c?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/common/jk_status.c (original)
+++ tomcat/jk/trunk/native/common/jk_status.c Thu Oct 21 18:53:41 2010
@@ -4682,7 +4682,7 @@ static int JK_METHOD service(jk_endpoint
                     }
                     jk_print_xml_start_elt(s, w, 0, 0, "software");
                     jk_print_xml_att_string(s, 2, "web_server", s->server_software);
-                    jk_print_xml_att_string(s, 2, "jk_version", JK_EXPOSED_VERSION);
+                    jk_print_xml_att_string(s, 2, "jk_version", JK_FULL_EXPOSED_VERSION);
                     jk_print_xml_stop_elt(s, 0, 1);
                 }
                 if (cmd == JK_STATUS_CMD_LIST) {
@@ -4713,7 +4713,7 @@ static int JK_METHOD service(jk_endpoint
                     }
                     jk_puts(s, "Software:");
                     jk_printf(s, " web_server=\"%s\"", s->server_software);
-                    jk_printf(s, " jk_version=%s", JK_EXPOSED_VERSION);
+                    jk_printf(s, " jk_version=%s", JK_FULL_EXPOSED_VERSION);
                     jk_puts(s, "\n");
                 }
                 if (cmd == JK_STATUS_CMD_LIST) {
@@ -4739,7 +4739,7 @@ static int JK_METHOD service(jk_endpoint
                         jk_print_prop_att_long(s, w, NULL, "time_unix", unix_seconds);
                     }
                     jk_print_prop_att_string(s, w, NULL, "web_server", s->server_software);
-                    jk_print_prop_att_string(s, w, NULL, "jk_version", JK_EXPOSED_VERSION);
+                    jk_print_prop_att_string(s, w, NULL, "jk_version", JK_FULL_EXPOSED_VERSION);
                 }
                 if (cmd == JK_STATUS_CMD_LIST) {
                     /* Step 2: Display configuration */
@@ -4780,7 +4780,7 @@ static int JK_METHOD service(jk_endpoint
                     }
                     jk_puts(s, "</td></tr>\n");
                     jk_putv(s, "<tr><td>JK Version:</td><td>",
-                            JK_EXPOSED_VERSION, "</td><td></td><td>", NULL);
+                            JK_FULL_EXPOSED_VERSION, "</td><td></td><td>", NULL);
                     jk_printf(s, "Unix Seconds:</td><td>%d", unix_seconds);
                     jk_puts(s, "</td></tr></table>\n<hr/>\n");
                 }

Modified: tomcat/jk/trunk/native/common/jk_version.h
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/common/jk_version.h?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/common/jk_version.h (original)
+++ tomcat/jk/trunk/native/common/jk_version.h Thu Oct 21 18:53:41 2010
@@ -37,7 +37,7 @@
 #define JK_VERRC        0
 #define JK_RCSTRING     "0"
 /* Source Control Revision as a suffix, e.g. "-r12345" */
-#define JK_REVISION "$Revision$"
+#define JK_REVISION ""
 
 /************** END OF AREA TO MODIFY BEFORE RELEASING *************/
 
@@ -65,11 +65,12 @@
 #if (JK_VERRC != 0)
 #define JK_EXPOSED_VERSION JK_EXPOSED_VERSION_INT "-rc-" JK_RCSTRING
 #elif (JK_VERISRELEASE == 1)
-#define JK_EXPOSED_VERSION JK_EXPOSED_VERSION_INT JK_REVISION
+#define JK_EXPOSED_VERSION JK_EXPOSED_VERSION_INT
 #else
 #define JK_EXPOSED_VERSION JK_EXPOSED_VERSION_INT "-dev" JK_REVISION
 #endif
 #endif
+#define JK_FULL_EXPOSED_VERSION JK_EXPOSED_VERSION JK_REVISION
 
 #define JK_MAKEVERSION(major, minor, fix, beta) \
             (((major) << 24) + ((minor) << 16) + ((fix) << 8) + (beta))

Modified: tomcat/jk/trunk/native/iis/jk_isapi_plugin.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/iis/jk_isapi_plugin.c?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/iis/jk_isapi_plugin.c (original)
+++ tomcat/jk/trunk/native/iis/jk_isapi_plugin.c Thu Oct 21 18:53:41 2010
@@ -52,6 +52,7 @@
 #include <strsafe.h>
 
 #define VERSION_STRING "Jakarta/ISAPI/" JK_EXPOSED_VERSION
+#define FULL_VERSION_STRING "Jakarta/ISAPI/" JK_FULL_EXPOSED_VERSION
 #define SHM_DEF_NAME   "JKISAPISHMEM"
 #define DEFAULT_WORKER_NAME ("ajp13")
 
@@ -202,7 +203,7 @@ char HTML_ERROR_HEAD[] =        "<!--\n"
 #define HTML_ERROR_BODY_FMT     "<TITLE>%s!</TITLE>\n</HEAD>\n<BODY>\n<H1>%s!</H1>\n<P>\n%s\n</P>\n"
 
 char HTML_ERROR_TAIL[] =        "<P>\n<BR/>&nbsp;<BR/>&nbsp;<BR/>&nbsp;<BR/>&nbsp;\n"
-                                VERSION_STRING "\n"
+                                FULL_VERSION_STRING "\n"
                                 "<BR/>&nbsp;\n"
                                 "<HR/>\n"
                                 "<P id=\"footer\">\n"
@@ -2267,7 +2268,7 @@ BOOL WINAPI TerminateFilter(DWORD dwFlag
 
     JK_ENTER_CS(&(init_cs), rc);
     if (is_inited) {
-        jk_log(logger, JK_LOG_INFO, "%s stopping", (VERSION_STRING));
+        jk_log(logger, JK_LOG_INFO, "%s stopping", (FULL_VERSION_STRING));
         is_inited = JK_FALSE;
         watchdog_interval = 0;
         if (watchdog_handle) {
@@ -2558,7 +2559,7 @@ static int init_jk(char *serverName)
 
     StringCbCopy(shm_name, MAX_PATH, SHM_DEF_NAME);
 
-    jk_log(logger, JK_LOG_INFO, "Starting %s", (VERSION_STRING));
+    jk_log(logger, JK_LOG_INFO, "Starting %s", (FULL_VERSION_STRING));
 
     if (*serverName) {
         size_t i;
@@ -2737,7 +2738,7 @@ static int init_jk(char *serverName)
                 watchdog_interval = 0;
             }
         }
-        jk_log(logger, JK_LOG_INFO, "%s initialized", (VERSION_STRING));
+        jk_log(logger, JK_LOG_INFO, "%s initialized", (FULL_VERSION_STRING));
     }
     return rc;
 }

Modified: tomcat/jk/trunk/native/netscape/jk_nsapi_plugin.c
URL: http://svn.apache.org/viewvc/tomcat/jk/trunk/native/netscape/jk_nsapi_plugin.c?rev=1026100&r1=1026099&r2=1026100&view=diff
==============================================================================
--- tomcat/jk/trunk/native/netscape/jk_nsapi_plugin.c (original)
+++ tomcat/jk/trunk/native/netscape/jk_nsapi_plugin.c Thu Oct 21 18:53:41 2010
@@ -307,7 +307,7 @@ NSAPI_PUBLIC int jk_init(pblock * pb, Se
             if (init_on_other_thread_is_done && init_on_other_thread_is_ok) {
                 magnus_atrestart(jk_term, NULL);
                 rc = REQ_PROCEED;
-                jk_log(logger, JK_LOG_INFO, "%s initialized", JK_EXPOSED_VERSION);
+                jk_log(logger, JK_LOG_INFO, "%s initialized", JK_FULL_EXPOSED_VERSION);
             }
 
 /*            if(wc_open(init_map, NULL, logger)) {



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: svn commit: r1026100 - in /tomcat/jk/trunk/native: apache-1.3/mod_jk.c apache-2.0/mod_jk.c common/jk_status.c common/jk_version.h iis/jk_isapi_plugin.c netscape/jk_nsapi_plugin.c

Posted by Mladen Turk <mt...@apache.org>.
On 21/10/2010 20:53, rjung@apache.org wrote:
> Author: rjung
>
> The new JK_FULL_EXPOSED_VERSION is used during
> init/startup/shutdown logging, not for the short
> version numbers.
>

Ok that makes more sense, although I still don't
get the what's the point and the *problem* you
had to solve with adding that.


Regards
-- 
^TM

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org