refactor
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<pd:ProcessDefinition xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:pfx="http://www.demo.com/author" xmlns:pd="http://xmlns.tibco.com/bw/process/2003" xmlns:ns="http://www.tibco.com/pe/WriteToLogActivitySchema" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns2="http://www.tibco.com/pe/GenerateErrorActivity/InputSchema">
|
||||
<pd:ProcessDefinition xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:pfx="http://www.demo.com/author" xmlns:pd="http://xmlns.tibco.com/bw/process/2003" xmlns:pfx2="http://www.tibco.com/schemas/httpRequest/Resources/schemas/Schema.xsd2" xmlns:ns="http://www.tibco.com/pe/WriteToLogActivitySchema" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns2="http://www.tibco.com/pe/GenerateErrorActivity/InputSchema">
|
||||
<xsd:import namespace="http://www.demo.com/author" schemaLocation="/Resources/WSDL/WSDL.wsdl"/>
|
||||
<xsd:import namespace="http://www.tibco.com/schemas/httpRequest/Resources/schemas/Schema.xsd2" schemaLocation="/Resources/schemas/errorSchema.xsd"/>
|
||||
<pd:name>Processes/sql/author/SqlDELETE.process</pd:name>
|
||||
<pd:startName>Start</pd:startName>
|
||||
<pd:startType>
|
||||
@@ -17,7 +18,7 @@
|
||||
<pd:returnBindings>
|
||||
<root>
|
||||
<status>
|
||||
<xsl:value-of select="concat('author deleted, rows affected: ', $DeleteAuthor/jdbcUpdateActivityOutput/noOfUpdates)"/>
|
||||
<xsl:value-of select="concat('author deleted, rows affected: ', $Delete-Author/jdbcUpdateActivityOutput/noOfUpdates)"/>
|
||||
</status>
|
||||
</root>
|
||||
</pd:returnBindings>
|
||||
@@ -34,10 +35,12 @@
|
||||
</pd:endType>
|
||||
<pd:endX>681</pd:endX>
|
||||
<pd:endY>62</pd:endY>
|
||||
<pd:errorSchemas/>
|
||||
<pd:errorSchemas>
|
||||
<DeleteError ref="pfx2:root"/>
|
||||
</pd:errorSchemas>
|
||||
<pd:processVariables/>
|
||||
<pd:targetNamespace>http://xmlns.example.com/1719579163583</pd:targetNamespace>
|
||||
<pd:activity name="DeleteAuthor">
|
||||
<pd:activity name="Delete Author">
|
||||
<pd:type>com.tibco.plugin.jdbc.JDBCUpdateActivity</pd:type>
|
||||
<pd:resourceType>ae.activities.JDBCUpdateActivity</pd:resourceType>
|
||||
<pd:x>424</pd:x>
|
||||
@@ -66,8 +69,8 @@
|
||||
<pd:activity name="Catch">
|
||||
<pd:type>com.tibco.pe.core.CatchActivity</pd:type>
|
||||
<pd:resourceType>ae.activities.catch</pd:resourceType>
|
||||
<pd:x>249</pd:x>
|
||||
<pd:y>164</pd:y>
|
||||
<pd:x>256</pd:x>
|
||||
<pd:y>328</pd:y>
|
||||
<pd:handler>true</pd:handler>
|
||||
<config>
|
||||
<catchAll>true</catchAll>
|
||||
@@ -77,20 +80,24 @@
|
||||
<pd:activity name="Generate Error">
|
||||
<pd:type>com.tibco.pe.core.GenerateErrorActivity</pd:type>
|
||||
<pd:resourceType>ae.activities.throw</pd:resourceType>
|
||||
<pd:x>514</pd:x>
|
||||
<pd:y>165</pd:y>
|
||||
<pd:x>516</pd:x>
|
||||
<pd:y>331</pd:y>
|
||||
<config>
|
||||
<faultName/>
|
||||
<faultName>DeleteError</faultName>
|
||||
</config>
|
||||
<pd:inputBindings>
|
||||
<ns2:ActivityInput>
|
||||
<message>
|
||||
<xsl:value-of select="string($Catch/exceptiondata)"/>
|
||||
</message>
|
||||
<data>
|
||||
<pfx2:root>
|
||||
<pfx2:error>
|
||||
<xsl:value-of select="'could not remove the author with given id, because it does not exist'"/>
|
||||
</pfx2:error>
|
||||
</pfx2:root>
|
||||
</data>
|
||||
</ns2:ActivityInput>
|
||||
</pd:inputBindings>
|
||||
</pd:activity>
|
||||
<pd:activity name="LogInputData">
|
||||
<pd:activity name="Log Input Data">
|
||||
<pd:type>com.tibco.pe.core.WriteToLogActivity</pd:type>
|
||||
<pd:resourceType>ae.activities.log</pd:resourceType>
|
||||
<pd:x>284</pd:x>
|
||||
@@ -106,12 +113,32 @@
|
||||
</ns:ActivityInput>
|
||||
</pd:inputBindings>
|
||||
</pd:activity>
|
||||
<pd:activity name="Author With Given Id Does Not Exist">
|
||||
<pd:type>com.tibco.pe.core.GenerateErrorActivity</pd:type>
|
||||
<pd:resourceType>ae.activities.throw</pd:resourceType>
|
||||
<pd:x>427</pd:x>
|
||||
<pd:y>232</pd:y>
|
||||
<config>
|
||||
<faultName>DeleteError</faultName>
|
||||
</config>
|
||||
<pd:inputBindings>
|
||||
<ns2:ActivityInput>
|
||||
<data>
|
||||
<pfx2:root>
|
||||
<pfx2:error>
|
||||
<xsl:value-of select="$Delete-Author/jdbcUpdateActivityOutput/noOfUpdates"/>
|
||||
</pfx2:error>
|
||||
</pfx2:root>
|
||||
</data>
|
||||
</ns2:ActivityInput>
|
||||
</pd:inputBindings>
|
||||
</pd:activity>
|
||||
<pd:transition>
|
||||
<pd:from>DeleteAuthor</pd:from>
|
||||
<pd:from>Delete Author</pd:from>
|
||||
<pd:to>End</pd:to>
|
||||
<pd:lineType>Default</pd:lineType>
|
||||
<pd:lineColor>-16777216</pd:lineColor>
|
||||
<pd:conditionType>always</pd:conditionType>
|
||||
<pd:conditionType>otherwise</pd:conditionType>
|
||||
</pd:transition>
|
||||
<pd:transition>
|
||||
<pd:from>Catch</pd:from>
|
||||
@@ -122,16 +149,25 @@
|
||||
</pd:transition>
|
||||
<pd:transition>
|
||||
<pd:from>Start</pd:from>
|
||||
<pd:to>LogInputData</pd:to>
|
||||
<pd:to>Log Input Data</pd:to>
|
||||
<pd:lineType>Default</pd:lineType>
|
||||
<pd:lineColor>-16777216</pd:lineColor>
|
||||
<pd:conditionType>always</pd:conditionType>
|
||||
</pd:transition>
|
||||
<pd:transition>
|
||||
<pd:from>LogInputData</pd:from>
|
||||
<pd:to>DeleteAuthor</pd:to>
|
||||
<pd:from>Log Input Data</pd:from>
|
||||
<pd:to>Delete Author</pd:to>
|
||||
<pd:lineType>Default</pd:lineType>
|
||||
<pd:lineColor>-16777216</pd:lineColor>
|
||||
<pd:conditionType>always</pd:conditionType>
|
||||
</pd:transition>
|
||||
<pd:transition>
|
||||
<pd:from>Delete Author</pd:from>
|
||||
<pd:to>Author With Given Id Does Not Exist</pd:to>
|
||||
<pd:xpathDescription>authorDoesNotExist</pd:xpathDescription>
|
||||
<pd:lineType>Default</pd:lineType>
|
||||
<pd:lineColor>-16777216</pd:lineColor>
|
||||
<pd:conditionType>xpath</pd:conditionType>
|
||||
<pd:xpath>$Delete-Author/jdbcUpdateActivityOutput/noOfUpdates = 0</pd:xpath>
|
||||
</pd:transition>
|
||||
</pd:ProcessDefinition>
|
||||
Reference in New Issue
Block a user