[jira] [Resolved] (CAMEL-8122) camel:run using useBlueprint option does not launch camel example project
[ https://issues.apache.org/jira/browse/CAMEL-8122?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Charles Moulliard resolved CAMEL-8122. -- Resolution: Fixed Issue not longer there after doing a mvn clean install of camel-2.15-SNAPSHOT project camel:run using useBlueprint option does not launch camel example project --- Key: CAMEL-8122 URL: https://issues.apache.org/jira/browse/CAMEL-8122 Project: Camel Issue Type: Bug Components: examples Affects Versions: 2.15.0 Reporter: Charles Moulliard When we launch the maven camel:run goal with the camel-example-sql-blueprint, the camel project is not started and this OSGI Service error is reported. I suspect that some bundles are missing and not loaded by the PoJoSr classloader when the project is started/launched by the camel-maven-plugin See line of code {code} package org.apache.camel.maven; ... public class RunMojo extends AbstractExecMojo { ... } else if (usingBlueprintMain) { mainClass = org.apache.camel.test.blueprint.Main; // must include plugin dependencies for blueprint extraPluginDependencyArtifactId = camel-test-blueprint; {code} Error reported on the console {code} Caused by: java.lang.RuntimeException: Gave up waiting for service (objectClass=org.apache.camel.CamelContext) [INFO] --- camel-maven-plugin:2.15-SNAPSHOT:run (default-cli) @ camel-example-sql-blueprint --- [INFO] Using org.apache.camel.test.blueprint.Main to initiate a CamelContext [INFO] Starting Camel ... [mel.test.blueprint.Main.main()] MainSupportINFO Apache Camel 2.15-SNAPSHOT starting [mel.test.blueprint.Main.main()] Activator INFO Camel activator starting [mel.test.blueprint.Main.main()] Activator INFO Camel activator started [mel.test.blueprint.Main.main()] BlueprintExtender INFO No quiesce support is available, so blueprint components will not participate in quiesce operations [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN Test bundle headers: Bundle-ManifestVersion=2, Bundle-Name=System Bundle, Bundle-SymbolicName=de.kalpatec.pojosr.framework, Bundle-Vendor=kalpatec, Bundle-Version=0.2.1 [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.camel.spi.TypeConverterLoader], bundle: org.apache.camel.camel-core [3], symbolicName: org.apache.camel.camel-core [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.camel.camel-blueprint [2], symbolicName: org.apache.camel.camel-blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.proxy.ProxyManager], bundle: org.apache.aries.proxy.impl [19], symbolicName: org.apache.aries.proxy.impl [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ConfigurationAdmin], bundle: org.apache.felix.configadmin [28], symbolicName: org.apache.felix.configadmin [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.felix.cm.PersistenceManager], bundle: org.apache.felix.configadmin [28], symbolicName: org.apache.felix.configadmin [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ManagedServiceFactory], bundle: org.apache.felix.fileinstall [29], symbolicName: org.apache.felix.fileinstall [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ConfigurationListener, org.apache.felix.fileinstall.ArtifactListener, org.apache.felix.fileinstall.ArtifactInstaller], bundle: org.apache.felix.fileinstall [29], symbolicName: org.apache.felix.fileinstall [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.url.URLStreamHandlerService], bundle: org.apache.felix.fileinstall [29],
[jira] [Assigned] (CAMEL-8122) camel:run using useBlueprint option does not launch camel example project
[ https://issues.apache.org/jira/browse/CAMEL-8122?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Charles Moulliard reassigned CAMEL-8122: Assignee: Charles Moulliard camel:run using useBlueprint option does not launch camel example project --- Key: CAMEL-8122 URL: https://issues.apache.org/jira/browse/CAMEL-8122 Project: Camel Issue Type: Bug Components: examples Affects Versions: 2.15.0 Reporter: Charles Moulliard Assignee: Charles Moulliard When we launch the maven camel:run goal with the camel-example-sql-blueprint, the camel project is not started and this OSGI Service error is reported. I suspect that some bundles are missing and not loaded by the PoJoSr classloader when the project is started/launched by the camel-maven-plugin See line of code {code} package org.apache.camel.maven; ... public class RunMojo extends AbstractExecMojo { ... } else if (usingBlueprintMain) { mainClass = org.apache.camel.test.blueprint.Main; // must include plugin dependencies for blueprint extraPluginDependencyArtifactId = camel-test-blueprint; {code} Error reported on the console {code} Caused by: java.lang.RuntimeException: Gave up waiting for service (objectClass=org.apache.camel.CamelContext) [INFO] --- camel-maven-plugin:2.15-SNAPSHOT:run (default-cli) @ camel-example-sql-blueprint --- [INFO] Using org.apache.camel.test.blueprint.Main to initiate a CamelContext [INFO] Starting Camel ... [mel.test.blueprint.Main.main()] MainSupportINFO Apache Camel 2.15-SNAPSHOT starting [mel.test.blueprint.Main.main()] Activator INFO Camel activator starting [mel.test.blueprint.Main.main()] Activator INFO Camel activator started [mel.test.blueprint.Main.main()] BlueprintExtender INFO No quiesce support is available, so blueprint components will not participate in quiesce operations [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN Test bundle headers: Bundle-ManifestVersion=2, Bundle-Name=System Bundle, Bundle-SymbolicName=de.kalpatec.pojosr.framework, Bundle-Vendor=kalpatec, Bundle-Version=0.2.1 [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.camel.spi.TypeConverterLoader], bundle: org.apache.camel.camel-core [3], symbolicName: org.apache.camel.camel-core [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.camel.camel-blueprint [2], symbolicName: org.apache.camel.camel-blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.proxy.ProxyManager], bundle: org.apache.aries.proxy.impl [19], symbolicName: org.apache.aries.proxy.impl [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ConfigurationAdmin], bundle: org.apache.felix.configadmin [28], symbolicName: org.apache.felix.configadmin [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.aries.blueprint.NamespaceHandler], bundle: org.apache.aries.blueprint [17], symbolicName: org.apache.aries.blueprint [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.apache.felix.cm.PersistenceManager], bundle: org.apache.felix.configadmin [28], symbolicName: org.apache.felix.configadmin [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ManagedServiceFactory], bundle: org.apache.felix.fileinstall [29], symbolicName: org.apache.felix.fileinstall [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.cm.ConfigurationListener, org.apache.felix.fileinstall.ArtifactListener, org.apache.felix.fileinstall.ArtifactInstaller], bundle: org.apache.felix.fileinstall [29], symbolicName: org.apache.felix.fileinstall [mel.test.blueprint.Main.main()] CamelBlueprintHelper WARN ServiceReference: [org.osgi.service.url.URLStreamHandlerService], bundle: org.apache.felix.fileinstall [29], symbolicName: org.apache.felix.fileinstall
[jira] [Comment Edited] (CAMEL-8104) rest-dsl - Allow custom error responses as-is without invoking the output binding
[ https://issues.apache.org/jira/browse/CAMEL-8104?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235294#comment-14235294 ] Espen Tjonneland edited comment on CAMEL-8104 at 12/5/14 9:21 AM: -- I wonder if there is still missing some bits (pun intended) here. And I am guessing it is failing due to it being done inside an interceptor. Consider the following route def: {code} public class MyRestRouteDefs extends RouteBuilder { imports .; @Override public void configure() { . config stuff interceptFrom().id(Create an error) .bean(CreateAnError.class); //Sets up one interceptor that always creates an error message - just to clarify this issue restConfiguration().component(servlet).bindingMode(RestBindingMode.json) .contextPath(/MyContext/api/).port(8080); RestDefinition privateAPI = rest(ServiceConstants.PRIVATE_API_VERSION_1).description(Private (internal) REST services for MyServices.) .skipBindingOnErrorCode(true); //Not neccecary (for clarity) privateAPI.get(/fetchsomething).description(Lists stuff from some service) .outTypeList(MyPojoForSomething.class) .route().routeId(A descriptive ID) .choice() .when(header(ServiceConstants.REQUEST_VALIDATED).isEqualTo(TRUE)) .bean(GoAheadAndFillAMyPojoForSomething-into-body.class) .otherwise()); //Otherwise might not be needed. Added it there to show that it is a branching point. } } public class CreateAnError { imports .; @Handler public void createAnError (@Body Message requestMessage) { requestMessage.setHeader(ServiceConstants.REQUEST_VALIDATED, FALSE); requestMessage.setHeader(Exchange.HTTP_RESPONSE_CODE, HttpServletResponse.SC_FORBIDDEN); requestMessage.setHeader(Exchange.CONTENT_TYPE, text/plain); requestMessage.setBody(I raised this error inside an interceptor and just wanted to tell you about it); } } {code} This results in an error: {code} com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'Missing': was expecting ('true', 'false' or 'null') at [Source: java.io.ByteArrayInputStream@67618968; line: 1, column: 9] at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1419) {code} was (Author: espentj): I wonder if there is still missing some bits here. And I am guessing it is failing due to it being done inside an interceptor. Consider the following route def: {code} public class MyRestRouteDefs extends RouteBuilder { imports .; @Override public void configure() { . config stuff interceptFrom().id(Create an error) .bean(CreateAnError.class); //Sets up one interceptor that always creates an error message - just to clarify this issue restConfiguration().component(servlet).bindingMode(RestBindingMode.json) .contextPath(/MyContext/api/).port(8080); RestDefinition privateAPI = rest(ServiceConstants.PRIVATE_API_VERSION_1).description(Private (internal) REST services for MyServices.) .skipBindingOnErrorCode(true); //Not neccecary (for clarity) privateAPI.get(/fetchsomething).description(Lists stuff from some service) .outTypeList(MyPojoForSomething.class) .route().routeId(A descriptive ID) .choice() .when(header(ServiceConstants.REQUEST_VALIDATED).isEqualTo(TRUE)) .bean(GoAheadAndFillAMyPojoForSomething-into-body.class) .otherwise()); //Otherwise might not be needed. Added it there to show that it is a branching point. } } public class CreateAnError { imports .; @Handler public void createAnError (@Body Message requestMessage) { requestMessage.setHeader(ServiceConstants.REQUEST_VALIDATED, FALSE); requestMessage.setHeader(Exchange.HTTP_RESPONSE_CODE, HttpServletResponse.SC_FORBIDDEN); requestMessage.setHeader(Exchange.CONTENT_TYPE, text/plain); requestMessage.setBody(I raised this error inside an interceptor and just wanted to tell you about it); } } {code} This results in an error: {code} com.fasterxml.jackson.core.JsonParseException: Unrecognized token 'Missing': was expecting ('true', 'false' or 'null') at [Source: java.io.ByteArrayInputStream@67618968; line: 1, column: 9] at com.fasterxml.jackson.core.JsonParser._constructError(JsonParser.java:1419) {code} rest-dsl - Allow custom error responses as-is without invoking the output binding - Key: CAMEL-8104 URL:
[jira] [Commented] (CAMEL-7925) groovy and osgi - Could not initialize class script1413536396719697720774
[ https://issues.apache.org/jira/browse/CAMEL-7925?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235338#comment-14235338 ] Charles Moulliard commented on CAMEL-7925: -- Unfortunately no. I'm not even sure that a ticket has been logged. groovy and osgi - Could not initialize class script1413536396719697720774 - Key: CAMEL-7925 URL: https://issues.apache.org/jira/browse/CAMEL-7925 Project: Camel Issue Type: Bug Components: camel-groovy Environment: Apache Karaf 2.2.x Reporter: Charles Moulliard Assignee: Charles Moulliard Priority: Minor When a camel route is deployed on apache Karaf using a groovy expression to be evaluated we get this error https://gist.github.com/cmoulliard/7294122c47e9c18df399 Route {code} from(direct:launch).routeId(request-token) .onException(HttpOperationFailedException.class) .handled(true) .log(An error occurred) .to(direct:interface-status) .end() .setHeader(Exchange.HTTP_URI, constant(wayneUriGetSession)) .setHeader(Exchange.HTTP_QUERY, constant(User= + UserName + + Pass= + Password)) .setHeader(Exchange.HTTP_METHOD, constant(GET)) .to(https4://token-service) .convertBodyTo(String.class) .setHeader(token).groovy(body.replaceAll('\','')) {code} {code} Caused by: java.lang.NoClassDefFoundError: Could not initialize class script1413536396719697720774 at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)[:1.7.0_51] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)[:1.7.0_51] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)[:1.7.0_51] at java.lang.reflect.Constructor.newInstance(Constructor.java:526)[:1.7.0_51] at java.lang.Class.newInstance(Class.java:374)[:1.7.0_51] at org.apache.camel.language.groovy.GroovyExpression.instantiateScript(GroovyExpression.java:71) {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-7925) groovy and osgi - Could not initialize class script1413536396719697720774
[ https://issues.apache.org/jira/browse/CAMEL-7925?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235372#comment-14235372 ] Antoine DESSAIGNE commented on CAMEL-7925: -- I fear that {{DynamicImport-Package*/DynamicImport-Package}} will allow groovy script to use any class and services of the platform. With explicit imports you're sure that you won't access something you don't want to. What if you use instead {code:language=xml} DynamicImport-Packagegroovy.*, org.codehaus.groovy, org.codehaus.groovy.*/DynamicImport-Package {code} That way you limit to groovy groovy and osgi - Could not initialize class script1413536396719697720774 - Key: CAMEL-7925 URL: https://issues.apache.org/jira/browse/CAMEL-7925 Project: Camel Issue Type: Bug Components: camel-groovy Environment: Apache Karaf 2.2.x Reporter: Charles Moulliard Assignee: Charles Moulliard Priority: Minor When a camel route is deployed on apache Karaf using a groovy expression to be evaluated we get this error https://gist.github.com/cmoulliard/7294122c47e9c18df399 Route {code} from(direct:launch).routeId(request-token) .onException(HttpOperationFailedException.class) .handled(true) .log(An error occurred) .to(direct:interface-status) .end() .setHeader(Exchange.HTTP_URI, constant(wayneUriGetSession)) .setHeader(Exchange.HTTP_QUERY, constant(User= + UserName + + Pass= + Password)) .setHeader(Exchange.HTTP_METHOD, constant(GET)) .to(https4://token-service) .convertBodyTo(String.class) .setHeader(token).groovy(body.replaceAll('\','')) {code} {code} Caused by: java.lang.NoClassDefFoundError: Could not initialize class script1413536396719697720774 at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)[:1.7.0_51] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)[:1.7.0_51] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)[:1.7.0_51] at java.lang.reflect.Constructor.newInstance(Constructor.java:526)[:1.7.0_51] at java.lang.Class.newInstance(Class.java:374)[:1.7.0_51] at org.apache.camel.language.groovy.GroovyExpression.instantiateScript(GroovyExpression.java:71) {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-7925) groovy and osgi - Could not initialize class script1413536396719697720774
[ https://issues.apache.org/jira/browse/CAMEL-7925?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235402#comment-14235402 ] Charles Moulliard commented on CAMEL-7925: -- You will solve a part of the problem if you restrict the packages to be imported (as you propose). But as Groovy will generate class dynamically under the name script123456789, they will not be loaded and a classloading exception will take place for these classes. This is why until now, the trick to import dynamically everything. For sure, this is not a good thing as it breaks the OSGI modularity. groovy and osgi - Could not initialize class script1413536396719697720774 - Key: CAMEL-7925 URL: https://issues.apache.org/jira/browse/CAMEL-7925 Project: Camel Issue Type: Bug Components: camel-groovy Environment: Apache Karaf 2.2.x Reporter: Charles Moulliard Assignee: Charles Moulliard Priority: Minor When a camel route is deployed on apache Karaf using a groovy expression to be evaluated we get this error https://gist.github.com/cmoulliard/7294122c47e9c18df399 Route {code} from(direct:launch).routeId(request-token) .onException(HttpOperationFailedException.class) .handled(true) .log(An error occurred) .to(direct:interface-status) .end() .setHeader(Exchange.HTTP_URI, constant(wayneUriGetSession)) .setHeader(Exchange.HTTP_QUERY, constant(User= + UserName + + Pass= + Password)) .setHeader(Exchange.HTTP_METHOD, constant(GET)) .to(https4://token-service) .convertBodyTo(String.class) .setHeader(token).groovy(body.replaceAll('\','')) {code} {code} Caused by: java.lang.NoClassDefFoundError: Could not initialize class script1413536396719697720774 at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)[:1.7.0_51] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)[:1.7.0_51] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)[:1.7.0_51] at java.lang.reflect.Constructor.newInstance(Constructor.java:526)[:1.7.0_51] at java.lang.Class.newInstance(Class.java:374)[:1.7.0_51] at org.apache.camel.language.groovy.GroovyExpression.instantiateScript(GroovyExpression.java:71) {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-7945) SMPP connector as consumer stops camel context
[ https://issues.apache.org/jira/browse/CAMEL-7945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235425#comment-14235425 ] Claus Ibsen commented on CAMEL-7945: Yeah sure we love contributions http://camel.apache.org/contributing.html SMPP connector as consumer stops camel context -- Key: CAMEL-7945 URL: https://issues.apache.org/jira/browse/CAMEL-7945 Project: Camel Issue Type: Improvement Components: camel-smpp Affects Versions: 2.13.2 Reporter: Tomas Hanus Fix For: Future I try to use SMPP component as producer and consumer to send SMS and PUSH SMS (MMS) to SMSC/receive delivery notifications or SMS from mobile devices. But still if SMSC is down camel context will shut down, and also all other context, so camel cannot start up. Affect version is camel 2.13.2 and only consumer. Producer is OK and parameter lazySessionCreation=true works well, but not for consumer. Any idea how to solve that? Probably it has to do with CAMEL-3853 issue. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Created] (CAMEL-8126) PropertyInject does nothing for setter method
Daniel Pocock created CAMEL-8126: Summary: PropertyInject does nothing for setter method Key: CAMEL-8126 URL: https://issues.apache.org/jira/browse/CAMEL-8126 Project: Camel Issue Type: Bug Components: camel-core Affects Versions: 2.14.0 Environment: Linux, JDK1.7, standalone Camel/Spring J2SE process running in Eclipse Reporter: Daniel Pocock Using the annotation @PropertyInject on a field of the RouteBuilder class gives a NullPointerException public class RouteBuilder extends SpringRouteBuilder { @PropertyInject(foo.bar) private String fooBar; ... } Using the {{ }} notation in endpoint URIs is working though. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Created] (CAMEL-8125) PropertyInject gives NullPointerException
Daniel Pocock created CAMEL-8125: Summary: PropertyInject gives NullPointerException Key: CAMEL-8125 URL: https://issues.apache.org/jira/browse/CAMEL-8125 Project: Camel Issue Type: Bug Components: camel-core Affects Versions: 2.14.0 Environment: Linux, JDK1.7, standalone Camel/Spring J2SE process running in Eclipse Reporter: Daniel Pocock Using the annotation @PropertyInject on a field of the RouteBuilder class gives a NullPointerException public class RouteBuilder extends SpringRouteBuilder { @PropertyInject(foo.bar) private String fooBar; ... } Using the {{ }} notation in endpoint URIs is working though. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (CAMEL-8126) PropertyInject does nothing for setter method
[ https://issues.apache.org/jira/browse/CAMEL-8126?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Daniel Pocock updated CAMEL-8126: - Description: Using the annotation @PropertyInject on a setter method of the RouteBuilder class doesn't appear to set the value. public class RouteBuilder extends SpringRouteBuilder { private String fooBar; @PropertyInject(foo.bar) private void setFooBar(String fooBar) { this.fooBar = fooBar; } @Override public void configure() throws Exception { logger.info(foo.bar = {}, fooBar); } ... } The log output says fooBar = null Using the {{ }} notation in endpoint URIs is working though. was: Using the annotation @PropertyInject on a field of the RouteBuilder class gives a NullPointerException public class RouteBuilder extends SpringRouteBuilder { @PropertyInject(foo.bar) private String fooBar; ... } Using the {{ }} notation in endpoint URIs is working though. PropertyInject does nothing for setter method - Key: CAMEL-8126 URL: https://issues.apache.org/jira/browse/CAMEL-8126 Project: Camel Issue Type: Bug Components: camel-core Affects Versions: 2.14.0 Environment: Linux, JDK1.7, standalone Camel/Spring J2SE process running in Eclipse Reporter: Daniel Pocock Using the annotation @PropertyInject on a setter method of the RouteBuilder class doesn't appear to set the value. public class RouteBuilder extends SpringRouteBuilder { private String fooBar; @PropertyInject(foo.bar) private void setFooBar(String fooBar) { this.fooBar = fooBar; } @Override public void configure() throws Exception { logger.info(foo.bar = {}, fooBar); } ... } The log output says fooBar = null Using the {{ }} notation in endpoint URIs is working though. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-8126) PropertyInject does nothing for setter method
[ https://issues.apache.org/jira/browse/CAMEL-8126?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14235476#comment-14235476 ] Daniel Pocock commented on CAMEL-8126: -- I tried putting a breakpoint in the setter method. The method is never called (as opposed to the possibility that it was being invoked with a null argument) PropertyInject does nothing for setter method - Key: CAMEL-8126 URL: https://issues.apache.org/jira/browse/CAMEL-8126 Project: Camel Issue Type: Bug Components: camel-core Affects Versions: 2.14.0 Environment: Linux, JDK1.7, standalone Camel/Spring J2SE process running in Eclipse Reporter: Daniel Pocock Using the annotation @PropertyInject on a setter method of the RouteBuilder class doesn't appear to set the value. public class RouteBuilder extends SpringRouteBuilder { private String fooBar; @PropertyInject(foo.bar) private void setFooBar(String fooBar) { this.fooBar = fooBar; } @Override public void configure() throws Exception { logger.info(foo.bar = {}, fooBar); } ... } The log output says fooBar = null Using the {{ }} notation in endpoint URIs is working though. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-7841) Allow SpEL inside Camel URIs
[ https://issues.apache.org/jira/browse/CAMEL-7841?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14236214#comment-14236214 ] Marc Carter commented on CAMEL-7841: yes, its all functional locally but needs unpicking from other local customisations and testing to be presentable. i'll give it another look over soon with an eye to getting something visible for you to look at even if its not the finished article Allow SpEL inside Camel URIs Key: CAMEL-7841 URL: https://issues.apache.org/jira/browse/CAMEL-7841 Project: Camel Issue Type: Improvement Components: camel-spring Affects Versions: 2.14.0 Reporter: Marc Carter Fix For: Future The test for {{BridgePropertyPlaceholderConfigurer}} shows a very unrealistic example of putting some SpEL into a camel variable. This requires pre-declaring every such spel expression as you instantiate the bridge. Essentaily the SpEL is only evaluated when directly in the Spring context refresh. This bridge class can be ugraded to parse SpEL expressions dynamically as Camel requests properties allowing the usecases like: {code} .from(direct:dostuff) .wireTap( file:#{@runtime.dataPath}?fileName=${date:now:MMdd}.txt ) {code} In today's code the first part of URI cannot be paramterised. I'll submit a PR via github with my solution and example tests. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (CAMEL-7678) Update camel-rabbitmq URI for consumers
[ https://issues.apache.org/jira/browse/CAMEL-7678?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14236443#comment-14236443 ] Yap Poh Soon commented on CAMEL-7678: - [~davsclaus] I am using the latest release, v2.14.0. Update camel-rabbitmq URI for consumers --- Key: CAMEL-7678 URL: https://issues.apache.org/jira/browse/CAMEL-7678 Project: Camel Issue Type: Bug Components: camel-rabbitmq Affects Versions: 2.13.2 Reporter: Edward Ost The camel-rabbitmq requires a mandatory amqp exchange as the first parameter in the URI. Other options are specfied after the ?. This is appropriate for producers, but not for consumers. Subscribers should specify the queue name as the first parameter. -- This message was sent by Atlassian JIRA (v6.3.4#6332)