Apache ServiceMix

来自开放百科 - 灰狐
跳转到: 导航, 搜索
Apache-servicemix.png

ServiceMix是一个开源的 ESBSOA 工具集, 支持 SUN JSP 208规范: Java Business Integration(JBI), 采用 Apache 许可协议.

其JBI的核心总线结构支持插件操作。

ServiceMix 已完整集成进 Apache Geronimo 里。

Wikipedia-35x35.png 您可以在Wikipedia上了解到此条目的英文信息 Apache ServiceMix Thanks, Wikipedia.

目录

Apache ActiveMQ

ServiceMix uses ActiveMQ to provide remoting, clustering, reliability and distributed failover.

Apache Camel

The servicemix-camel component provides support for using Apache Camel to provide a full set of Enterprise Integration Patterns and flexible routing and transformation in both Java code or Spring XML to route services on the Normalized Message Router.

Apache CXF

ServiceMix CXF SE component is a JBI Service Engine exposing (annotated) POJO as services on the JBI Bus. It uses Apache CXF internally to perform service invocations and xml marshaling.

Hyperic HQ

Use Hyperic HQ to monitor ServiceMix

Activiti

BPM 引擎由 Activiti 提供。

ServiceMix 6

ServiceMix 5

ServiceMix 4

ServiceMix 4 Runtime 基于 OSGi 构建, 将使用 Apache Felix can download OSGi bundles dynamically from Maven repos,OSGi的核心是 Apache Karaf

More detail: http://servicemix.apache.org/SMX4/

./servicemix
[email protected]> admin:create huihoo // 创建一个实例
[email protected]> admin:start huihoo //启动实例
[email protected]> admin:connect huihoo //连接实例
[email protected]>  
[email protected]> ls
[email protected]> help
[email protected]> osgi:list
[email protected]> osgi:list | grep camel
[email protected]> features:list | grep camel
[email protected]> features:install camel-xmpp
[email protected]> log:display
[email protected]> log:display-exception
[email protected]> log:set DEBUG
[email protected]> log:display | grep DEBUG
[email protected]> shell:logout // 退出
[email protected]> features:install wrapper
[email protected]> wrapper:install --help
[email protected]> wrapper:install -s AUTO_START -n KARAF -d Karaf -D "Karaf Service"
apache-servicemix-4.4.1/bin/KARAF-service start
apache-servicemix-4.4.1/bin/KARAF-service stop

Web Console

[email protected]> features:install webconsole
http://localhost:8181/system/console // user:password smx:smx, in etc/system.properties 

ActiveMQ Web Console

[email protected]> features:install activemq-web-console
[email protected]> web:list
http://localhost:8181/activemqweb

Install Web App

[email protected]> install war:mvn:org.apache.wicket/wicket-examples/1.4.7/war?Web-ContextPath=wicket
[email protected]> osgi:start 218 
http://localhost:8181/wicket 

Console Commands:

activemq:browse            activemq:bstat             activemq:create-broker
activemq:destroy-broker    activemq:list              activemq:purge
activemq:query             admin:change-port          admin:connect
admin:create               admin:destroy              admin:list
admin:start                admin:stop                 config:cancel
config:edit                config:list                config:propappend
config:propdel             config:proplist            config:propset
config:update              dev:dynamic-import         dev:framework
dev:show-tree              features:addUrl            features:install
features:list              features:listUrl           features:refreshUrl
features:removeUrl         features:uninstall         jbi:list
jbi:shutdown               jbi:start                  jbi:stop
log:display                log:display-exception      log:get
log:set                    nmr:list                   obr:addUrl
obr:deploy                 obr:info                   obr:list
obr:listUrl                obr:refreshUrl             obr:removeUrl
obr:source                 obr:start                  osgi:bundle-level
osgi:headers               osgi:install               osgi:list
osgi:ls                    osgi:refresh               osgi:resolve
osgi:restart               osgi:shutdown              osgi:start
osgi:start-level           osgi:stop                  osgi:uninstall
osgi:update                packages:exports           packages:imports
shell:cat                  shell:clear                shell:each
shell:echo                 shell:exec                 shell:grep
shell:if                   shell:info                 shell:java
shell:printf               shell:sleep                shell:sort
shell:tac                  ssh:ssh                    ssh:sshd
wrapper:install

