[ 
https://issues.apache.org/jira/browse/STANBOL-1335?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14176794#comment-14176794
 ] 

Rupert Westenthaler commented on STANBOL-1335:
----------------------------------------------

Hi

IMO a Filter that handles all CORS request the same way is fine. I would 
however prefer a Servlet Filter over a JAX-RS filter. Servlet Filters can be 
simple registered as OSGI service (whiteboard pattern). You can take [1] as an 
example.

BTW: do not forget to set the version range for the servlet packages in the 
pom.xml to 

{code}
    <Import-Package>
        javax.servlet.*; version="[2.5.0,4.0.0)",
        *
    </Import-Package>
{code}

As not all users do need cors support I suggest to create a separate module 
(commons.cors) that provide this filter.

Thx Christian for taking on this Issue
best
Rupert

[1] 
http://svn.apache.org/repos/asf/stanbol/trunk/commons/httpqueryheaders/src/main/java/org/apache/stanbol/commons/httpqueryheaders/impl/QueryHeadersFilter.java

> Re-enable CORS support
> ----------------------
>
>                 Key: STANBOL-1335
>                 URL: https://issues.apache.org/jira/browse/STANBOL-1335
>             Project: Stanbol
>          Issue Type: Sub-task
>            Reporter: Rupert Westenthaler
>             Fix For: 1.0.0
>
>
> The Stanbol trunk currently does not support CORS as the old code used in 
> 0.12 is deactivated and the proposed solution - by using a Servlet Filter - 
> was not yet implemented.
> Workaround: Use the 0.12.0 release or the 0.12-releasing branch version



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to