This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wrapper.java.additional.4=-Denv_name=prod | |
wrapper.java.additional.5=-Dmule.password=muleftw |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<context:property-placeholder properties-ref="MuleMeetZuul"/> | |
<spring:beans> | |
<zuul:properties id="MuleMeetZuul" config="AcmeProperties" host="localhost" port="8080" | |
context="/zuul-web-1.5" environment="#{environment['env_name']}"> | |
<zuul:file-store/> | |
<zuul:pbe-decryptor password="#{environment['mule.password']}" algorithm="PBEWITHSHA256AND128BITAES-CBC-BC"/> | |
</zuul:properties> | |
</spring:beans> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<mule xmlns:context="http://www.springframework.org/schema/context" | |
xmlns="http://www.mulesoft.org/schema/mule/core" | |
xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.2" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xmlns:zuul="http://www.devnull.org/schema/zuul-spring-client" | |
xsi:schemaLocation=" | |
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-current.xsd | |
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd | |
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd | |
http://www.devnull.org/schema/zuul-spring-client http://www.devnull.org/schema/zuul-spring-client.xsd"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
acme.jdbc.host=acmedb | |
acme.jdbc.port=3306 | |
acme.jdbc.database=acmeProducts | |
acme.jdbc.user=WileECoyote | |
acme.jdbc.password=GeeWhizz | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<scripting:component> | |
<scripting:script engine="groovy"> | |
<![CDATA[ | |
throw new org.mule.module.apikit.exception.NotFoundException("Product ID does not exist!"); | |
]]> | |
</scripting:script> | |
</scripting:component> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<apikit:mapping-exception-strategy name="acme-apiKitGlobalExceptionMapping"> | |
<apikit:mapping statusCode="404"> | |
<apikit:exception value="org.mule.module.apikit.exception.NotFoundException" /> | |
<set-property propertyName="Content-Type" value="application/json" /> | |
<set-payload value="{ "message": "Resource not found" }" /> | |
</apikit:mapping> | |
<apikit:mapping statusCode="405"> | |
<apikit:exception value="org.mule.module.apikit.exception.MethodNotAllowedException" /> | |
<set-property propertyName="Content-Type" value="application/json" /> | |
<set-payload value="{ "message": "Method not allowed" }" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<choice> | |
<when expression="#[payload.size != 0]"> | |
<!-- Add processing logic here --> | |
</when> | |
<otherwise> | |
<set-property propertyName="http.status" value="404"/> | |
<set-payload value="Quoth the server, 404"/> | |
</otherwise> | |
</choice> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<flow name="get:/products/{id}:acme-config" doc:name="get:/products/{id}:acme-config"> | |
<jdbc-ee:outbound-endpoint exchange-pattern="request-response" queryKey="GetProductByID" queryTimeout="-1" doc:name="Database"> | |
<jdbc-ee:query key="GetProductByID" value="SELECT * FROM Products WHERE ID=#[flowVars['id']]"/> | |
</jdbc-ee:outbound-endpoint> | |
<!-- add transformation logic here --> | |
</flow> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<flow name="get:/products/{id}:acme-config" doc:name="get:/products/{id}:acme-config"> | |
<set-payload value="#[NullPayload.getInstance()]" doc:name="Set Payload"/> | |
</flow> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#%RAML 0.8 | |
--- | |
title: Acme REST API | |
version: v0.1 | |
baseUri: http://localhost:8081/acme/{version} | |
/products/{id}: | |
displayName: Product | |
get: | |
description: Get Product by ID |
NewerOlder