B4J Question Socket Close ....cannot reconnect to host !

Jmu5667

Well-Known Member
Licensed User
Longtime User
Hi

I have done a lot of work with the socket object and async streams. We have alot of apps in vb6, B4A and now B4J, that all communicate together using sockets, and store data in SQL etc.

A new app we are developing connects to one of our servers apps called the 'Application Gateway' (APPG) and other apps connect to it so that can exchange data with each other.

The new B4J app can support many client connections can send data that each client sends and store in a SQL DB. Currently the B4J app is being designed to see the most efficient method for doing a heavy workload.

So, the B4J app connects to the APPG and can received lots of packets of data while handling it's own client connections etc.

I have noticed if I disconnect from the APPG, I cannot connect to it again. The code that manage the APPG connection etc is in a class of it's own. I have found if after closing the async stream and the socket, if I do initialize the socket again I can connect......

Is this a bug, or is this the way it should be done.

All comments welcome

Regards

John.
 
Top