Hi
I'm not able to reproduce this issue in my local snapshot.
I've modified the existing test, here is the output:

Address: http://localhost:9002/mkyong_webapp/services/rest/product/product_id
Encoding: ISO-8859-1
Http-Method: POST
Content-Type: application/x-www-form-urlencoded
Headers: {Accept=[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8,], Cache-Control=[no-cache], connection=[keep-alive], Content-Length=[7], content-type=[application/x-www-form-urlencoded], Host=[localhost:9002], Pragma=[no-cache], User-Agent=[Apache CXF 2.6.1-SNAPSHOT]}
Payload: id=MyId

--------------------------------------
MyId
26-Apr-2012 22:09:47 org.apache.cxf.interceptor.LoggingOutInterceptor
INFO: Outbound Message
---------------------------
ID: 1
Response-Code: 204
Content-Type: text/xml
Headers: {Date=[Thu, 26 Apr 2012 21:09:47 GMT], Content-Length=[0]}
--------------------------------------
26-Apr-2012 22:09:47 org.eclipse.jetty.server.handler.ContextHandler$Context log
INFO: Closing Spring root WebApplicationContext
26-Apr-2012 22:09:47 org.eclipse.jetty.server.handler.ContextHandler doStop
INFO: stopped o.e.j.w.WebAppContext{/mkyong_webapp,file:/home/sberyozkin/work/apache/cxf/trunk/systests/jaxrs/target/test-classes/jaxrs_soap_rest/},/home/sberyozkin/work/apache/cxf/trunk/systests/jaxrs/target/test-classes/jaxrs_soap_rest

where the test method is typed exactly the way you type it, with the context name, CXFServlet pattern, jaxrs:server/@address, root resource and method having the same path values.

I guess you have a slightly different case, probably Tomcat and the form is submitted from the HTML page, but to be honest it just has to work, I have few demos accepting form payloads...

Any chance you can create a simple Maven-based project for me to try ?

Sergey

On 26/04/12 14:03, imiten wrote:
Hi,

As I mentioned other urls are invoking methods fine.  Just the one with
@FormParam is having this issue.

CXFServlet urlpattern:
<servlet-mapping>
     <servlet-name>cxf</servlet-name>
     <url-pattern>/services/*</url-pattern>
   </servlet-mapping>


cxf-servlet.xml server:
<jaxrs:server id="myProductRest" address="/rest">
     <jaxrs:serviceBeans>
       <ref bean="myRestService" />
     </jaxrs:serviceBeans>
   </jaxrs:server>

My Rest Web Service:
@Path("/product")
@Features(features = "org.apache.cxf.feature.LoggingFeature")
public class ProductWebRest {

Regards,

Miten.


--
View this message in context: 
http://cxf.547215.n5.nabble.com/form-post-to-restful-service-not-finding-matching-method-tp5667389p5667558.html
Sent from the cxf-user mailing list archive at Nabble.com.


--
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com

Reply via email to