概述
Webservice专注于远程服务调用,jms专注于信息交换。
大多数情况下Webservice是两系统间的直接交互(Consumer <–> Producer),而大多数情况下jms是三方系统交互(Consumer <- Broker -> Producer)。当然,JMS也可以实现request-response模式的通信,只要Consumer或Producer其中一方兼任broker即可。
JMS可以做到异步调用完全隔离了客户端和服务提供者,能够抵御流量洪峰; WebService服务通常为同步调用,需要有复杂的对象转换,相比SOAP,现在JSON,rest都是很好的http架构方案;(举一个例子,电子商务的分布式系统中,有支付系统和业务系统,支付系统负责用户付款,在用户在银行付款后需要通知各个业务系统,那么这个时候,既可以用同步也可以用异步,使用异步的好处就能抵御网站暂时的流量高峰,或者能应对慢消费者。)
JMS是java平台上的消息规范。一般jms消息不是一个xml,而是一个java对象,很明显,jms没考虑异构系统,说白了,JMS就没考虑非java的东西。但是好在现在大多数的jms provider(就是JMS的各种实现产品)都解决了异构问题。相比WebService的跨平台各有千秋吧
U2FsdGVkX1+h8eFEXnuU415PZE2D4QKj2ibfwBlREg8Qx+bziBbJz7uSrpH2yz0O
onetFUxv8DEeXz8Ypawo3gH1vRIKKGPOeQuBO4Saez5HysZq5XNAh1Z3Q/FmCw/0
VFoByYN2/nWv4tL2qGP7GgN6ryyW6J8qHGx/UnoSkxzIRM6GBIqtcC8RzoKp/D8O
EW3z+1MJKS2WcPke7e4GIsFZczP23ZzHNR0pC+y0UKp5KWwZ+ipT/g8l1LM9ylB7
Y3TMC1S31v1F5saDEfAdpaPrtfv08bgvkYbOSil6ub5hH3KHZG0HZ54I49T7adVE
akseIFwMp9kKl/SyJdo8N7uSQjS8Emmny6w02ARP4hmGyK8OXPOCS3QkN8vwTy0K
O5Ycqbew81dKPPSh6mAeUA7ZMfdXNTAxHpVTk8OuaDJ8ZzbTN9390k2oBSTSRJfU
wF8mppvdjRUuVaujaZ08ei2HGVoFMJmDRYm4oZKgiqP6cQmL63GZdN/JDaKX4PNq
D1KuCOHmp2iqcnOfXvrUsK+6cMRDxKu2+bL5/9DvdwdX0xzLVUroDkBs0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Iy8m7E2tPH+VIiTNQH
mExp4qwCPv6bX2/84+XGdA==
最后
以上就是悦耳大船为你收集整理的webservice和jms的区别的全部内容,希望文章能够帮你解决webservice和jms的区别所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复