java.net.ConnectException: Connection refused: connect

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

java.net.ConnectException: Connection refused: connect

vinodv
i have added a simple application HelloWorld which displays "Hello World" on the screen.
i have made the whole framework and also added the application in the ofbiz-component.xml in the applications folder.
There are no problems when i use any other application, but when i use the hello application i get the following error on the front-end.

java.net.ConnectException: Connection refused: connect


The log for this error is as under :

2007-12-05 11:05:56,557 (http-0.0.0.0-8080-Processor4) [     ControlServlet.java:196:ERROR] ---- exception report ----------------------------------------------------------
Error in request handler:
Exception: java.net.ConnectException
Message: Connection refused: connect
---- stack trace ---------------------------------------------------------------
java.net.ConnectException: Connection refused: connect
java.net.PlainSocketImpl.socketConnect(Native Method)
java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
java.net.Socket.connect(Socket.java:507)
java.net.Socket.connect(Socket.java:457)
sun.net.NetworkClient.doConnect(NetworkClient.java:157)
sun.net.www.http.HttpClient.openServer(HttpClient.java:365)
sun.net.www.http.HttpClient.openServer(HttpClient.java:477)
sun.net.www.http.HttpClient.<init>(HttpClient.java:214)
sun.net.www.http.HttpClient.New(HttpClient.java:287)
sun.net.www.http.HttpClient.New(HttpClient.java:299)
sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:792)
sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:744)
sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:669)
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:913)
org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown Source)
org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(Unknown Source)
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:98)
org.ofbiz.base.util.UtilXml.readXmlDocument(UtilXml.java:238)
org.ofbiz.base.util.UtilXml.readXmlDocument(UtilXml.java:177)
org.ofbiz.widget.screen.ScreenFactory.getScreenFromLocation(ScreenFactory.java:114)
org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:108)
org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:94)
org.ofbiz.widget.screen.ScreenWidgetViewHandler.render(ScreenWidgetViewHandler.java:94)
org.ofbiz.webapp.control.RequestHandler.renderView(RequestHandler.java:651)
org.ofbiz.webapp.control.RequestHandler.doRequest(RequestHandler.java:435)
org.ofbiz.webapp.control.ControlServlet.doGet(ControlServlet.java:193)
javax.servlet.http.HttpServlet.service(HttpServlet.java:595)
javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
org.ofbiz.webapp.control.ContextFilter.doFilter(ContextFilter.java:248)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:542)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
java.lang.Thread.run(Thread.java:595)
--------------------------------------------------------------------------------
2007-12-05 11:05:56,557 (http-0.0.0.0-8080-Processor4) [     ControlServlet.java:210:ERROR] An error occurred, going to the errorPage: /error/error.jsp2007-12-05 11:05:56,573 (http-0.0.0.0-8080-Processor4) [     ControlServlet.java:217:ERROR] Including errorPage: /error/error.jsp
Reply | Threaded
Open this post in threaded view
|

Re: java.net.ConnectException: Connection refused: connect

Tim Ruppert
You have a port / IP conflict and your OFBiz server cannot come up.  
You need to get that conflict resolved then go from there.

Cheers,
Tim
--
Tim Ruppert
HotWax Media
http://www.hotwaxmedia.com

o:801.649.6594
f:801.649.6595


On Dec 12, 2007, at 4:29 AM, vinodv wrote:

