Can sync and async sockets communicate succesfully?

We have a socket connection specifically built for us that reads an xml file to get the host connection details  ip address,port  etc and then sends a login  request, a xml data  file, waits for a  response data file from the host  and then sends a session logout and converts the response file to xml format.

Initially this was thought to be working well until in some circumstances the response file is truncated and this crashes the program that reads the response file.

The trace attached shows that our server receives the full data sent from the host but the socket dll seems to not send all  data from the host back to the calling application.

The attached trace shows the point in blue where the received data is truncated. My question is have we been lucky that the socket dll has worked at all so far as we have been advised that our socket is sync and the host is async.

Is it possible for sync and async sockets to communicate succesfully or could our problem be elsewhere?

Many thanks
Richard

socket-trace.doc
fxb1000Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

cyberkiwiCommented:
It should work ok, because sync is just a special form of async, so to speak. Async allows multiple mini-conversations to occur at the same time, like talking to your wife and not waiting for responses, and responding in batches. But your wife is free to take your sentence one at a time and only respond to one at a time.
0
pkadianCommented:
I could not understand following...

The trace attached shows that our server receives the full data sent from the host but the socket dll seems to not send all  data from the host back to the calling application.
0
fxb1000Author Commented:
Hi
The trace shows the full response file from the host is received at some level in our server however the socket file doesnt seem to provide all that data back to the calling application. In this case causing an incomplete xml to be assembled (from the data received from the host).
We are trying to work out why this file is incomplete when the trace shows it is fully received. I am not sure if the socket is at fault hence my sync versus async question.

Small extract is shown

      1392: 6f20 6d61 7463 6869 6e67 2061 6363 7275    o matching accru
      1408: 616c 2066 6f72 2073 7065 6369 6669 6564    al for specified
      1424: 2064 6174 653c 2f54 6578                    date</Tex

Note : File is truncated here in the application

csydw11.au.fcl.internal ->  aclys01.au.fcl.internal TCP D=23030 S=2284 Ack=427297718 Seq=1085150510 Len=0 Win=32768

         0: 0021 2846 af52 001b d588 78de 0800 4500    .!(F.R....x...E.
        16: 0028 58af 4000 7806 9fda 0a16 ec19 0a16    .(X.@.x.....ì...
        32: 0a01 08ec 59f6 40ae 152e 1978 0bb6 5010    ...ìY.@....x..P.
        48: 8000 47a1 0000 0000 0000 0000              ..G¡........

aclys01.au.fcl.internal ->  csydw11.au.fcl.internal TCP D=2284 S=23030 Push Ack=1085150510 Seq=427299098 Len=195 Win=32775

         0: 001b d588 78de 0021 2846 af52 0800 4500    ....x..!(F.R..E.
        16: 00eb 4062 4000 4006 0000 0a16 0a01 0a16    ..@b@.@.........
        32: ec19 59f6 08ec 1978 111a 40ae 152e 5018    ì.Y..ì.x..@...P.
        48: 8007 0000 0000 743e 3c2f 4572 726f 723e    ......t></Error>
      64: 3c2f 496e 766f 6963 6549 7465 6d3e 3c49</InvoiceItem><I
        80: 6e76 6f69 6365 4974 656d 2053 7461 7475    nvoiceItem Statu
        96: 733d 2252 656a 6563 7465 6422 3e3c 4572    s="Rejected"><Er
       112: 726f 7220 436f 6465 3d22 4352 4956 435f    ror Code="CRIVC_
       128: 4e4f 5f41 4343 525f 4441 5445 223e 3c54    NO_ACCR_DATE"><T
       144: 6578 743e 4e6f 206d 6174 6368 696e 6720    ext>No matching
       160: 6163 6372 7561 6c20 666f 7220 7370 6563    accrual for spec
       176: 6966 6965 6420 6461 7465 3c2f 5465 7874    ified date</Text
       192: 3e3c 2f45 7272 6f72 3e3c 2f49 6e76 6f69></Error></Invoi
       208: 6365 4974 656d 3e3c 2f49 6e76 6f69 6365    ceItem></Invoice
       224: 4974 656d 733e 3c2f 5375 626d 6974 496e    Items></SubmitIn
       240: 766f 6963 6552 533e 00                     voiceRS>.
This is the actual end of the file.



I hope that explains the situation more clearly
Regards

0
fxb1000Author Commented:
Eventual resolution was -  route between client and server had changed and a device in the path was causing problems. Original path was 4 hops new path was 9. dont know what was in between but infrastructure guys rerouted and all was good.
Thanks for all posts.

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Programming Languages-Other

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.