[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [xmlblaster] xmlBlasterClient.pl: SessionId '' is invalid + p atch



Osterman, Forrest wrote:

Hi,

please use the very newest cvs from today.

As many properties changed it makes sense that you use the newest code,
see xmlBlaster/CHANGES

I have updated
http://www.xmlblaster.org/xmlBlaster/doc/requirements/protocol.socket.html
to be more descriptive on your questions.


I'd like to give a little more detail about what I tried to do, so you can
correct any false assumptions I might be making here:

I tried to construct a connect message to send to xmlBlaster, so that I
could start a subscription.

Here is the message I constructed:
458**I**13464*connect***
<qos>
<session name='osterman/3' timeout='3600000' maxSessions='10' clearSessions='false'/>
<ptp>true</ptp>
<duplicateUpdates>false</duplicateUpdates>
<queue relating='callback' maxEntries='1000' maxBytes='4000000' onOverflow='deadMessage'>
<callback type='IOR' sessionId='4e56890ghdFzj0' pingInterval='10000' retries='-1' delay='10000' oneway='false' dispatchPlugin='undef'> IOR:10000010033200000099000010....
<burstMode collectTime='400' /> <compress type='gzip' minSize='3000'/>
<ptp>true</ptp>
</callback></queue></qos>*



I tried to keep the message the same as your example, with the exception of my login name, and put an arbitrary request ID in front of it. Are the request ID's in fact arbitrary or are they supposed to follow some scheme?

They are used for the sender (your applet) only. XmlBlaster bounces it back for the return so
that the applet can find out to which request the response belongs.


Please look into
xmlBlaster/src/c/socket/xmlBlasterAccessUnparsed.c
for an implementation example of the SOCKET protocol, it is very straightforward
and small.



As I was asking before, is the sessionId field that you send in the connect message randomly generated, and then received back in the returned connect message as confirmation? If not, where do you get the sessionId value to send in the connection request?

See http://www.xmlblaster.org/xmlBlaster/doc/requirements/protocol.socket.html


After I sent this message, xmlblaster gave this output:

[May 22, 2003 7:32:14 PM TRACE HandleClientRequest] Client accepted, coming from host=/127.0.0.1 port=3322
[May 22, 2003 7:32:14 PM TRACE Parser] Entering readOneMsg(), waiting on inputStream
[May 22, 2003 7:32:27 PM TRACE Parser] Got first 10 bytes of total length=45
[May 22, 2003 7:32:27 PM DUMP Parser] Raw message received '**********8**I**13464*connect***<qos><session'


This looks wrong, the 'I' seems to be shifted one place to the right and the message length in the first 10 chars
seems to be missing ....


Please check it with
http://www.xmlblaster.org/xmlBlaster/doc/requirements/protocol.socket.html

regards

Marcel

PS: Having a raw Java SOCKET module without XmlBlasterException/Global/LogChannel dependency
seems to be a good approach. This module could than be wrapped into our SOCKET plugin providing
a layer with xmlBlaster dependend java classes.
On the SOCKET C side i'm currently trying this approach.


[May 22, 2003 7:32:27 PM WARN  Parser] Ignoring checksum flag [May 22, 2003
7:32:27 PM WARN  Parser] Ignoring version=-48 on 1 is supported
[May 22, 2003 7:32:27 PM TRACE Parser] Leaving parse(), message successfully

parsed
[May 22, 2003 7:32:27 PM TRACE HandleClientRequest] Receiving message connect(13464)
[May 22, 2003 7:32:27 PM DUMP HandleClientRequest] Receiving message >


59A****113464*connect***<qos><session**0* -1<
[May 22, 2003 7:32:27 PM TRACE SocketExecutor] Receiving 'UNKNOWN_TYPE' message connect(13464)
[May 22, 2003 7:32:27 PM WARN SocketExecutor] Ignoring received 'connect' message id=13464, nobody is interested in it
[May 22, 2003 7:32:27 PM DUMP SocketExecutor] Ignoring received message, nobody is interested in it: >
59A****113464*connect***<qos><session**0*-1<
[May 22, 2003 7:32:27 PM TRACE Parser] Entering readOneMsg(), waiting on inputStream
[May 22, 2003 7:32:27 PM WARN HandleClientRequest] Lost connection to client: java.io.IOException: Format of message header is corrupted '
name='ost', expected integral value


Is it really obvious what it didn't like about this message? Anything
obvious that I am missing here?

Thanks,
-Forrest