ServiceMix 3

ServiceMix 2

Components list

ServiceMix currently has the following JBI components:

  • servicemix-bean
  • servicemix-camel
  • servicemix-cxf-bc
  • servicemix-cxf-se
  • servicemix-drools
  • servicemix-eip
  • servicemix-file
  • servicemix-ftp
  • servicemix-http
  • servicemix-jms
  • servicemix-jsr181
  • servicemix-lwcontainer
  • servicemix-mail
  • servicemix-osworkflow
  • servicemix-quartz
  • servicemix-saxon
  • servicemix-script
  • servicemix-scripting
  • servicemix-smpp
  • servicemix-snmp
  • servicemix-validation
  • servicemix-vfs
  • servicemix-wsn2005
  • servicemix-xmpp

安装指南

获得 http://download.huihoo.com/apache/servicemix/
如: tar zxvf servicemix-2.0.2.tar.gz 

cd servicemix-2.0./bin

启动 servicemix

[email protected]:~/java/soa/servicemix-2.0.2/bin$ ./servicemix

ServiceMix ESB: 2.0.2
Loading ServiceMix from servicemix.xml on the CLASSPATH
04:04:29,647 INFO [JournalPersistenceAdapter] Opening journal.
04:04:29,727 INFO [JournalPersistenceAdapter] Opened journal: Active Journal: using 2 x 20.0 Megs at: ../var/ journal
04:04:29,727 INFO [JournalPersistenceAdapter] Journal Recovery Started.
04:04:29,803 INFO [JournalPersistenceAdapter] Journal Recovered: 0 message(s) in transactions recovered. 

测试

[email protected]:~/java/soa/servicemix-2.0.2/examples/basic$ /home/huihoo/java/soa/servicemix-2.0.2/bin/servicemix servicemix.xml

ServiceMix ESB: 2.0.2

Loading ServiceMix from file: servicemix.xml
13:24:50,580 INFO [JournalPersistenceAdapter] Opening journal.
13:24:50,897 INFO [JournalPersistenceAdapter] Opened journal: Active Journal: using 2 x 20.0 Megs at: ../var/journal
13:24:50,897 INFO [JournalPersistenceAdapter] Journal Recovery Started.
13:24:50,984 INFO [JournalPersistenceAdapter] Journal Recovered: 0 message(s) in transactions recovered.
13:24:51,228 INFO [JCAContainer] Jencks JCA Container (http://jencks.org/) has started running version: 1.1.1
13:24:51,993 INFO [JCAConnector] Activating endpoint for activationSpec: ActiveMQActivationSpec{acknowledgeMode='Auto-acknowledge',
 destinationType='javax.jms.Topic', messageSelector='null', destination='demo.org.servicemix.source', clientId='null',  
subscriptionName='null', subscriptionDurability='NonDurable'} using endpointFactory: 

[email protected][transactionManager= org[email protected]168989e]

13:24:52,195 INFO [JCAConnector] Activating endpoint for activationSpec: ActiveMQActivationSpec{acknowledgeMode='Auto-acknowledge', 
destinationType='javax.jms.Topic', messageSelector='null', destination='demo.org.servicemix.result', clientId='null',   
subscriptionName='null', subscriptionDurability='NonDurable'} using endpointFactory: 

[email protected][transactionManager= org[email protected]168989e] 13:24:52,606 DEBUG [XAEndpoint] Transaction started and resource enlisted 13:24:52,697 DEBUG [XAEndpoint] Transaction committed ....... 测试报告

[email protected]:~/java/soa/servicemix-2.0.2/examples/basic/target/test-reports$ ls
more activemq-test.log
2006-04-22 13:24:52,606 [Thread-14 ] DEBUG XAEndpoint - Transaction started and resource enlisted
2006-04-22 13:24:52,697 [Thread-14 ] DEBUG XAEndpoint - Transaction committed
2006-04-22 13:24:52,791 [Thread-19 ] DEBUG XAEndpoint - Transaction started and resource enlisted
2006-04-22 13:24:52,847 [Thread-19 ] DEBUG XAEndpoint - Transaction committed
..... 

图集

链接

Comment-32x32.png

<discussion>characters_max=300</discussion>

分享您的观点
个人工具
名字空间

变换
操作
导航
工具箱