diff --git a/edi-x12-as2/camel/edi-x12-as2.camel.yaml b/edi-x12-as2/camel/edi-x12-as2.camel.yaml index f7cf18c..95bb540 100644 --- a/edi-x12-as2/camel/edi-x12-as2.camel.yaml +++ b/edi-x12-as2/camel/edi-x12-as2.camel.yaml @@ -1,5 +1,19 @@ - routeConfiguration: id: as2Error + onException: + - onException: + exception: + - java.lang.Exception + handled: + constant: + expression: "true" + steps: + - script: + expression: + groovy: + expression: "httpContext = exchangeProperties['CamelAs2.interchange']\n\ + httpContext.setAttribute(org.apache.camel.component.as2.api.AS2Header.DISPOSITION_TYPE,\ + \ \n org.apache.camel.component.as2.api.entity.AS2DispositionType.FAILED)\n" - route: id: receivePurchaseOrder routeConfigurationId: as2Error @@ -11,18 +25,6 @@ requestUriPattern: /mycorp/orders serverPortNumber: 8081 steps: - - onException: - exception: - - java.lang.Exception - handled: - constant: - expression: "true" - - script: - expression: - groovy: - expression: "httpContext = exchangeProperties['CamelAs2.interchange']\n\ - httpContext.setAttribute(org.apache.camel.component.as2.api.AS2Header.DISPOSITION_TYPE,\ - \ \n org.apache.camel.component.as2.api.entity.AS2DispositionType.FAILED)\n" - to: uri: jms parameters: @@ -89,7 +91,7 @@ as2From: mycorp as2MessageStructure: PLAIN as2To: acme - ediMessageCharset: charset=US-ASCII + ediMessageCharset: US-ASCII ediMessageContentType: application/edi-x12 from: bob@example.org inBody: ediMessage diff --git a/ftp/application.properties b/ftp/application.properties index 97f3dda..128c508 100644 --- a/ftp/application.properties +++ b/ftp/application.properties @@ -19,3 +19,6 @@ camel.beans.poolCF.connectionIdleTimeout = 20000 camel.component.jms.connection-factory = #bean:poolCF camel.jbang.classpathFiles=application.properties + +# Additional dependencies required at runtime (comma separated) +camel.jbang.dependencies=jakarta.inject:jakarta.inject-api:2.0.1,jakarta.enterprise:jakarta.enterprise.cdi-api:4.1.0 diff --git a/ftp/jbang.properties b/ftp/jbang.properties index a86794f..06e387f 100644 --- a/ftp/jbang.properties +++ b/ftp/jbang.properties @@ -1,3 +1,2 @@ -# Declare required additional dependencies for testing -run.deps=jakarta.inject:jakarta.inject-api:2.0.1,\ -jakarta.enterprise:jakarta.enterprise.cdi-api:4.1.0 +# Additional runtime dependencies are declared via camel.jbang.dependencies +# in application.properties (Camel JBang natively supports comma separated lists). diff --git a/openapi/server/petstore.camel.yaml b/openapi/server/petstore.camel.yaml index 155dd3d..78afa9e 100644 --- a/openapi/server/petstore.camel.yaml +++ b/openapi/server/petstore.camel.yaml @@ -1,3 +1,6 @@ +- restConfiguration: + clientRequestValidation: true + apiContextPath: openapi - rest: openApi: specification: petstore-api.json