cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h jk_global.h

2002-09-24 Thread hgomez

hgomez  2002/09/24 15:45:18

  Modified:jk/native2/include jk_msg.h jk_global.h
  Log:
  AS/400 back port from 1.2.0.
  
  Revision  ChangesPath
  1.14  +3 -0  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- jk_msg.h  2 Jul 2002 16:53:59 -   1.13
  +++ jk_msg.h  24 Sep 2002 22:45:18 -  1.14
  @@ -142,6 +142,9 @@
   int (*appendString)(struct jk_env *env, struct jk_msg *_this, 
const char *param);
   
  +int (*appendAsciiString)(struct jk_env *env, struct jk_msg *_this, 
  + const char *param);
  +
   int (*appendMap)(struct jk_env *env, struct jk_msg *_this, 
struct jk_map *map);
   
  
  
  
  1.14  +10 -3 jakarta-tomcat-connectors/jk/native2/include/jk_global.h
  
  Index: jk_global.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_global.h,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- jk_global.h   10 Jun 2002 23:58:52 -  1.13
  +++ jk_global.h   24 Sep 2002 22:45:18 -  1.14
  @@ -73,6 +73,13 @@
   #include time.h
   #include ctype.h
   
  +#ifdef AS400
  +#include ap_config.h
  +#include apr_strings.h
  +#include apr_lib.h
  +extern char *strdup (const char *str);
  +#endif
  +
   #include sys/types.h
   #include sys/stat.h
   
  @@ -119,10 +126,10 @@
   #include netinet/tcp.h
   #include arpa/inet.h
   #include sys/un.h
  -#ifndef _OSD_POSIX
  +#if !defined(_OSD_POSIX)  !defined(AS400)  !defined(CYGWIN)
   #include sys/socketvar.h
   #endif
  -#ifndef HPUX11
  +#if !defined(HPUX11)  !defined(AS400)
   #include sys/select.h
   #endif
   #endif
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-07-02 Thread costin

