Quantcast

Disconnecting; received message for unknown session while logon and client keep on reconnecting

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Disconnecting; received message for unknown session while logon and client keep on reconnecting

vijayt
Hello All, I am new to quickfix/j

I am trying to build a simple quickfix appl (acceptor and initiator communication)..

With the help of samples provided, i created a server and client.... but unable to proceed due to the below problem
1. Started the server successfully
2. while starting the client part, a session has been created with server
3. then client sends the logon message and Session disconnect response. Server states it is disconnecting due to unknown session. [Disconnecting; received message for unknown session]
4. and client keep on reconnecting and disconnecting.


Here is the server log,
-----------------------
Oct 25, 2010 1:09:19 PM quickfix.mina.acceptor.AbstractSocketAcceptor startAcceptingConnections
INFO: Listening for connections at 0.0.0.0/0.0.0.0:9880
Server Started !!!!
Oct 25, 2010 1:09:25 PM quickfix.mina.acceptor.AcceptorIoHandler sessionCreated
INFO: MINA session created: /127.0.0.1:1660
Oct 25, 2010 1:09:26 PM quickfix.mina.AbstractIoHandler messageReceived
SEVERE: Disconnecting; received message for unknown session: 8=FIXT.1.1_9=131_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:39:26.055_56=SERVER_98=0_108=30_141=Y_553=testUser_554=testPwd_1137=7_10=209_


here is the client logs
---------------------
Oct 25, 2010 1:16:12 PM quickfix.mina.initiator.InitiatorIoHandler sessionCreated
INFO: MINA session created for FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER: local=/127.0.0.1:1743, class org.apache.mina.transport.socket.nio.SocketSessionImpl, remote=localhost/127.0.0.1:9880
QFix Client Appl:toAdmin method invoked
QFix Client Appl : Mon Oct 25 13:16:12 IST 2010
message : 8=FIXT.1.1_9=106_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:46:12.970_56=SERVER_98=0_108=30_141=Y_1137=7_10=209_
MsgType :: A
<20101025-07:46:12, FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER, outgoing> (8=FIXT.1.1_9=131_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:46:12.970_56=SERVER_98=0_108=30_141=Y_553=testUser_554=testPwd_1137=7_10=208_)
<20101025-07:46:12, FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER, event> (Initiated logon request)
Oct 25, 2010 1:16:12 PM quickfix.Session disconnect
INFO: [FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER] Disconnecting: IO Session closed
QFix Client Appl:onLogout method invoked


server config
------------
[default]
FileStorePath=G:\\fixmessage\\server
ConnectionType=acceptor
SocketAcceptPort=9880
StartTime=00:00:00
EndTime=00:00:00
HeartBtInt=30
SenderCompID=*
TargetCompID=*
UseDataDictionary=Y
DefaultMarketPrice=15
Username=Server
Password=PASSWORD
ValidateFieldsOutOfOrder=N
ResetOnLogin=Y
ResetOnDisconnect=N
ResetOnLogout=N
ResetOnLogon=Y
UseDynamicSsession=Y

[session]
AcceptorTemplate=Y
DefaultApplVerID=FIX.5.0
BeginString=FIXT.1.1
DataDictionary=FIX50.xml
CheckLatency=N
CheckCompID=N
FileStoreMaxCachedMsgs=0


client config
------------
[default]
FileStorePath=G:\\fixmessage\\client
ConnectionType=initiator
SenderCompID=C261983C12A660A2A5BCF067C8715C30
TargetCompID=SERVER
SocketConnectHost=localhost
SocketConnectPort=9880
StartTime=00:00:00
EndTime=00:00:00
HeartBtInt=30
ReconnectInterval=10


Username=TestClient
Password=TestPass
isEventLogEnabled=false
isIncomingLogEnabled=false
isOutgoingLogEnabled=false

[session]
BeginString=FIXT.1.1
DefaultApplVerID=FIX.5.0
DataDictionary=FIX50.xml
CheckLatency=N
CheckCompID=N
ResetOnLogon=Y
ResetOnLogout=Y
ResetOnDisconnect=Y


Can some one help to find what is the problem here?

Thanks,
VIjay
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Disconnecting; received message for unknown session while logon and client keep on reconnecting

Kenny Stone-3
QuickFIX/J Documentation: http://www.quickfixj.org/documentation/
QuickFIX/J Support: http://www.quickfixj.org/support/



I don't think this works like you think it will:  

SenderCompID=*
TargetCompID=*

Unless you have implemented the other parts of having dynamic sessions.

Try making your server config match your client (reversing sender to be target):

TargetCompID=C261983C12A660A2A5BCF067C8715C30
SenderCompID=SERVER

--
Kenny Stone
Connamara Systems, LLC


On Mon, Oct 25, 2010 at 4:13 AM, vijayt <[hidden email]> wrote:
QuickFIX/J Documentation: <a href="http://www.quickfixj.org/documentation/ QuickFIX/J" target="_blank">http://www.quickfixj.org/documentation/
QuickFIX/J Support: http://www.quickfixj.org/support/



