java - 为什么我不能在 ejb 模块中创建 RESTful Web 服务?

标签 java web-services

我正在使用 Netbeans 6.8。我可以在我的独立 ejb 模块中看到创建 Web 服务的选项,但我似乎无法在我的 ejb 模块中找到创建基于 RESTful 的 Web 服务的选项。 ejb 模块中是否有任何类型的限制,我只能创建基于 SOAP 的 Web 服务而不能创建 RESTful?还是Netbeans 6.8的bug?

最佳答案

EJB3 规范的第 2.6 章:

To support web service interoperability, the EJB specification requires compliant implementations to support XML-based web service invocations using WSDL and SOAP or plain XML over HTTP incon- formance with the requirements of the JAX-WS[32], JAX-RPC[25], Web Services for JavaEE[31], and Web Services Metadata for the Java Platform [30] specifications.

换句话说:EJB3 只能作为 SOAP Web 服务公开。

关于java - 为什么我不能在 ejb 模块中创建 RESTful Web 服务?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2985108/

相关文章:

java - 位戳 {"error": "API key not found"} Code Response: 200

.net - SOA : WCF 中转换层的替代方案

java - 将 J2EE 网站中发生的错误(异常)映射到合适的错误消息的有效方法是什么?

java - 关于 Java 溢出的困惑

java - Web 服务与消息传递

java - 调用动态 Web 服务时出现 nosuchelementException

java - 在 Eclipse 中为 GWT 应用程序配置 Log 4j

java - 加密安装的应用程序和网络服务的方法

Java HttpClient NoSuchAlgorithmException

iPhone XML SOAP 请求或 .NET Web 服务