costin  2002/07/02 09:53:59

  Modified:jk/native2/include jk_msg.h
  Log:
  Change back the max message size to what we had in jk1.
  
  Without this we run into problems when jk2 talks with jk1.
  
  Revision  ChangesPath
  1.13  +1 -1  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- jk_msg.h  11 Jun 2002 21:46:38 -  1.12
  +++ jk_msg.h  2 Jul 2002 16:53:59 -   1.13
  @@ -77,7 +77,7 @@
   struct jk_ws_service;
   struct jk_logger;
   
  -#define DEF_BUFFER_SZ (8300)
  +#define DEF_BUFFER_SZ (8*1024)
   #define AJP13_MAX_SEND_BODY_SZ  (DEF_BUFFER_SZ - 6)
   
   /**
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-06-11 Thread nacho

nacho   2002/06/11 14:46:38

  Modified:jk/native2/include jk_msg.h
  Log:
  * Fix the license copyright dates
  
  Revision  ChangesPath
  1.12  +1 -1  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- jk_msg.h  10 Jun 2002 21:41:14 -  1.11
  +++ jk_msg.h  11 Jun 2002 21:46:38 -  1.12
  @@ -2,7 +2,7 @@
*   *
* The Apache Software License,  Version 1.1 *
*   *
  - *  Copyright (c) 1999-2001 The Apache Software Foundation.  *
  + *  Copyright (c) 1999-2002 The Apache Software Foundation.  *
*   All rights reserved.*
*   *
* = *
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-06-10 Thread nacho

nacho   2002/06/10 14:41:14

  Modified:jk/native2/include jk_msg.h
  Log:
  Changed the default ajp buffer size to match the Java part
  
  Revision  ChangesPath
  1.11  +1 -1  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- jk_msg.h  28 May 2002 22:37:11 -  1.10
  +++ jk_msg.h  10 Jun 2002 21:41:14 -  1.11
  @@ -77,7 +77,7 @@
   struct jk_ws_service;
   struct jk_logger;
   
  -#define DEF_BUFFER_SZ (8 * 1024)
  +#define DEF_BUFFER_SZ (8300)
   #define AJP13_MAX_SEND_BODY_SZ  (DEF_BUFFER_SZ - 6)
   
   /**
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-05-23 Thread costin

costin  02/05/23 16:33:19

  Modified:jk/native2/common jk_msg_ajp.c jk_requtil.c
   jk/native2/include jk_msg.h
  Log:
  Reduce the warnings. There are more signed/unsigned char problems,
  I'll do another pass.
  
  Revision  ChangesPath
  1.15  +1 -1  jakarta-tomcat-connectors/jk/native2/common/jk_msg_ajp.c
  
  Index: jk_msg_ajp.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_msg_ajp.c,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- jk_msg_ajp.c  16 May 2002 21:03:44 -  1.14
  +++ jk_msg_ajp.c  23 May 2002 23:33:18 -  1.15
  @@ -356,7 +356,7 @@
   return rc;
   }
   
  -static unsigned char *jk2_msg_ajp_getString(jk_env_t *env, jk_msg_t *msg) 
  +static char *jk2_msg_ajp_getString(jk_env_t *env, jk_msg_t *msg) 
   {
   int size = jk2_msg_ajp_getInt(env, msg);
   int start = msg-pos;
  
  
  
  1.20  +2 -2  jakarta-tomcat-connectors/jk/native2/common/jk_requtil.c
  
  Index: jk_requtil.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_requtil.c,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- jk_requtil.c  23 May 2002 14:54:07 -  1.19
  +++ jk_requtil.c  23 May 2002 23:33:19 -  1.20
  @@ -773,8 +773,8 @@
   {
   const unsigned char *s = (const unsigned char *)path;
   unsigned char *d = (unsigned char *)dest;
  -unsigned char *e = dest + destsize - 1;
  -unsigned char *ee = dest + destsize - 3;
  +unsigned char *e = (unsigned char *)(dest + destsize - 1);
  +unsigned char *ee = (unsigned char *)(dest + destsize - 3);
   unsigned c;
   
   while ((c = *s)) {
  
  
  
  1.9   +1 -1  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- jk_msg.h  16 May 2002 20:49:53 -  1.8
  +++ jk_msg.h  23 May 2002 23:33:19 -  1.9
  @@ -159,7 +159,7 @@
   The buffer is internal to the message, you must save
   or make sure the message lives long enough.
*/ 
  -unsigned char *(*getString)(struct jk_env *env, struct jk_msg *_this);
  +char *(*getString)(struct jk_env *env, struct jk_msg *_this);
   
   /** Return a byte[] and it's length.
*  The buffer is internal to the message, you must save
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-05-01 Thread costin

costin  02/05/01 20:13:05

  Modified:jk/native2/common jk_channel_jni.c jk_msg_ajp.c jk_shm.c
jk_worker_status.c
   jk/native2/include jk_msg.h
  Log:
  Added some more debugging code the shm ( now it can dump the content
  in a file and display some more or less usefull information ).
  
  Started to add code to serialize/deserialize a map ( it's very
  common ).
  
  Few more checks, remove few verbose messages.
  
  Revision  ChangesPath
  1.13  +4 -1  jakarta-tomcat-connectors/jk/native2/common/jk_channel_jni.c
  
  Index: jk_channel_jni.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_channel_jni.c,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- jk_channel_jni.c  1 May 2002 23:10:17 -   1.12
  +++ jk_channel_jni.c  2 May 2002 03:13:05 -   1.13
  @@ -466,7 +466,10 @@
   
   /* XXX Don't detach if worker is reused per thread */
   endpoint-endpoint_private=NULL;
  -we-vm-detach( env, we-vm ); 
  +if( we==NULL || we-vm==NULL ) {
  +return JK_OK;
  +}
  +/* we-vm-detach( env, we-vm );  */
   
   env-l-jkLog(env, env-l, JK_LOG_INFO, 
 channelJni.afterRequest() ok\n);
  
  
  
  1.8   +67 -21jakarta-tomcat-connectors/jk/native2/common/jk_msg_ajp.c
  
  Index: jk_msg_ajp.c
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_msg_ajp.c,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- jk_msg_ajp.c  25 Apr 2002 19:17:22 -  1.7
  +++ jk_msg_ajp.c  2 May 2002 03:13:05 -   1.8
  @@ -60,7 +60,7 @@
* Author:  Costin Manolache
* Author:  Gal Shachor [EMAIL PROTECTED]   *
* Author:  Henri Gomez [EMAIL PROTECTED]   *
  - * Version: $Revision: 1.7 $   *
  + * Version: $Revision: 1.8 $   *
***/
   
   #include jk_pool.h
  @@ -83,7 +83,7 @@
   int i=0;
   env-l-jkLog( env, env-l, JK_LOG_INFO,
  %s pos=%d len=%d max=%d \n,
  -err, _this-pos, _this-len, _this-maxlen );
  +   err, _this-pos, _this-len, _this-maxlen );
   
   env-l-jkLog( env, env-l, JK_LOG_INFO,
   %2x %2x %2x %2x:%2x %2x %2x %2x:%2x %2x %2x %2x:%2x %2x %2x %2x 
\n, 
  @@ -169,6 +169,21 @@
   return JK_OK;
   }
   
  +static int jk2_msg_ajp_appendMap(jk_env_t *env, jk_msg_t *msg, 
  + jk_map_t *map) 
  +{
  +
  +return JK_OK;
  +}
  +
  +static int jk2_msg_ajp_getMap(jk_env_t *env, jk_msg_t *msg, 
  +  jk_map_t *map) 
  +{
  +
  +return JK_OK;
  +}
  +
  +
   static int jk2_msg_ajp_appendString(jk_env_t *env, jk_msg_t *msg, 
   const char *param) 
   {
  @@ -413,25 +428,8 @@
   return len;
   }
   
  -
  -jk_msg_t *jk2_msg_ajp_create(jk_env_t *env, jk_pool_t *pool, int buffSize) 
  +static void jk2_msg_ajp_init(jk_env_t *env, jk_msg_t *msg, int buffSize) 
   {
  -jk_msg_t *msg = 
  -(jk_msg_t *)pool-calloc(env, pool, sizeof(jk_msg_t));
  -
  -if( buffSize==0 )
  -buffSize=DEF_BUFFER_SZ;
  -if(!msg) {
  -return NULL;
  -}
  -msg-pool = pool;
  -
  -msg-buf= (unsigned char *)msg-pool-alloc(env, msg-pool, buffSize);
  -
  -if(msg-buf==NULL) {
  -return NULL;
  -}
  -
   msg-maxlen=buffSize;
   msg-len=0;
   
  @@ -446,6 +444,7 @@
   msg-appendInt=jk2_msg_ajp_appendInt;
   msg-appendLong=jk2_msg_ajp_appendLong;
   msg-appendString=jk2_msg_ajp_appendString;
  +msg-appendMap=jk2_msg_ajp_appendMap;
   
   msg-appendFromServer=jk2_msg_ajp_appendFromServer;
   
  @@ -454,10 +453,57 @@
   msg-peekInt=jk2_msg_ajp_peekInt;
   msg-getLong=jk2_msg_ajp_getLong;
   msg-getString=jk2_msg_ajp_getString;
  +msg-getMap=jk2_msg_ajp_getMap;
   msg-getBytes=jk2_msg_ajp_getBytes;
   
   msg-checkHeader=jk2_msg_ajp_checkHeader;
  -   
  +}
  +
  +
  +jk_msg_t *jk2_msg_ajp_create2(jk_env_t *env, jk_pool_t *pool, char *buf, int 
buffSize)
  +{
  +jk_msg_t *msg = 
  +(jk_msg_t *)pool-calloc(env, pool, sizeof(jk_msg_t));
  +
  +if( buffSize==0 )
  +buffSize=DEF_BUFFER_SZ;
  +if(!msg) {
  +return NULL;
  +}
  +msg-pool = pool;
  +
  +msg-buf= buf;
  +
  +if(msg-buf==NULL) {
  +return NULL;
  +}
  +
  +jk2_msg_ajp_init( env, msg, buffSize );
  +
  +return msg;
  +}
  +
  +
  +jk_msg_t *jk2_msg_ajp_create(jk_env_t *env, jk_pool_t *pool, 

cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h jk_objCache.h jk_pool.h jk_requtil.h

2002-02-21 Thread hgomez

hgomez  02/02/21 03:15:52

  Modified:jk/native2/include jk_msg.h jk_objCache.h jk_pool.h
jk_requtil.h
  Log:
  Eigth Batch of renaming (zzz zzz zzz)
  
  Revision  ChangesPath
  1.5   +2 -2  jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- jk_msg.h  26 Jan 2002 06:22:41 -  1.4
  +++ jk_msg.h  21 Feb 2002 11:15:51 -  1.5
  @@ -171,7 +171,7 @@
   
   /** 
* Special method. Will read data from the server and add them as
  - * bytes. It is equivalent with jk_requtil_readFully() in a buffer
  + * bytes. It is equivalent with jk2_requtil_readFully() in a buffer
* and then jk_msg_appendBytes(), except that we use directly the
* internal buffer.
*
  @@ -196,7 +196,7 @@
   };
   
   /* Temp */
  -jk_msg_t *jk_msg_ajp_create(struct jk_env *env, struct jk_pool *p,
  +jk_msg_t *jk2_msg_ajp_create(struct jk_env *env, struct jk_pool *p,
   int buffSize);
   
   #ifdef __cplusplus
  
  
  
  1.6   +1 -1  jakarta-tomcat-connectors/jk/native2/include/jk_objCache.h
  
  Index: jk_objCache.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_objCache.h,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- jk_objCache.h 6 Feb 2002 19:19:16 -   1.5
  +++ jk_objCache.h 21 Feb 2002 11:15:51 -  1.6
  @@ -78,7 +78,7 @@
   #define JK_OBJCACHE_DEFAULT_SZ  (128)
   
   
  -jk_objCache_t *jk_objCache_create(struct jk_env *env, struct jk_pool *pool );
  +jk_objCache_t *jk2_objCache_create(struct jk_env *env, struct jk_pool *pool );
   
   /**
* Simple object cache ( or pool for java people - don't confuse with the
  
  
  
  1.6   +2 -2  jakarta-tomcat-connectors/jk/native2/include/jk_pool.h
  
  Index: jk_pool.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_pool.h,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- jk_pool.h 16 Dec 2001 23:17:23 -  1.5
  +++ jk_pool.h 21 Feb 2002 11:15:51 -  1.6
  @@ -58,7 +58,7 @@
   /***
* Description: Memory Pool object header file *
* Author:  Gal Shachor [EMAIL PROTECTED]   *
  - * Version: $Revision: 1.5 $   *
  + * Version: $Revision: 1.6 $   *
***/
   #ifndef _JK_POOL_H
   #define _JK_POOL_H
  @@ -159,7 +159,7 @@
   
   XXX move this to the factory
*/
  -int jk_pool_create( struct jk_env *env, jk_pool_t **newPool, jk_pool_t *parent, int 
size );
  +int jk2_pool_create( struct jk_env *env, jk_pool_t **newPool, jk_pool_t *parent, 
int size );
   
   
   #ifdef __cplusplus
  
  
  
  1.4   +9 -9  jakarta-tomcat-connectors/jk/native2/include/jk_requtil.h
  
  Index: jk_requtil.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_requtil.h,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- jk_requtil.h  16 Dec 2001 23:17:23 -  1.3
  +++ jk_requtil.h  21 Feb 2002 11:15:51 -  1.4
  @@ -154,50 +154,50 @@
   
   /** Get header value using a lookup table. 
*/
  -const char *jk_requtil_getHeaderById(struct jk_env *env, int sc);
  +const char *jk2_requtil_getHeaderById(struct jk_env *env, int sc);
   
   /**
* Get method id. 
*/
  -int jk_requtil_getMethodId(struct jk_env *env, const char*method,
  +int jk2_requtil_getMethodId(struct jk_env *env, const char*method,
  unsigned char *sc);
   
   /**
* Get header id.
*/
  -int  jk_requtil_getHeaderId(struct jk_env *env, const char *header_name,
  +int  jk2_requtil_getHeaderId(struct jk_env *env, const char *header_name,
   unsigned short *sc);
   
   /** Retrieve session id from the cookie or the parameter  
* (parameter first)
*/
  -char *jk_requtil_getSessionId(struct jk_env *env, jk_ws_service_t *s);
  +char *jk2_requtil_getSessionId(struct jk_env *env, jk_ws_service_t *s);
   
   /** Retrieve the cookie with the given name
*/
  -char *jk_requtil_getCookieByName(struct jk_env *env, jk_ws_service_t *s,
  +char *jk2_requtil_getCookieByName(struct jk_env *env, jk_ws_service_t *s,
  

cvs commit: jakarta-tomcat-connectors/jk/native2/include jk_msg.h

2002-01-25 Thread costin

costin  02/01/25 22:22:41

  Modified:jk/native2/include jk_msg.h
  Log:
  Removed the sent/receive methods. They were duplicated in channel, and made 
impossible
  or difficult to do some optimizations. Jni channel ( or most message-based - doors,
  fifo, etc ) do not need to read the header in a separate operation. Even for socket,
  it may be better to read as much as available ( buffering ) - that could be
  implemented in the apr channel.
  
  Revision  ChangesPath
  1.4   +11 -13jakarta-tomcat-connectors/jk/native2/include/jk_msg.h
  
  Index: jk_msg.h
  ===
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/include/jk_msg.h,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- jk_msg.h  16 Dec 2001 23:17:23 -  1.3
  +++ jk_msg.h  26 Jan 2002 06:22:41 -  1.4
  @@ -106,7 +106,11 @@
   /** Method id - to be sent in the packet
*/
   int id;
  - 
  +
  +/** Header length for this message
  + */
  +int headerLength;
  +
   /*
* Prepare the buffer for a new invocation 
*/
  @@ -117,6 +121,9 @@
*/
   void (*end)(struct jk_env *env, struct jk_msg *_this);
   
  +int (*checkHeader)(struct jk_env *env, struct jk_msg *_this,
  +struct jk_endpoint *e);
  +
   /*
* Dump the buffer header
*   @param err Message text
  @@ -158,18 +165,9 @@
   The buffer is internal to the message, you must save
   or make sure the message lives long enough.
*/ 
  -unsigned char *(*getBytes)(struct jk_env *env, struct jk_msg *_this, int *len);
  -
  -
  -/*
  - * Receive a message from endpoint
  - */
  -int (*receive)(struct jk_env *env, jk_msg_t *_this, struct jk_endpoint *ae );
  -
  -/*
  - * Send a message to endpoint
  - */
  -int (*send)(struct jk_env *env, jk_msg_t *_this, struct jk_endpoint *ae );
  +unsigned char *(*getBytes)(struct jk_env *env,
  +   struct jk_msg *_this,
  +   int *len);
   
   /** 
* Special method. Will read data from the server and add them as
  
  
  

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]