JAR/WAR/EAR 中的消息处理程序
我正在制作一个 PEP 服务器,它拦截 SOAP 消息,并根据单独数据库中定义的 WS-Policies 检查它们。它分为 3 个组件:
1) PEP(策略执行点)使用消息处理程序拦截消息
2) 将其发送到 -> 来决定哪个消息通过
PDP(策略决策点)通过使用具有策略数据库的 PIP(策略信息点)
3)。如果策略正确,消息将进一步发送到 Web 服务。现在我想知道如何将此 PEP 打包到 JAR 文件中(或 WAR/EAR?我对此很陌生,所以我不确定它应该放在哪种包中)。 PEP 是一个消息处理程序,因此 Web 服务必须指定 @HandlerChain(file = "handler.xml")
如果此 PEP 包含在 jar 文件中,现在是否可以将其包含在 xml 文件中?
I am making a PEP Server which intercepts the SOAP messages, and checks them against WS-Policies defined in a separate database. It is divided in 3 compontents:
1) PEP (Policy enforcemenet point) intercepts the messages with a message handler
2) sends it to the -> PDP (Policy decision point) decides which message gets through
3) this by using the PIP (Policy information point) which has a database with the policies.
If the policies are correct, the message gets send further to the web service. Now I was wondering how it would be possible to package this PEP in a JAR file (or WAR/EAR? I am new to this so I am not sure in which kind of package it should come). The PEP is a messagehandler, so the Web service will have to specify a @HandlerChain(file = "handler.xml")
Would it now be possible to include this PEP in the xml file, if its in contained in a jar file?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我建议使用 JAX-WS 来创建和调用 Java Web 服务。
有一个关于创建服务和调用该服务的客户端的很好的教程。就您而言,您希望将“简单的 JAX-WS 客户端”部分归零。他们概述了如何使用 NetBeans 执行此操作,但您可以了解总体思路,然后针对您的特定情况进行修改。
以下是教程的链接:使用 JAX 创建简单的 Web 服务和客户端- WS
我认为在您的情况下,您可以创建一个打包为 JAR 的 Java 客户端。
I recommend using JAX-WS for creating and invoking Java Web Services.
There's a nice tutorial about creating both a service and a client to invoke the service. In your case, you'd want to zero in on the "A Simple JAX-WS Client" section. They outline how to do this with NetBeans but you can get the general idea and then revamp for your particular situation.
Here's the link for the tutorial: Creating a Simple Web Service and Client with JAX-WS
I'm thinking in your situation that you can just create a Java client that gets packaged as a JAR.