193 lines
7.8 KiB
XML
193 lines
7.8 KiB
XML
<?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:ns1="http://www.tibco.com/pe/GenerateErrorActivity/InputSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
|
<xsd:import namespace="http://www.demo.com/author" schemaLocation="/Resources/WSDL/WSDL.wsdl"/>
|
|
<pd:name>Processes/sql/author/SqlPOST.process</pd:name>
|
|
<pd:startName>Start</pd:startName>
|
|
<pd:startType>
|
|
<xsd:element name="root">
|
|
<xsd:complexType>
|
|
<xsd:sequence>
|
|
<xsd:element ref="pfx:author"/>
|
|
</xsd:sequence>
|
|
</xsd:complexType>
|
|
</xsd:element>
|
|
</pd:startType>
|
|
<pd:startX>152</pd:startX>
|
|
<pd:startY>112</pd:startY>
|
|
<pd:returnBindings>
|
|
<root>
|
|
<status>
|
|
<xsl:value-of select="'new author added'"/>
|
|
</status>
|
|
</root>
|
|
</pd:returnBindings>
|
|
<pd:endName>End</pd:endName>
|
|
<pd:endType>
|
|
<xsd:element name="root">
|
|
<xsd:complexType>
|
|
<xsd:sequence>
|
|
<xsd:element ref="pfx:author" minOccurs="0"/>
|
|
<xsd:element name="status" type="xsd:string"/>
|
|
</xsd:sequence>
|
|
</xsd:complexType>
|
|
</xsd:element>
|
|
</pd:endType>
|
|
<pd:endX>778</pd:endX>
|
|
<pd:endY>112</pd:endY>
|
|
<pd:errorSchemas/>
|
|
<pd:processVariables/>
|
|
<pd:targetNamespace>http://xmlns.example.com/1719579163583</pd:targetNamespace>
|
|
<pd:activity name="AddAuthor">
|
|
<pd:type>com.tibco.plugin.jdbc.JDBCUpdateActivity</pd:type>
|
|
<pd:resourceType>ae.activities.JDBCUpdateActivity</pd:resourceType>
|
|
<pd:x>384</pd:x>
|
|
<pd:y>112</pd:y>
|
|
<config>
|
|
<timeout>10</timeout>
|
|
<commit>false</commit>
|
|
<emptyStrAsNil>false</emptyStrAsNil>
|
|
<jdbcSharedConfig>/Resources/configurations/JDBC Connection.sharedjdbc</jdbcSharedConfig>
|
|
<statement>INSERT INTO author ( id,firstname, lastname, date_of_birth, date_of_death, age) VALUES (?,?,?,?,?,?);</statement>
|
|
<Prepared_Param_DataType>
|
|
<parameter>
|
|
<parameterName>param_id</parameterName>
|
|
<dataType>INTEGER</dataType>
|
|
</parameter>
|
|
<parameter>
|
|
<parameterName>param_firstname</parameterName>
|
|
<dataType>VARCHAR</dataType>
|
|
</parameter>
|
|
<parameter>
|
|
<parameterName>param_lastname</parameterName>
|
|
<dataType>VARCHAR</dataType>
|
|
</parameter>
|
|
<parameter>
|
|
<parameterName>param_date-of_birth</parameterName>
|
|
<dataType>DATE</dataType>
|
|
</parameter>
|
|
<parameter>
|
|
<parameterName>param_date-of_death</parameterName>
|
|
<dataType>DATE</dataType>
|
|
</parameter>
|
|
<parameter>
|
|
<parameterName>param_age</parameterName>
|
|
<dataType>INTEGER</dataType>
|
|
</parameter>
|
|
</Prepared_Param_DataType>
|
|
</config>
|
|
<pd:inputBindings>
|
|
<jdbcUpdateActivityInput>
|
|
<param_id>
|
|
<xsl:choose>
|
|
<xsl:when test="exists($Start/root/pfx:author/@id)">
|
|
<xsl:value-of select="$Start/root/pfx:author/@id"/>
|
|
</xsl:when>
|
|
<xsl:otherwise>
|
|
<xsl:attribute name="xsi:nil">true</xsl:attribute>
|
|
</xsl:otherwise>
|
|
</xsl:choose>
|
|
</param_id>
|
|
<param_firstname>
|
|
<xsl:value-of select="$Start/root/pfx:author/pfx:firstName"/>
|
|
</param_firstname>
|
|
<param_lastname>
|
|
<xsl:value-of select="$Start/root/pfx:author/pfx:lastName"/>
|
|
</param_lastname>
|
|
<param_date-of_birth>
|
|
<xsl:value-of select="$Start/root/pfx:author/pfx:dateOfBirth"/>
|
|
</param_date-of_birth>
|
|
<param_date-of_death>
|
|
<xsl:choose>
|
|
<xsl:when test="exists($Start/root/pfx:author/pfx:dateOfDeath)">
|
|
<xsl:value-of select="$Start/root/pfx:author/pfx:dateOfDeath"/>
|
|
</xsl:when>
|
|
<xsl:otherwise>
|
|
<xsl:attribute name="xsi:nil">true</xsl:attribute>
|
|
</xsl:otherwise>
|
|
</xsl:choose>
|
|
</param_date-of_death>
|
|
<param_age>
|
|
<xsl:choose>
|
|
<xsl:when test="exists($Start/root/pfx:author/pfx:age)">
|
|
<xsl:value-of select="$Start/root/pfx:author/pfx:age"/>
|
|
</xsl:when>
|
|
<xsl:otherwise>
|
|
<xsl:attribute name="xsi:nil">true</xsl:attribute>
|
|
</xsl:otherwise>
|
|
</xsl:choose>
|
|
</param_age>
|
|
</jdbcUpdateActivityInput>
|
|
</pd:inputBindings>
|
|
</pd:activity>
|
|
<pd:activity name="LogInputData">
|
|
<pd:type>com.tibco.pe.core.WriteToLogActivity</pd:type>
|
|
<pd:resourceType>ae.activities.log</pd:resourceType>
|
|
<pd:x>274</pd:x>
|
|
<pd:y>113</pd:y>
|
|
<config>
|
|
<role>User</role>
|
|
</config>
|
|
<pd:inputBindings>
|
|
<ns:ActivityInput>
|
|
<message>
|
|
<xsl:value-of select="concat('input data',string($Start/root))"/>
|
|
</message>
|
|
</ns:ActivityInput>
|
|
</pd:inputBindings>
|
|
</pd:activity>
|
|
<pd:activity name="Catch">
|
|
<pd:type>com.tibco.pe.core.CatchActivity</pd:type>
|
|
<pd:resourceType>ae.activities.catch</pd:resourceType>
|
|
<pd:x>281</pd:x>
|
|
<pd:y>239</pd:y>
|
|
<pd:handler>true</pd:handler>
|
|
<config>
|
|
<catchAll>true</catchAll>
|
|
</config>
|
|
<pd:inputBindings/>
|
|
</pd:activity>
|
|
<pd:activity name="Generate Error">
|
|
<pd:type>com.tibco.pe.core.GenerateErrorActivity</pd:type>
|
|
<pd:resourceType>ae.activities.throw</pd:resourceType>
|
|
<pd:x>418</pd:x>
|
|
<pd:y>240</pd:y>
|
|
<config>
|
|
<faultName/>
|
|
</config>
|
|
<pd:inputBindings>
|
|
<ns1:ActivityInput>
|
|
<message>
|
|
<xsl:value-of select="string($Catch/exceptiondata)"/>
|
|
</message>
|
|
</ns1:ActivityInput>
|
|
</pd:inputBindings>
|
|
</pd:activity>
|
|
<pd:transition>
|
|
<pd:from>AddAuthor</pd:from>
|
|
<pd:to>End</pd:to>
|
|
<pd:lineType>Default</pd:lineType>
|
|
<pd:lineColor>-16777216</pd:lineColor>
|
|
<pd:conditionType>always</pd:conditionType>
|
|
</pd:transition>
|
|
<pd:transition>
|
|
<pd:from>Start</pd:from>
|
|
<pd:to>LogInputData</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>AddAuthor</pd:to>
|
|
<pd:lineType>Default</pd:lineType>
|
|
<pd:lineColor>-16777216</pd:lineColor>
|
|
<pd:conditionType>always</pd:conditionType>
|
|
</pd:transition>
|
|
<pd:transition>
|
|
<pd:from>Catch</pd:from>
|
|
<pd:to>Generate Error</pd:to>
|
|
<pd:lineType>Default</pd:lineType>
|
|
<pd:lineColor>-16777216</pd:lineColor>
|
|
<pd:conditionType>always</pd:conditionType>
|
|
</pd:transition>
|
|
</pd:ProcessDefinition> |