users@glassfish.java.net

Using regular expressions with <url-pattern>?

From: <glassfish_at_javadesktop.org>
Date: Wed, 10 Dec 2008 22:38:50 PST

Hi,

I was wondering if it's possible to use regular expressions when specifying <url-pattern>, specifically the value of:

[code]<security-constraint>
  <web-resource-collection>
    <url-pattern>someValue</url-pattern>
  </web-resource-collection>
</security-constraint>[/code]

I am using JAX-RS so I have URLs such as:

http://example.com/rest/playlists/{id}/versions/{version}/

Realistically speaking I probably only need to specify a url-pattern of /rest/* but I was wondering if it's possible to match /rest/playlists/*/versions so the constraint only affects URLs under that path.

Thank you,
Gili
[Message sent by forum member 'cowwoc' (cowwoc)]

http://forums.java.net/jive/thread.jspa?messageID=321177