>
> i have added a simple application HelloWorld which displays "Hello  
> World" on
> the screen.
> i have made the whole framework and also added the application in the
> ofbiz-component.xml in the applications folder.
> There are no problems when i use any other application, but when i  
> use the
> hello application i get the following error on the front-end.
>
> java.net.ConnectException: Connection refused: connect
>
>
> The log for this error is as under :
>
> 2007-12-05 11:05:56,557 (http-0.0.0.0-8080-Processor4) [
> ControlServlet.java:196:ERROR] ---- exception report
> ----------------------------------------------------------
> Error in request handler:
> Exception: java.net.ConnectException
> Message: Connection refused: connect
> ---- stack trace
> ---------------------------------------------------------------
> java.net.ConnectException: Connection refused: connect
> java.net.PlainSocketImpl.socketConnect(Native Method)
> java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
> java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
> java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
> java.net.Socket.connect(Socket.java:507)
> java.net.Socket.connect(Socket.java:457)
> sun.net.NetworkClient.doConnect(NetworkClient.java:157)
> sun.net.www.http.HttpClient.openServer(HttpClient.java:365)
> sun.net.www.http.HttpClient.openServer(HttpClient.java:477)
> sun.net.www.http.HttpClient.<init>(HttpClient.java:214)
> sun.net.www.http.HttpClient.New(HttpClient.java:287)
> sun.net.www.http.HttpClient.New(HttpClient.java:299)
> sun
> .net
> .www
> .protocol
> .http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:792)
> sun
> .net
> .www
> .protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:
> 744)
> sun
> .net
> .www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:
> 669)
> sun
> .net
> .www
> .protocol
> .http.HttpURLConnection.getInputStream(HttpURLConnection.java:913)
> org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown  
> Source)
> org.apache.xerces.impl.XMLEntityManager.startEntity(Unknown Source)
> org.apache.xerces.impl.XMLEntityManager.startDTDEntity(Unknown Source)
> org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(Unknown  
> Source)
> org.apache.xerces.impl.XMLDocumentScannerImpl
> $DTDDispatcher.dispatch(Unknown
> Source)
> org
> .apache
> .xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
> Source)
> org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
> org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
> org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
> org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
> javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:98)
> org.ofbiz.base.util.UtilXml.readXmlDocument(UtilXml.java:238)
> org.ofbiz.base.util.UtilXml.readXmlDocument(UtilXml.java:177)
> org
> .ofbiz
> .widget
> .screen.ScreenFactory.getScreenFromLocation(ScreenFactory.java:114)
> org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:108)
> org.ofbiz.widget.screen.ScreenRenderer.render(ScreenRenderer.java:94)
> org
> .ofbiz
> .widget
> .screen.ScreenWidgetViewHandler.render(ScreenWidgetViewHandler.java:
> 94)
> org
> .ofbiz.webapp.control.RequestHandler.renderView(RequestHandler.java:
> 651)
> org
> .ofbiz.webapp.control.RequestHandler.doRequest(RequestHandler.java:
> 435)
> org.ofbiz.webapp.control.ControlServlet.doGet(ControlServlet.java:193)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:595)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
> org
> .apache
> .catalina
> .core
> .ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:
> 269)
> org
> .apache
> .catalina
> .core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
> org.ofbiz.webapp.control.ContextFilter.doFilter(ContextFilter.java:
> 248)
> org
> .apache
> .catalina
> .core
> .ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:
> 215)
> org
> .apache
> .catalina
> .core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
> org
> .apache
> .catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:
> 210)
> org
> .apache
> .catalina.core.StandardContextValve.invoke(StandardContextValve.java:
> 174)
> org
> .apache
> .catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
> org
> .apache
> .catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
> org
> .apache
> .catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:
> 108)
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:
> 542)
> org
> .apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:
> 151)
> org
> .apache.coyote.http11.Http11Processor.process(Http11Processor.java:
> 870)
> org.apache.coyote.http11.Http11BaseProtocol
> $Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:
> 665)
> org
> .apache
> .tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:
> 528)
> org
> .apache
> .tomcat
> .util
> .net
> .LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
> org.apache.tomcat.util.threads.ThreadPool
> $ControlRunnable.run(ThreadPool.java:685)
> java.lang.Thread.run(Thread.java:595)
> --------------------------------------------------------------------------------
> 2007-12-05 11:05:56,557 (http-0.0.0.0-8080-Processor4) [
> ControlServlet.java:210:ERROR] An error occurred, going to the  
> errorPage:
> /error/error.jsp2007-12-05 11:05:56,573 (http-0.0.0.0-8080-
> Processor4) [
> ControlServlet.java:217:ERROR] Including errorPage: /error/error.jsp
>
> --
> View this message in context: http://www.nabble.com/java.net.ConnectException%3A-Connection-refused%3A-connect-tp14292727p14292727.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>


smime.p7s (3K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: java.net.ConnectException: Connection refused: connect

vinodv
Thanks Tim,

The problem is that it is only happening with this application .
All the other ofbiz applications like e-commerce and Accounting are working.
It is only this application that gives a problem.

Earlier there was a problem with the port conflict with another application. Stopped the service that was using the port and OFBiz was working properly, however the new "hello world" application is not working properly.


Vinod K
L&T Infotech






<quote author="Tim Ruppert">
You have a port / IP conflict and your OFBiz server cannot come up.  
You need to get that conflict resolved then go from there.

Cheers,
Tim
--
Tim Ruppert
HotWax Media
http://www.hotwaxmedia.com

o:801.649.6594
f:801.649.6595