Hi,
I'm trying to implement a HTTP reverse proxy in B4J.
The implementation is simple:
- the application is listing on port 80 (serversocket)
- when a connection is made a (client) socket is created: it connects to the "real" website
- both sockets exchange data (data received on one socket is sent to the other and visa versa).
In fact, currently it is just an attempt to do port forwarding in B4J.
I make sure to take into account multi threading (I keep a list of socket pairs).
For a simple website it seems to work, but as soon as concurrent requests are being made it fails. I guess it has to do with multi threading functionality in B4J ?
Thanks
I'm trying to implement a HTTP reverse proxy in B4J.
The implementation is simple:
- the application is listing on port 80 (serversocket)
- when a connection is made a (client) socket is created: it connects to the "real" website
- both sockets exchange data (data received on one socket is sent to the other and visa versa).
In fact, currently it is just an attempt to do port forwarding in B4J.
I make sure to take into account multi threading (I keep a list of socket pairs).
For a simple website it seems to work, but as soon as concurrent requests are being made it fails. I guess it has to do with multi threading functionality in B4J ?
Thanks
Last edited: