如何在没有内置jetty的情况下运行cxf jax-ws(使用tomcat代替)

发布于 2024-12-27 05:14:13 字数 252 浏览 3 评论 0原文

每次当我在 tomcat 中运行以下内容时,cxf 内置码头就会启动并满足请求。

<jaxws:endpoint 
    id="wsServer"
    implementor="a.b.c.ServiceImpl"
    address="http://localhost:8080/ws">
</jaxws:endpoint>    

有什么办法让tomcat接收请求并委托给cxf吗?

every time when i run with the following inside tomcat, cxf build-in jetty is up and serving the request.

<jaxws:endpoint 
    id="wsServer"
    implementor="a.b.c.ServiceImpl"
    address="http://localhost:8080/ws">
</jaxws:endpoint>    

is there any way we have tomcat receiving the request and delegating to cxf?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

甜味拾荒者 2025-01-03 05:14:13

更新

您可以按照本文:在 web.xml 中使用 org.apache.cxf.transport.servlet.CXFServlet 并且不要忘记导入META-INF/cxf/cxf-servlet.xml

或者(如果 CXF 不是您必须的)您可以:

UPDATE

You can avoid using embedded Jetty by following this article: Use org.apache.cxf.transport.servlet.CXFServlet in your web.xml and don't forget to import META-INF/cxf/cxf-servlet.xml.

Alternatively (if CXF is not your must) you can:

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文