简体   繁体   English

使用JBoss EAP连接到套接字的Openshift

[英]Openshift connecting to a socket using JBoss EAP

I'm trying to connect to a socket using JBoss EAP in Openshift. 我正在尝试使用Openshift中的JBoss EAP连接到套接字。 I'm getting this error: 我收到这个错误:

ERROR (ServerService Thread Pool -- 70) Ping to [address.of.destination:10443] failed: Permission denied: java.net.SocketException: Permission denied
        at sun.nio.ch.Net.connect0(Native Method) [rt.jar:1.7.0_51]
        at sun.nio.ch.Net.connect(Net.java:465) [rt.jar:1.7.0_51]
        at sun.nio.ch.Net.connect(Net.java:457) [rt.jar:1.7.0_51]
        at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:670) [rt.jar:1.7.0_51]

I think the reason why is because Openshift blocks access to the port. 我认为原因是因为Openshift阻止了对端口的访问。

Also I'm under these conditions: 我也在这些条件下:

  • I can't change the port on the destination server, since it's not under my control. 我无法更改目标服务器上的端口,因为它不在我的控制之下。
  • the connection made to the server is made by the library I'm using, which means, it is writing the address and port by itself, so I cannot change the port on the code of the library because it's compiled code already. 与服务器建立的连接是由我正在使用的库创建的,这意味着它正在自己编写地址和端口,因此我无法更改库代码上的端口,因为它已经是已编译的代码。

Is there a work-around for this situation? 这种情况有解决办法吗?

It is possible to bind to the internal IP with port range between 15000 and 35530 https://www.openshift.com/kb/kb-e1038-i-cant-bind-to-a-port . 可以绑定到内部IP,端口范围在15000到35530之间https://www.openshift.com/kb/kb-e1038-i-cant-bind-to-a-port Also read http://blog-judcon.rhcloud.com/?p=97 另请阅读http://blog-judcon.rhcloud.com/?p=97

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM