source: ccr/trunk/nhin-vista/projects/NHINC/Current/Product/Production/Gateway/NhincProxyBPEL/src/NhincProxyDocRetrieve.bpel@ 507

Last change on this file since 507 was 507, checked in by George Lilly, 15 years ago

NHIN gateway and adaptor for use on linux with VistA EHR and RPMS

File size: 21.7 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<process
3 name="NhincProxyDocRetrieve"
4 targetNamespace="urn:gov:hhs:fha:nhinc:gateway:nhincproxybpel:nhincproxydocretrieve"
5 xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
6 xmlns:xsd="http://www.w3.org/2001/XMLSchema"
7 xmlns:sxt="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace"
8 xmlns:sxed="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor"
9 xmlns:sxeh="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/ErrorHandling"
10 xmlns:tns="urn:gov:hhs:fha:nhinc:gateway:nhincproxybpel:nhincproxydocretrieve"
11 xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
12 xmlns:nccommonproxy="urn:gov:hhs:fha:nhinc:common:nhinccommonproxy"
13 xmlns:nccommon="urn:gov:hhs:fha:nhinc:common:nhinccommon"
14 xmlns:soapaddr04="http://schemas.xmlsoap.org/ws/2004/08/addressing"
15 xmlns:ihe="urn:ihe:iti:xds-b:2007"
16 xmlns:rs="urn:oasis:names:tc:ebxml-regrep:xsd:rs:3.0"
17 xmlns:conninfo="urn:gov:hhs:fha:nhinc:common:connectionmanagerinfo"
18 xmlns:nccommonadapter="urn:gov:hhs:fha:nhinc:common:nhinccommonadapter"
19 xmlns:auditlog="urn:gov:hhs:fha:nhinc:common:auditlog">
20 <import namespace="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" location="Interfaces/wsdl/NhincProxyDocRetrieve.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
21 <import namespace="http://enterprise.netbeans.org/bpel/NhinDocRetrieveWrapper" location="NhinDocRetrieveWrapper.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
22 <import namespace="urn:ihe:iti:xds-b:2007" location="Interfaces/wsdl/NhinDocRetrieve.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
23 <import namespace="urn:gov:hhs:fha:nhinc:nhinccomponentconnectionmanager" location="Interfaces/wsdl/NhincComponentConnectionManager.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
24 <import namespace="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" location="Interfaces/wsdl/NhincComponentInternalAuditRepository.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/>
25 <partnerLinks>
26 <partnerLink name="AuditRepositoryPL" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" partnerLinkType="tns:NhincComponentInternalAuditRepository" partnerRole="NhincComponentInternalAuditRepositoryPortTypeRole"/>
27 <partnerLink name="ConnectionManagerPL" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentconnectionmanager" partnerLinkType="tns:NhincComponentConnectionManager" partnerRole="NhincComponentConnectionManagerPortTypeRole"/>
28 <partnerLink name="NhinDocRetrievePL" xmlns:tns="http://enterprise.netbeans.org/bpel/NhinDocRetrieveWrapper" partnerLinkType="tns:RespondingGateway_Retrieve_LinkType" partnerRole="RespondingGateway_Retrieve_Role"/>
29 <partnerLink name="NhincProxyDocRetrievePL" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" partnerLinkType="tns:NhincProxyDocRetrieve" myRole="NhincProxyDocRetrievePortTypeRole"/>
30 </partnerLinks>
31 <variables>
32 <variable name="LogDocRetrieveOut" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" messageType="tns:LogEventResponseMessage"/>
33 <variable name="LogDocRetrieveIn" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" messageType="tns:LogDocRetrieveRequestMessage"/>
34 <variable name="Proxy_CrossGatewayRetrieveOut" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" messageType="tns:RespondingGateway_CrossGatewayRetrieveResponseMessage"/>
35 <variable name="Proxy_CrossGatewayRetrieveIn" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" messageType="tns:RespondingGateway_CrossGatewayRetrieveRequestMessage"/>
36 </variables>
37 <sequence>
38 <receive name="ReceiveProxyDocRetrieve" createInstance="yes" partnerLink="NhincProxyDocRetrievePL" operation="RespondingGateway_CrossGatewayRetrieve" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" portType="tns:NhincProxyDocRetrievePortType" variable="Proxy_CrossGatewayRetrieveIn"/>
39 <assign name="AssignAuditReposDRReq">
40 <copy>
41 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/ihe:RetrieveDocumentSetRequest</from>
42 <to>$LogDocRetrieveIn.LogDocRetrieveRequest/auditlog:message/ihe:RetrieveDocumentSetRequest</to>
43 </copy>
44 <copy>
45 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion</from>
46 <to>$LogDocRetrieveIn.LogDocRetrieveRequest/auditlog:message/auditlog:assertion</to>
47 </copy>
48 <copy>
49 <from>'Inbound'</from>
50 <to>$LogDocRetrieveIn.LogDocRetrieveRequest/auditlog:direction</to>
51 </copy>
52 <copy>
53 <from>'Nhin'</from>
54 <to>$LogDocRetrieveIn.LogDocRetrieveRequest/auditlog:interface</to>
55 </copy>
56 </assign>
57 <invoke name="InvokeAuditReposDRReq" partnerLink="AuditRepositoryPL" operation="LogDocRetrieve" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" portType="tns:NhincComponentInternalAuditRepositoryPortType" inputVariable="LogDocRetrieveIn" outputVariable="LogDocRetrieveOut"/>
58 <scope name="ProxyDocRetrieveScope">
59 <variables>
60 <variable name="LogDocRetrieveResultOut" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" messageType="tns:LogEventResponseMessage"/>
61 <variable name="LogDocRetrieveResultIn" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" messageType="tns:LogDocRetrieveResultRequestMessage"/>
62 <variable name="TargetAddress" type="xsd:string"/>
63 <variable name="GetConnectionInfoEndpointByServiceNameOut" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentconnectionmanager" messageType="tns:GetConnectionInfoEndpointByServiceNameResponseMessage"/>
64 <variable name="GetConnectionInfoEndpointByServiceNameIn" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentconnectionmanager" messageType="tns:GetConnectionInfoEndpointByServiceNameRequestMessage"/>
65 <variable name="Nhin_CrossGatewayRetrieveOut" xmlns:ihe="urn:ihe:iti:xds-b:2007" messageType="ihe:CrossGatewayRetrieveResponse_Message"/>
66 <variable name="Nhin_CrossGatewayRetrieveIn" xmlns:ihe="urn:ihe:iti:xds-b:2007" messageType="ihe:CrossGatewayRetrieve_Message"/>
67 </variables>
68 <faultHandlers>
69 <catch faultName="sxeh:systemFault" faultVariable="systemFaultVar" faultMessageType="sxeh:faultMessage">
70 <sequence name="SystemFaultSeq">
71 <assign name="AssignErrorInfo">
72 <sxt:trace>
73 <sxt:log level="info" location="onStart">
74 <bpel:from>'NhinProxyDocRetrieve.bpel - A system fault was encountered processing a doc retrieve message. Fault details follow...'</bpel:from>
75 </sxt:log>
76 <sxt:log level="warning" location="onStart">
77 <bpel:from variable="systemFaultVar"/>
78 </sxt:log>
79 </sxt:trace>
80 <copy>
81 <from>'urn:oasis:names:tc:ebxml-regrep:ResponseStatusType:Failure'</from>
82 <to>$Proxy_CrossGatewayRetrieveOut.RespondingGateway_CrossGatewayRetrieveResponse/rs:RegistryResponse/@status</to>
83 </copy>
84 <copy>
85 <from>'XDSRepositoryError'</from>
86 <to>$Proxy_CrossGatewayRetrieveOut.RespondingGateway_CrossGatewayRetrieveResponse/rs:RegistryResponse/rs:RegistryErrorList/rs:RegistryError/@errorCode</to>
87 </copy>
88 <copy>
89 <from>'Error'</from>
90 <to>$Proxy_CrossGatewayRetrieveOut.RespondingGateway_CrossGatewayRetrieveResponse/rs:RegistryResponse/rs:RegistryErrorList/rs:RegistryError/@severity</to>
91 </copy>
92 <copy>
93 <from>'Processing NHIN Proxy document retrieve'</from>
94 <to>$Proxy_CrossGatewayRetrieveOut.RespondingGateway_CrossGatewayRetrieveResponse/rs:RegistryResponse/rs:RegistryErrorList/rs:RegistryError/@codeContext</to>
95 </copy>
96 </assign>
97 <reply name="ReplyFromFault" partnerLink="NhincProxyDocRetrievePL" operation="RespondingGateway_CrossGatewayRetrieve" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" portType="tns:NhincProxyDocRetrievePortType" variable="Proxy_CrossGatewayRetrieveOut"/>
98 <exit name="ExitFromFault"/>
99 </sequence>
100 </catch>
101 </faultHandlers>
102 <sequence name="ProxyDocRetrieveSeq">
103 <if name="IfHasHomeCommunity">
104 <condition>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:nhinTargetSystem/nccommon:homeCommunity/nccommon:homeCommunityId</condition>
105 <sequence name="Sequence1">
106 <assign name="AssignConnectionMgrInput">
107 <copy>
108 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:nhinTargetSystem/nccommon:homeCommunity</from>
109 <to>$GetConnectionInfoEndpointByServiceNameIn.GetConnectionInfoEndpointByServiceNameRequest/conninfo:homeCommunityWithServiceName/conninfo:homeCommunity</to>
110 </copy>
111 <copy>
112 <from>'documentretrieve'</from>
113 <to>$GetConnectionInfoEndpointByServiceNameIn.GetConnectionInfoEndpointByServiceNameRequest/conninfo:homeCommunityWithServiceName/conninfo:serviceName</to>
114 </copy>
115 </assign>
116 <invoke name="InvokeConnectionManager" partnerLink="ConnectionManagerPL" operation="GetConnectionInfoEndpointByServiceName" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentconnectionmanager" portType="tns:NhincComponentConnectionManagerPortType" inputVariable="GetConnectionInfoEndpointByServiceNameIn" outputVariable="GetConnectionInfoEndpointByServiceNameOut"/>
117 <assign name="AssignConnectionMgrOutput">
118 <copy>
119 <from>bpel:doXslTransform('urn:stylesheets:wrap2serviceref.xsl', $GetConnectionInfoEndpointByServiceNameOut.ConnectionInfoEndpoint/conninfo:serviceConnectionInfoEndpoints/conninfo:serviceConnectionInfoEndpoint/nccommon:EPR/nccommon:EndpointReference)</from>
120 <to partnerLink="NhinDocRetrievePL"/>
121 </copy>
122 <copy>
123 <from>string($GetConnectionInfoEndpointByServiceNameOut.ConnectionInfoEndpoint/conninfo:serviceConnectionInfoEndpoints/conninfo:serviceConnectionInfoEndpoint/nccommon:EPR/nccommon:EndpointReference/soapaddr04:Address)</from>
124 <to variable="TargetAddress"/>
125 </copy>
126 </assign>
127 </sequence>
128 <else>
129 <assign name="AssignEprProvided">
130 <copy>
131 <from>bpel:doXslTransform('urn:stylesheets:wrap2serviceref.xsl', $Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:nhinTargetSystem/nccommon:epr/nccommon:EndpointReference)</from>
132 <to partnerLink="NhinDocRetrievePL"/>
133 </copy>
134 <copy>
135 <from>string($Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:nhinTargetSystem/nccommon:epr/nccommon:EndpointReference/soapaddr04:Address)</from>
136 <to variable="TargetAddress"/>
137 </copy>
138 </assign>
139 </else>
140 </if>
141 <assign name="AssignAssertion">
142 <copy>
143 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/ihe:RetrieveDocumentSetRequest</from>
144 <to variable="Nhin_CrossGatewayRetrieveIn" part="body"/>
145 </copy>
146 <copy>
147 <from>string($TargetAddress)</from>
148 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:resource"/>
149 </copy>
150 <copy>
151 <from>'retrieveDocuments'</from>
152 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:action"/>
153 </copy>
154 <copy>
155 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:claimFormRaw</from>
156 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:content"/>
157 </copy>
158 <copy>
159 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:claimFormRef</from>
160 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:contentReference"/>
161 </copy>
162 <copy>
163 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:expirationDate</from>
164 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:expirationDate"/>
165 </copy>
166 <copy>
167 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:purposeOfDisclosureCoded/nccommon:codeSystem</from>
168 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:purposeForUseCodeSystem"/>
169 </copy>
170 <copy>
171 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:purposeOfDisclosureCoded/nccommon:codeSystemName</from>
172 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:purposeForUseCodeSystemName"/>
173 </copy>
174 <copy>
175 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:purposeOfDisclosureCoded/nccommon:displayName</from>
176 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:purposeForUseDisplayName"/>
177 </copy>
178 <copy>
179 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:purposeOfDisclosureCoded/nccommon:code</from>
180 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:purposeForUseRoleCode"/>
181 </copy>
182 <copy>
183 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:dateOfSignature</from>
184 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:signDate"/>
185 </copy>
186 <copy>
187 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:personName/nccommon:givenName</from>
188 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userFirstName"/>
189 </copy>
190 <copy>
191 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:personName/nccommon:familyName</from>
192 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userLastName"/>
193 </copy>
194 <copy>
195 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:personName/nccommon:secondNameOrInitials</from>
196 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userMiddleName"/>
197 </copy>
198 <copy>
199 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:userName</from>
200 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userName"/>
201 </copy>
202 <copy>
203 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:org/nccommon:name</from>
204 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userOrganization"/>
205 </copy>
206 <copy>
207 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:roleCoded/nccommon:code</from>
208 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userRoleCode"/>
209 </copy>
210 <copy>
211 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:roleCoded/nccommon:displayName</from>
212 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userRoleCodeDisplayName"/>
213 </copy>
214 <copy>
215 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:roleCoded/nccommon:codeSystem</from>
216 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userRoleCodeSystem"/>
217 </copy>
218 <copy>
219 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion/nccommon:userInfo/nccommon:roleCoded/nccommon:codeSystemName</from>
220 <to variable="Nhin_CrossGatewayRetrieveIn" property="ihe:userRoleCodeSystemName"/>
221 </copy>
222 </assign>
223 <invoke name="InvokeNhinDocRetrieve" partnerLink="NhinDocRetrievePL" operation="RespondingGateway_CrossGatewayRetrieve" xmlns:ihe="urn:ihe:iti:xds-b:2007" portType="ihe:RespondingGateway_Retrieve_PortType" inputVariable="Nhin_CrossGatewayRetrieveIn" outputVariable="Nhin_CrossGatewayRetrieveOut"/>
224 <assign name="AssignNhinResponse">
225 <copy>
226 <from variable="Nhin_CrossGatewayRetrieveOut" part="body"/>
227 <to variable="Proxy_CrossGatewayRetrieveOut" part="RespondingGateway_CrossGatewayRetrieveResponse"/>
228 </copy>
229 </assign>
230 <assign name="AssignLogDocRetrieveResponse">
231 <copy>
232 <from>$Nhin_CrossGatewayRetrieveOut.body/rs:RegistryResponse</from>
233 <to>$LogDocRetrieveResultIn.LogDocRetrieveResultRequest/auditlog:message/ihe:RetrieveDocumentSetResponse/rs:RegistryResponse</to>
234 </copy>
235 <copy>
236 <from>$Nhin_CrossGatewayRetrieveOut.body/ihe:DocumentResponse</from>
237 <to>$LogDocRetrieveResultIn.LogDocRetrieveResultRequest/auditlog:message/ihe:RetrieveDocumentSetResponse/ihe:DocumentResponse</to>
238 </copy>
239 <copy>
240 <from>$Proxy_CrossGatewayRetrieveIn.RespondingGateway_CrossGatewayRetrieveRequest/nccommonproxy:assertion</from>
241 <to>$LogDocRetrieveResultIn.LogDocRetrieveResultRequest/auditlog:message/auditlog:assertion</to>
242 </copy>
243 <copy>
244 <from>'Outbound'</from>
245 <to>$LogDocRetrieveResultIn.LogDocRetrieveResultRequest/auditlog:direction</to>
246 </copy>
247 <copy>
248 <from>'Nhin'</from>
249 <to>$LogDocRetrieveResultIn.LogDocRetrieveResultRequest/auditlog:interface</to>
250 </copy>
251 </assign>
252 <invoke name="InvokeLogDocRetrieveResponse" partnerLink="AuditRepositoryPL" operation="LogDocRetrieveResult" xmlns:tns="urn:gov:hhs:fha:nhinc:nhinccomponentinternalauditrepository" portType="tns:NhincComponentInternalAuditRepositoryPortType" inputVariable="LogDocRetrieveResultIn" outputVariable="LogDocRetrieveResultOut"/>
253 </sequence>
254 </scope>
255 <reply name="ReplyProxyDocRetrieve" partnerLink="NhincProxyDocRetrievePL" operation="RespondingGateway_CrossGatewayRetrieve" xmlns:tns="urn:gov:hhs:fha:nhinc:nhincproxydocretrieve" portType="tns:NhincProxyDocRetrievePortType" variable="Proxy_CrossGatewayRetrieveOut"/>
256 </sequence>
257</process>
Note: See TracBrowser for help on using the repository browser.