SOAP+WSDL 以外的标准来实现 SOA
我读了这个问题
但是我仍然不清楚什么是另一种方法是不使用 SOAP/WSDL 等技术来实现 SOA 架构。 我正在开发部署到 websphere 和 weblogic 应用程序服务器的应用程序。如果您能给出与此类环境相关的示例,将会更有帮助。
I read this question
However I am still not clear what are the other way to implement a SOA architecture with out using technologies like SOAP/WSDL.
I am working on applications deployed to websphere and weblogic app server. It would be more helpful if you can give example related to such kind of environments.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以使用 RESTful 服务而不是 SOAP/WSDL...
You can use RESTful services instead of SOAP/WSDL...
首先要明确SOA。许多人认为,如果您使用SOA,那么您就必须拥有Web 服务。我认为这是错误的。 SOA 由许多称为服务的独立原子模块组成。现在,您必须在内部(意味着您的应用程序内部)和外部(您的应用程序外部)公开用于访问这些服务的端点。
您可以通过多种方式公开 SOA 服务的端点:
我们使用(JAVA 中的)JBoss jBPM、JBoss Drools 和 JMS/ActiveMQ 构建了 SOA。根据我们对特定服务的要求,我们有不同的服务端点。例如,某些服务需要定期发布数据,因此我们将这些服务创建为 Web 服务、自定义 XML 架构请求/响应(有些是 JSON)。有些服务没有暴露在应用程序之外,这些服务具有 RMI 端点或 JMS 队列/主题等。有些服务可以使用简单的方法调用(VM 端点)来调用。
以PersistenceService为例。它负责管理数据库访问和其他操作。所以,SOA中任何服务想要访问数据库,都需要使用PersistenceService。由于该服务对于最终用户(或者我们可以说在应用程序之外)并不重要,因此您可以使用直接方法调用(VM 端点)、RMI 存根/骨架、创建 JMS 队列/主题来公开该服务的端点 现在,我们有UserManagementService,它负责用户管理任务,
如身份验证、授权、管理角色等。您的应用程序将使用它来登录/注销,例如来自用户。因此,您可以将其公开为 Web 服务,或者自定义 XML 架构请求/响应。
因此,我们可以说 SOA 服务在应用程序内部和应用程序外部使用。取决于它的端点不同。服务的端点将取决于您想要使用该服务的方式。
谢谢。
更新:
是的,我完全同意你的观点。但正如您所说,对于作为业务功能提供的服务来说确实如此。但是您可以在应用程序的环境中应用相同的 SOA 服务概念。您可以以 SOA 方式设计应用程序,以便应用程序中的所有服务都可以像单独的 SOA 服务一样运行,无论它们是应用程序的公共服务还是核心服务(例如 PersistenceService、ReportingService、LoggingService 等)。这样您还可以对应用程序进行集群在服务层面(业务服务以及核心服务),服务分布在不同的节点上。顺便说一句(我知道),这不是你问题的答案。您可以使用自定义 XML 请求/响应来替代 Web 服务。
First be clear about SOA. Many people thinks, you are using SOA then you must have web services. I think that is wrong. SOA consist of many individual, atomic modules known as service. Now, you have to expose endpoints for accessesing those service in(means inside your application) and out(out side your application).
There are many ways by which you can expose end point of your SOA service:
We have build a SOA using (in JAVA)JBoss jBPM, JBoss Drools and JMS/ActiveMQ. We have different end points of our services as per our requirement of specific service. Like, some service need to publish data regularly, so we have created those service as web services, custom XML schema requests/response(some where JSON). Some services are not exposed out side of application, those have endpoints of RMI, or JMS queue/topic etc. Some service can be called using simple method call(VM endpoints).
Take PersistenceService for example. It is responsible for managing database access and other operations. So, any service in SOA want database access, need to use PersistenceService. Since, this service is not important for end user (or we can say out side of application), you can expose end points of that service using direct method call(VM end points), RMI stub/skeleton, create a JMS queue/topic on which it is listening on etc.
Now, we have UserManagementService that is responsible for user managemet tasks like authenticate, authorize, manage role etc. It will be used by your application for login/logout like stuff from user. So, you can expose it as a web service or you custome XML schema request/response.
So, we can say that SOA services are used inside your application and out side of application. Depends on that its endpoints differes. End points of services will depend on the way you want to use that service.
Thanks.
UPDATE:
Yes, I totally agree with you. But that is true for services that are available as a business functions as you said. But you can apply the same SOA service concepts inside environment of your application. You can design your application in SOA way such that all services in your appliacation can behave like individual SOA service whether they are public service or core service of your application(like PersistenceService, ReportingService, LoggingService et.) This way you can also cluster you application at service level(business service as well as core services) where services are distributed at different nodes. By the way(I know), this is not your questions's answer. You can use your custom XML request/response as a replcement of web services.