Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Give me your opinion please
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
01047123
Message ID:
01047139
Vues:
10
Chad,
I guess you could look at the 250 commands as one session, but I have never thought of it as one session because the commands are not related to eachother.


Can you see any other advantages of considdering the 250 commands one session other than overhead and a slight performance in time?

Einar

>Einar,
>
>You could go either way with it (obviously), but it seems to me that all 250 commands are part of a single session. Without more information, I don't see why you wouldn't just connect once per session and disconnect after all commands are sent and received. It would cut down on the overhead of connection/disconnection a great deal.
>
>HTH,
>Chad
>
>
>>I am working on an app that connects to a device using the TCP protocol. I send a data packet (containing a command), this is a relatively small data packet. Then the device that I am connected to will return a data packet (again relatively small packet up to 1K worth of data).
>>I will connect to the device up to 250 times (send and receive data) then I will wait for about 1 minute (might be a longer wait. I think I will make the waiting period programmable from 30 seconds to 5 minutes) and do the same thing over again.
>>
>>Currently what I am doing is connecting to the IP endpoint (IP address and port) using TCP anding the command, then receiving the data then disconnecting. Then I connect, send, receive and disconnect again and so on and so forth.
>>
>>This is in my oppinion the correct way of doing this.
>>
>>The other option is to connect, then send command#1, receive, send command #2, receive, ....send command#250, receive and then disconnect
>>
>>Any thoughts on the issue? Has anyone created a class that does something similar? Which method would you choose?
>>
>>Thanks,
>>Einar
Semper ubi sub ubi.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform