Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!feeder.news-service.com!feeder2.cambriumusenet.nl!feed.tweaknews.nl!209.197.12.242.MISMATCH!nx01.iad01.newshosting.com!newshosting.com!news-out.readnews.com!news-xxxfer.readnews.com!postnews.google.com!news1.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!spln!extra.newsguy.com!newsp.newsguy.com!news4 From: Michael Wojcik Newsgroups: comp.lang.java.programmer Subject: Re: tools for programming applets Date: Thu, 26 May 2011 14:29:39 -0400 Organization: Micro Focus Lines: 38 Message-ID: References: <028d2009-98b7-43a3-b02d-83eaa89db79e@glegroupsg2000goo.googlegroups.com> <4ddb88aa$0$49180$e4fe514c@news.xs4all.nl> NNTP-Posting-Host: p8ec8ce9b907ae7f730298ef71cc1634c24f0b4143cd3669a.newsdawg.com Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.5.0 In-Reply-To: <4ddb88aa$0$49180$e4fe514c@news.xs4all.nl> Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:4612 Silvio wrote: > > Why don't you run a local proxy (apache comes to mind but even > Tomcat/Jetty would do) for the site with some special rules to serve the > applet from where you have it and to replace the sites DNS with its > actual IP. Then map the DNS to localhost in /etc/hosts or > /Windows/System32/drivers/etc/hosts. Has worked fine with almost any > site for me in the past. Was this really the only post in this interminable thread to suggest a proxy? To the OP: Look at your problem this way. You want a server you control, so you can test your applet. You want the applet to be able to request resources from that server. You don't want to duplicate the production server. So set up your local server to serve the applet from a local resource, and to proxy everything else from the production server. A server can provide some content without being the origin server for that content. (HTTP specifies a number of proxying modes to solve problems like this; see RFC 2616.) The applet needs non-HTTP resources from the production server? Proxy those as well. There are any number of generic TCP proxy utilities floating around. I often use the TcpTunnel utility from the old Apache Java SOAP toolkit, mostly because I've had it lying around for years and there's been no reason to find or write another one, for this purpose. Personally, I'd go ahead and duplicate the origin server, or a subset of it, because that's usually the best option, for all the reasons that have already been mentioned in the thread. But proxying is a viable alternative. -- Michael Wojcik Micro Focus Rhetoric & Writing, Michigan State University