camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralf Steppacher (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAMEL-9855) REST DSL rest configuration attribute enableCORS has no effect when rendering resource listing/Camel contexts
Date Mon, 11 Apr 2016 14:42:25 GMT

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

Ralf Steppacher commented on CAMEL-9855:
----------------------------------------

Unfortunately I cannot. My component dependes on activemq-camel which fails to deploy. With
Camel 2.17.0 both version 5.12.1 and 5.13.2 fail to install:

{noformat}
2016-04-11 16:39:55,914 | ERROR | pool-37-thread-1 | BlueprintContainerImpl           | 13
- org.apache.aries.blueprint.core - 1.4.5 |   | Unable to start blueprint container for bundle
org.apache.activemq.activemq-osgi/5.13.2
...
Caused by: java.lang.ClassNotFoundException: org.springframework.osgi.context.support.OsgiBundleXmlApplicationContext
not found by org.apache.activemq.activemq-osgi [53]
	at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1574)[org.apache.felix.framework-5.4.0.jar:]
	at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:79)[org.apache.felix.framework-5.4.0.jar:]
	at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:2018)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:357)[:1.8.0_77]
	... 39 more
{noformat}

> REST DSL rest configuration attribute enableCORS has no effect when rendering resource
listing/Camel contexts
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-9855
>                 URL: https://issues.apache.org/jira/browse/CAMEL-9855
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 2.16.3
>         Environment: Karaf 4.0.3, Java 8, Blueprint
>            Reporter: Ralf Steppacher
>            Priority: Minor
>
> Setting the attribute {{enableCORS}} to true has no effect, i.e. none of the {{Access-Control-*}}
are set. To enable CORS headers one has to add an {{apiProperty}} element like so:
> {code:xml}
> <restConfiguration contextPath="{{contextpath}}" component="jetty" scheme="http" host="{{host}}"
port="{{port}}" apiContextPath="api-docs">
>    <apiProperty key="cors" value="true" />
>    <!-- ... -->
> />
> </restConfiguration>
> {code}
> See {{RestSwaggerSupport::renderCamelContexts(...)}} and {{RestSwaggerSupport::renderResourceListing(...)}}.
> {{RestSwaggerSupport}} adds the headers with capital first letters: {{Access-Control-Allow-Origin}}.
However, the response contains the header names all lower case. Not sure where they loose
the capitalization. 



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

Mime
View raw message