OSGi / Eclipse RCP 环境中的 Resteasy 客户端
我正在尝试在 Eclipse 中为 Resteasy 服务构建一个客户端。我认为这很简单 - 但 Resteasy 所做的很多魔力(例如查找 POJO 上的注释、加载 Resteasy 提供程序等)似乎都被 OSGi 类加载器破坏了。我花了相当多的时间来解决依赖关系和伙伴策略的问题,但我遇到了一个绊脚石。我将描述它,但最好的解决方案是为 Resteasy 客户端提供一组预先存在的 OSGi/Eclipse 插件。如果失败的话..
could not find writer for content-tyope application/xml type: com.company.Pojo
org.jboss.resteasy.client.ClientRequest.writeRequestBody(ClientRequest:473)
这是轻松的1.2.1.GA。
干杯,罗布。
I'm trying to build a client for a Resteasy service in Eclipse. I thought this would be simple - but a lot of the magic that Resteasy does (e.g. looking up annotations on POJOs, loading the Resteasy providers, etc.) seems to be broken by the OSGi class loader. I've spent quite a bit of time resolving the problems with dependencies and buddy policies, but I've come across a stumbling block. I'll describe it, but the best possible solution would be a pre-existing set of OSGi/Eclipse plugins for the resteasy client. Failing that..
could not find writer for content-tyope application/xml type: com.company.Pojo
org.jboss.resteasy.client.ClientRequest.writeRequestBody(ClientRequest:473)
This is resteasy 1.2.1.GA.
Cheers, Rob.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的 - 最终成功解决了这个问题,尽管这不是最优雅的解决方案。
采取的步骤:
Ok - managed to sort this in the end, although it's not the most elegant solution.
Steps to take: