⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme

📁 java开源的企业总线.xmlBlaster
💻
字号:
## xmlBlaster/demo/javaclients/cluster/firewall/README# xmlBlaster@marcelruff.info 2003/12/06#Example of a slave xmlBlaster cluster node 'frodo' running behinda firewall which allows outbound socket connection only.On the outside we have a master xmlBlaster cluster node 'heron': clientA -+                                          +- clientX          |                                          |  ...     +-> frodo ---SOCKET---|firewall|--> heron -+- ...          |                                          | clientN -+                                          +- clientYWe have configured frodo to use the SOCKET protocl to connectto heron. This allows to tunnel back update() messages usingthe same outbound socket connection.It is important that we configure heron to be the master of allmessages (see frodo.properties).Note that heron does NOT connect to frodo (the firewall wouldnot allow it).Current drawback: frodo can't be master of some message topicsas heron would in this case try to establish a connection,this issue would need some coding in xmlBlaster (if heron isconnected by frodo already try to reuse the socket connection).If the firewall only allows http with proxies inbetween thissetup won't help. You need to switch to email protocol orreuse the applet code which can handle this.Try the example:================First we do this on the same machine.Open 5 xterm (or DOS boxes) and change to directory  xmlBlaster/demo/javaclients/cluster/firewallStart heron (the master):  java org.xmlBlaster.Main -propertyFile heron.properties  Note that heron is configured with xmlBlasterPluginsSimple.xml  (see heron.properties) to be very simple to avoid too much  logging output and to avoid port conflicts as we run on the  same machine as frodo.  Start frodo (the slave):   java org.xmlBlaster.Main -propertyFile frodo.properties  Note that frodo runs in default mode with all protocol drivers  switched on. Look at the logging output and see how frodo  connects to heron with the SOCKET protocol.Start a publisher (which connects to frodo):  java javaclients.HelloWorldPublish -numPublish 100 -oid ClusterTest -session.name publisherToFrodo/1  This publisher connects to frodo and each time you press the enter key  a message is published to frodo and forwarded to heronStart a subscriber (which connects to frodo):  java javaclients.HelloWorldSubscribe -oid ClusterTestStart a subscriber (which connects to heron):  java javaclients.HelloWorldSubscribe -oid ClusterTest -protocol SOCKET -dispatch/connection/plugin/socket/port 8900 -session.name subscriberAtHeronTry the example behind a firewall:==================================You need to edit frodo.properties and replace the socket addresswith the IP (or DNS hostname) where heron is running on,for example change   socket://:8900\   to   socket://myServer.myCompany.com:8900\and start the second subscriber with this address as well:   java javaclients.HelloWorldSubscribe \         -oid ClusterTest \         -protocol SOCKET \         -dispatch/connection/plugin/socket/hostname myServer.myCompany.com \         -dispatch/connection/plugin/socket/port 8900 \         -session.name subscriberAtHeronNote that the only port which needs to be opened through the firewallis the outgoing port 8900 to the server myServer.myCompany.comMaking it secure:=================If you want to secure the communicationjust make a ssh connection from the frodo hostto the heron host and tunnel the SOCKET connectionthrough it.In this case frodo connects to the local side of thessh tunnel and the remote ssh deamon forwards everythingto heron.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -