Jetty Cross Origin Filter

Aloha,

I fought this for awhile as well, and found that the final node needs to be:

<filter-mapping>
    <filter-name>cross-origin</filter-name>
    <url-pattern>/*</url-pattern>
</filter-mapping>

NOT

<filter-mapping>
     <filter-name>cross-origin</filter-name>
     <filter-pattern>/*</filter-pattern>
</filter-mapping>

Here is the link I found to help me: wiki.eclipse.org/Jetty/Feature/Cross_Origin_Filter

After I updated my web.xml file and restarted the jetty server, I was able to make cross domain request using jQuery ajax calls.

Rob

Leave a Comment