Hello All, I am new to quickfix/j

I am trying to build a simple quickfix appl (acceptor and initiator
communication)..

With the help of samples provided, i created a server and client.... but
unable to proceed due to the below problem
1. Started the server successfully
2. while starting the client part, a session has been created with server
3. then client sends the logon message and Session disconnect response.
Server states it is disconnecting due to unknown session. [Disconnecting;
received message for unknown session]
4. and client keep on reconnecting and disconnecting.


Here is the server log,
-----------------------
Oct 25, 2010 1:09:19 PM quickfix.mina.acceptor.AbstractSocketAcceptor
startAcceptingConnections
INFO: Listening for connections at 0.0.0.0/0.0.0.0:9880
Server Started !!!!
Oct 25, 2010 1:09:25 PM quickfix.mina.acceptor.AcceptorIoHandler
sessionCreated
INFO: MINA session created: /127.0.0.1:1660
Oct 25, 2010 1:09:26 PM quickfix.mina.AbstractIoHandler messageReceived
SEVERE: Disconnecting; received message for unknown session:
8=FIXT.1.1_9=131_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:39:26.055_56=SERVER_98=0_108=30_141=Y_553=testUser_554=testPwd_1137=7_10=209_


here is the client logs
---------------------
Oct 25, 2010 1:16:12 PM quickfix.mina.initiator.InitiatorIoHandler
sessionCreated
INFO: MINA session created for
FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER: local=/127.0.0.1:1743,
class org.apache.mina.transport.socket.nio.SocketSessionImpl,
remote=localhost/127.0.0.1:9880
QFix Client Appl:toAdmin method invoked
QFix Client Appl : Mon Oct 25 13:16:12 IST 2010
message :
8=FIXT.1.1_9=106_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:46:12.970_56=SERVER_98=0_108=30_141=Y_1137=7_10=209_
MsgType :: A
<20101025-07:46:12, FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER,
outgoing>
(8=FIXT.1.1_9=131_35=A_34=1_49=C261983C12A660A2A5BCF067C8715C30_52=20101025-07:46:12.970_56=SERVER_98=0_108=30_141=Y_553=testUser_554=testPwd_1137=7_10=208_)
<20101025-07:46:12, FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER,
event> (Initiated logon request)
Oct 25, 2010 1:16:12 PM quickfix.Session disconnect
INFO: [FIXT.1.1:C261983C12A660A2A5BCF067C8715C30->SERVER] Disconnecting: IO
Session closed
QFix Client Appl:onLogout method invoked


server config
------------
[default]
FileStorePath=G:\\fixmessage\\server
ConnectionType=acceptor
SocketAcceptPort=9880
StartTime=00:00:00
EndTime=00:00:00
HeartBtInt=30
SenderCompID=*
TargetCompID=*
UseDataDictionary=Y
DefaultMarketPrice=15
Username=Server
Password=PASSWORD
ValidateFieldsOutOfOrder=N
ResetOnLogin=Y
ResetOnDisconnect=N
ResetOnLogout=N
ResetOnLogon=Y
UseDynamicSsession=Y

[session]
AcceptorTemplate=Y
DefaultApplVerID=FIX.5.0
BeginString=FIXT.1.1
DataDictionary=FIX50.xml
CheckLatency=N
CheckCompID=N
FileStoreMaxCachedMsgs=0


client config
------------
[default]
FileStorePath=G:\\fixmessage\\client
ConnectionType=initiator
SenderCompID=C261983C12A660A2A5BCF067C8715C30
TargetCompID=SERVER
SocketConnectHost=localhost
SocketConnectPort=9880
StartTime=00:00:00
EndTime=00:00:00
HeartBtInt=30
ReconnectInterval=10


Username=TestClient
Password=TestPass
isEventLogEnabled=false
isIncomingLogEnabled=false
isOutgoingLogEnabled=false

[session]
BeginString=FIXT.1.1
DefaultApplVerID=FIX.5.0
DataDictionary=FIX50.xml
CheckLatency=N
CheckCompID=N
ResetOnLogon=Y
ResetOnLogout=Y
ResetOnDisconnect=Y


Can some one help to find what is the problem here?

Thanks,
VIjay
--
View this message in context: http://quickfix-j.364392.n2.nabble.com/Disconnecting-received-message-for-unknown-session-while-logon-and-client-keep-on-reconnecting-tp5669930p5669930.html
Sent from the QuickFIX/J mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Quickfixj-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quickfixj-users


------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Quickfixj-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quickfixj-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Disconnecting; received message for unknown session while logon and client keep on reconnecting

vijayt
Thanks for your reply kenny, I tried reversing the targetCompID and senderCompId but didnt work, but I tried the sample from below link and it worked for me, guess some configuration issue with my application.

http://quickfix-j.364392.n2.nabble.com/Developing-simple-Sender-initiator-and-Receiver-acceptor-but-having-difficulties-td792527.html

anyways thanks Kenny, its a good learning start for me..
Loading...