]
Brian Fitzpatrick updated JBIDE-11068:
--------------------------------------
Fix Version/s: 3.3.0.CR1
Wrong error: This parameter type
(javax.servlet.http.HttpServletRequest) cannot be annotated with @Context
----------------------------------------------------------------------------------------------------------
Key: JBIDE-11068
URL:
https://issues.jboss.org/browse/JBIDE-11068
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: Webservices
Affects Versions: 3.3.0.Beta1
Environment: Win7 64bit
Eclipse 3.7.2 64bit
JBoss JAX-RS
Tools 1.2.2.v20120217-1720-H797-Beta1 org.jboss.tools.ws.jaxrs.feature.feature.group JBoss
by Red Hat
JBoss Maven
Integration 1.3.0.v20120215-1811-H563-Beta1 org.jboss.tools.maven.feature.feature.group JBoss
by Red Hat
JBoss Maven JAX-RS
Configurator 1.3.0.v20120215-1811-H563-Beta1 org.jboss.tools.maven.jaxrs.feature.feature.group JBoss
by Red Hat
JBoss WebServices
Tools 1.2.2.v20120217-1720-H797-Beta1 org.jboss.tools.ws.feature.feature.group JBoss by
Red Hat
Reporter: Ron Ratovsky
Assignee: Xavier Coulon
Fix For: 3.3.0.CR1
Upon checking in the channel with maxandersen, he found that the following code is
related:
* Validates that the method parameters annotated with {@link Context} are of the
supported types in the spec:
* {@link UriInfo}, {@link HttpHeaders}, {@link ServletConfig}, {@link ServletContext},
{@link HttpServletRequest},
* {@link Request}, {@link HttpServletResponse} and {@link Response}
ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsResourceMethod.java
According to the above javadoc, @Context is legal with HttpServletRequest.
However, the plugin produces an error on the following line of code (for example):
public Response get(@Context HttpServletRequest
requestContext, @PathParam(EntitiesRestConsts.PARAM_ID) ObjectId id) {
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: