Java Virtal Machine.net

[ News ] rss

March 19, 2010

Kohsuke Kawaguchi: Hudson Hackathon Day 1. Hudson Hackathon Day 1 is over, and I'm just back to the office.

More »

March 19, 2010

New process for subscribing/unsubscribing to jsr-314-open@jcp.org. My last blog entry about JSR-314-OPEN@JCP.ORG was over a year ago. This list is the official Expert Group (EG) mailing list on which the development of the JSR-314 specification (JSF 2.0) is discussed. The information on how to subscribe/unsubscri...

More »

March/2010
SunMonTueWedThuFriSat
 1 2 3 4 56
7 8 9 10 11 12 13
1415 16 17 18 19 20
21 222324252627
28293031   

[ Archives News
for 'Java Technology' ]

home > news > java technology > url patterns are more flexible in jersey than in the web.xml

URL patterns are more flexible in Jersey than in the web.xml

Rule of thumb: Avoid to use {variables} as the first path of a Jersey's @Path I am working on the Arena PUJ Project, a RESTful web-service to support PUJ competitions. We are in the early stages of the project but we already got some resources published on the web. Let me show you a few URL samples: An insecure GET method to read all competitions promoted by a JUG: GET /{competition_id}/homework Sample URL: http://fgaucho.dyndns.org:8080/arena-http/institution/cejug/competition curl -v -H "Accept: application/json" -XGET http://fgaucho.dyndns.org:8080/arena-http/institution/cejug/competition An insecure GET method to read all homeworks from a competition name: GET /{competition_id}/homework Sample URL: http://fgaucho.dyndns.org:8080/arena-http/PUJCE-08/homework curl -v -H "Accept: application/json" -XGET http://fgaucho.dyndns.org:8080/arena-http/PUJCE-08/homework A secure method for creating a new homework. In the PUJ business model, only professors can submit a homework. POST /{competition_id}/homework/{homework_id} Sample URL: http://fgaucho.dyndns.org:8080/arena-http/PUJCE-08/homework/newHomework curl -v -H "Accept: application/json" -XPOST http://fgaucho.dyndns.org:8080/arena-http/PUJCE-08/homework/newHomework The problem: you cannot map variables in the beggining of the path in the web.xml In Jersey, all the above URLs are valid, actually Jersey can also use regular expressions to map...


Date: September, 17 2009
Url: http://www.java.net/blog/felipegaucho/archive/2009/09/17/url-patterns-are-more-flexible-jersey-webxml


Others News

1 Comments to "URL patterns are more flexible in Jersey than in the web.xml" »

I am working on the Arena PUJ Project, a RESTful web-service to support PUJ competitions. We are in the early stages of the project but we already got some resources published on the web.
1.An insecure GET method to read all competitions promoted by a JUG.
2.An insecure GET method to read all homeworks from a competition name.
3.A secure method for creating a new homework. In the PUJ business model, only professors can submit a homework.
Comment by gingko — December 11, 2009

Leave a Reply

Name (required)
Mail (will not be published) (required)
Website
You don't see letters?

Enter the code shown above (required)


Related

  • Simple Flex Webapp ... form</servlet-name> <url-pattern>*.html</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>spring-flex</servlet-name> <url-pattern ...
©2002-2008Java-Virtual-Machine.net