我已编写代码,使用SSL使用HTTPS POST成功连接到第三方服务。 该计划取得了成功,我得到了预期的回应。 问题是,在我们的Staging环境中,我们得到一个异常而且我无法调试,因为我们没有权限,而且,应用程序被部署为WAR文件;所以没有源代码。
附加了例外。
我从Windows机器测试了我的工作代码,现在真正的测试是从Linux机器完成的。我看到的唯一区别是提到证书路径的方式。 在Windows中,它类似于C:// jre-security-folder-path / cacerts,但在Linux中它的某些功能类似于/ usr / jre-security-folder-path / cacerts。
因为,我m unable to debug,I
我不确定在哪一点,它失败了。
有人告诉我这是否是我身边的问题,如SSL证书相关或服务器端问题?
java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:529)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:559)
at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.connect(BaseSSLSocketImpl.java:141)
at sun.net.NetworkClient.doConnect(NetworkClient.java:163)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
at sun.net.www.protocol.https.HttpsClient.<init>(HttpsClient.java:272)
at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:329)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(AbstractDelegateHttpsURLConnection.java:172)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:911)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:158)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1014)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream(HttpsURLConnectionImpl.java:230)
at com.pass.project.application.activities.DlgEditBoProfilePaxGUIElementActivity.callSecureService(DlgEditBoProfilePaxGUIElementActivity.java:1968)
at com.pass.project.application.activities.DlgEditBoProfilePaxGUIElementActivity.eventStart(DlgEditBoProfilePaxGUIElementActivity.java:301)
at com.pass.framework.utc.components.mvc.activity.GuiElementActivityEvent.callActivity(GuiElementActivityEvent.java:111)
at com.pass.framework.utc.components.mvc.activity.BaseDialogActivityEvent.callActivities(BaseDialogActivityEvent.java:226)
at com.pass.framework.utc.components.activitychain.ActivityChain.fireEvent(ActivityChain.java:141)
at com.pass.project.gillerpax.action.DlgEditBoProfilePaxAction.handleBtnNewtblBoProfilePax_FormOfPaymentAction(DlgEditBoProfilePaxAction.java:4358)
at com.pass.project.gillerpax.action.DlgEditBoProfilePaxAction.handleEvents(DlgEditBoProfilePaxAction.java:423)
at com.pass.project.gillerpax.action.DlgEditBoProfilePaxAction.doExecute(DlgEditBoProfilePaxAction.java:172)
at com.pass.framework.utc.components.mvc.action.CodegenAction.execute(CodegenAction.java:189)
at com.pass.project.gillerpax.action.DlgEditBoProfilePaxAction.execute(DlgEditBoProfilePaxAction.java:127)
at com.pass.framework.utc.components.mvc.forms.CodegenForm.buttonPressedExecution(CodegenForm.java:353)
at com.pass.project.gillerpax.forms.DlgEditBoProfilePaxForm.btnNewtblBoProfilePax_FormOfPaymentPressed(DlgEditBoProfilePaxForm.java:15091)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.el.parser.AstValue.invoke(AstValue.java:191)
at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276)
at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:105)
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:787)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1252)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:312)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.pass.framework.utc.components.utcjsf.UtcFacesServletFilter.doFilter(UtcFacesServletFilter.java:138)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at com.pass.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:776)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:705)
at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:898)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
at java.lang.Thread.run(Thread.java:662)