从命令行通过 SSL 使用 Spring HttpInvoker
我有一个命令行 Spring 应用程序,它通过 Spring 的 HttpInvoker 使用远程 Web 服务。连接 URL 在属性文件中配置:
<bean id="httpFooBarServiceProxy"
class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">
<property name="serviceUrl" value="${serverURI}/
FooBarService-httpinvoker.rpc" />
<property name="serviceInterface">
<value>foo.bar.service.Interface</value>
</property>
<property name="httpInvokerRequestExecutor">
<bean
class="org.springframework.remoting.httpinvoker.CommonsHttpInvokerRequestExecutor" />
</property>
</bean>
一切正常,但现在我们的合作伙伴希望通过 HTTPS 使用它来访问在其 Weblogic 10.3 服务器上运行的服务。
据我所知,应用程序可以保持不变,他只需将证书(?)导入密钥库(?)并更改属性文件中url中的协议。你能否证实这一点?
I have a command line spring application that uses a remote webservice via Spring's HttpInvoker. The connection URL is configured in a property file:
<bean id="httpFooBarServiceProxy"
class="org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean">
<property name="serviceUrl" value="${serverURI}/
FooBarService-httpinvoker.rpc" />
<property name="serviceInterface">
<value>foo.bar.service.Interface</value>
</property>
<property name="httpInvokerRequestExecutor">
<bean
class="org.springframework.remoting.httpinvoker.CommonsHttpInvokerRequestExecutor" />
</property>
</bean>
All OK, but now our partner would like to use it over HTTPS to reach the service running on his Weblogic 10.3 server.
As far as I know the application can remain unchanged, he only has to import the certificate (?) into a keystore (?) and change the protocol in the url in the property file. Can you confirm this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是的,因为您已经在使用支持 https 的
CommonsHttpInvokerRequestExecutor
。Yes, since you are already using
CommonsHttpInvokerRequestExecutor
which has support for https.