Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 339641 - [server] [sites] Error 500 when site points to nonexistent remote URL
Summary: [server] [sites] Error 500 when site points to nonexistent remote URL
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.2   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 0.2   Edit
Assignee: Mark Macdonald CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-11 01:39 EST by Mark Macdonald CLA
Modified: 2011-09-01 11:42 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Macdonald CLA 2011-03-11 01:39:57 EST
1. Go to sites.html, create a new site
2. Click on the site's name to open it in edit-site.html
3. Click the "Add..." button and choose "URL..."
4. Leave the added entry as-is. It should look like this:
        Target             Mount at
        http://someurl     /mountPoint
5. Save, return to sites.html, and start the site.
6. Visit http://<startedSiteHostName>/mountPoint in your browser.
   After a few seconds' pause, you'll see an 500 Internal Server error and a Java stack trace.

This error needs to be handled, returning an error details object instead of a stack trace, and with a more correct response code.
Comment 1 Mark Macdonald CLA 2011-03-11 01:41:07 EST
Here's the stack trace

java.net.UnknownHostException: someurl
    at java.net.PlainSocketImpl.connect(Unknown Source)
    at java.net.SocksSocketImpl.connect(Unknown Source)
    at java.net.Socket.connect(Unknown Source)
    at java.net.Socket.connect(Unknown Source)
    at sun.net.NetworkClient.doConnect(Unknown Source)
    at sun.net.www.http.HttpClient.openServer(Unknown Source)
    at sun.net.www.http.HttpClient.openServer(Unknown Source)
    at sun.net.www.http.HttpClient.<init>(Unknown Source)
    at sun.net.www.http.HttpClient.New(Unknown Source)
    at sun.net.www.http.HttpClient.New(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
    at org.eclipse.orion.internal.server.hosting.HostedSiteServlet.proxyRemoteUrl(HostedSiteServlet.java:206)
    at org.eclipse.orion.internal.server.hosting.HostedSiteServlet.serve(HostedSiteServlet.java:107)
    at org.eclipse.orion.internal.server.hosting.HostedSiteServlet.doGet(HostedSiteServlet.java:57)
        ....
Comment 2 Mark Macdonald CLA 2011-04-04 14:07:50 EDT
Fixed by Bug 340065