The Design of Software (CLOSED)

A public forum for discussing the design of software, from the user interface to the code architecture. Now closed.

The "Design of Software" discussion group has been merged with the main Joel on Software discussion group.

The archives will remain online indefinitely.

Port forwarder/TCP-level proxy software

My team are exposing a web service to various other teams within the company. We want to be able to regularly deploy new versions on a different IP port for final testing and then later seamlessly migrate multiple existing clients over to the new instance without them having to know the version has changed or having any downtime (assuming no breaking interface changes).

The way I'd like to do this is by having a intermediary port forwarder/TCP-level proxy in software that will always point to which ever web service instance is the current live version and will redirect clients to that web service without them even knowing they didn't connect directly to the web service. The change of port would take place by changing central config and the proxy software would poll that config and switch over a few minutes after the config has changed.

The redirection would be very much the same way that ethereal or various other network debugging apps work to allow them to listen in on TCP traffic but I just want to use it for redirection.

An ideal solution would be some C# source code for a windows application that can do this but I'd be interested in other software solutions, I've not been able to find any concise examples using google. Hardware's out of the question as this is a large enterprise so we don't have access to the physical servers.
mutabled Send private email
Tuesday, April 17, 2007
 
 
It may be too low-level for your needs, as it relays all traffic on a port, but you might try RelayTCP:
http://www.dlcsistemas.com/html/relay_tcp.html

I've used it for proxying database connections, and have been very pleased.

It runs in a Windows command shell, and you can update the config from a telnet session.
Achilles
Tuesday, April 17, 2007
 
 
Thanks Achilles, RelayTCP certainly looks interesting and may well fit our needs.  Does it have any performance overheads (when logging is disabled) over making a direct connection?

I'm more interested in the RelayTCP Windows service so it can run 24x7 rather than the console mode. I'll get one of my guys to check it out.

We'd envisaged having central config file that the proxy software polled to update itself in which case we'd need to roll our own but it looks like RelayTCP might allow us to configure it while running by writing to the windows registry.
mutabled Send private email
Tuesday, April 17, 2007
 
 
I haven't noticed any performance issues, either with the "relay server" or the overall throughput, though I won't claim to have stress-tested it.

I've used it primarily to get around NAT problems occurring with multiple VPNs.

I too run it as a Windows service. What I should have said was that the control program, retcpadm, can be done remotely through a telnet session.

I don't know about modifying the config through the registry, but when I modify the configuration using the control panel, I have to stop and start the service.
Achilles
Tuesday, April 17, 2007
 
 
If it's something like soap, why not just configure apache and modproxy?
Grant Send private email
Tuesday, April 17, 2007
 
 
But if you don't have control over your infrastructure, do you have reliable static IPs to run off of?
Grant Send private email
Tuesday, April 17, 2007
 
 
I wonder if LinkByte's ComTun service might work for you?  It's not exactly made for this, but it can do some port forwarding.  Not sure how it stands up to load, but it works well in a home environment.

http://www.linkbyte.com/
Doug
Tuesday, April 17, 2007
 
 
Grant, you're right that we can't guarantee our IP addresses, they are fairly stable but are not guaranteed not to change so we would be looking for a proxy solution that can have the end points specified as machine names and resolve these to IP addresses.

I'll take a look at ComTun and mod_proxy, i'm not familiar with either.
mutabled Send private email
Wednesday, April 18, 2007
 
 
Isn't this the sort of thing that Bonjour/Redezvous/Zeroconf and UPnP is intended to solve?

Have a look here:

  http://www.zeroconf.org/

here:

  http://developer.apple.com/networking/bonjour/

or here:

  http://www.upnp.org/
Jeff Dutky Send private email
Thursday, April 19, 2007
 
 

Tuesday, May 01, 2007
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz