Forum Replies Created
-
AuthorPosts
-
June 30, 2010 at 4:15 AM in reply to: How to serialize parts of an orchestration (procedure invoking)? #25088
Ok, it seems that I have to use correlation types and correlation sets to associate orchestration instances to each other creating one message per message-shape in the same time interval.
Which BTS.* property should I use as correlation type for my send-shape (related to a Soap Message which call a procedure “myPrc”) to relate them to the one send-port specified by the WCF-SQL Adapter and the Soap Header “Procedure/dbo/myPrc”?
(My intention has been to prevent the simultaneous call of the procedure “myPrc”)
Hiwa
June 30, 2010 at 3:51 AM in reply to: How to get Query Notification for events in the BizTalkMgmtDb? #25087I have played around with this for a couple of days and I have made a SQL script (not finished yet) that reads out the exact same information as you would have under each “Application” in the Biztalk Server Admin console as an XML file from the BizTalkMgmtDb. This gives me the opportunity to read out and compare the data from different points of time during a day or week.
Here is the script, which still needs quite a bit of tweaking before it is 100% and can be used. Maybe it can be of interest to others…
####################################################################################
use BizTalkMgmtDb
declare @applicationId int
select
application.nId as “@Id”
— , ____.nId as “@assemId”
, application.nvcName as “@appName”
, application.DateModified as “DateModified”
————————————————————————————————
— Orchestration
————————————————————————————————
,(
select
Orchestration.orcName as “@Name”
, Orchestration.Modified as “DateModified”
, Orchestration.assemName as “assemName”, bindings
from
(
select app.nID as appId
, ____.nID as assemId
,app.nvcName as appName
, orcestration.nvcFullName as orcName
, orcestration.dtModified as Modified
, ____.nvcFullName as assemName
, ( — Orchestration – bindings
select
p.nvcName as “@Id”
, case
when sendt.nId is not null then sendt.nvcName
when resc.nId is not null then resc.nvcName
when spg.nId is not null then spg.nvcName
else ‘mangler’
end as “@Port”
from dbo.bts_application app
left join dbo.bts_assembly ____ on ____.nApplicationID = app.nID
inner join dbo.bts_orchestration orc on ____.nID = orc.nAssemblyID
left join dbo.bts_orchestration_port p on p.nOrchestrationID = orc.nId
left join dbo.bts_porttype pt on p.nPortTypeID = pt.nID
inner join dbo.bts_orchestration_port_binding bind on bind.nOrcPortID = p.nID
left join dbo.bts_sendport sendt on sendt.nId = bind.nSendPortID and sendt.nApplicationID = app.nID
left join dbo.bts_receiveport resc on resc.nID = bind.nReceivePortID and resc.nApplicationID = app.nID
left join dbo.bts_sendportgroup spg on spg.nID = bind.nSpgID and spg.nApplicationID = app.nID
where app.nID = application.nId
and orcestration.nId = orc.nID
for xml path(‘LogicalPort’),type) ‘Bindings’
, ‘Orchestration’ as bizTalkPart
from dbo.bts_application app
left join dbo.bts_assembly ____ on ____.nApplicationID = app.nID
inner join dbo.bts_orchestration orcestration on ____.nID = orcestration.nAssemblyID
where app.nID = application.nId
) as Orchestration
for xml path(‘Orchestration’),type) ‘Orchestrations’
————————————————————————————————
— Send Port Groups
————————————————————————————————
,(
select
SendPortGroups.portGroupName as “@portGroupName”
, SendPortGroups.DateModified as “DateModified”
, transports
from
(
select
app.nID as appId
, a.nID as assemId
,app.nvcName as appName
, a.nvcFullName as asseName
, sendPortgr.DateModified as DateModified
, sendPortgr.nvcName as portGroupName
, ( select distinct — Send Port Groups properties
sp.nvcName as “@Name”
,case
when st.bIsPrimary = 0 then ‘Backup’
when st.bIsPrimary = 1 then ‘Primary’
end as transport
, adp.Name as type
, st.nvcAddress as URI
, pipeRecive.Name as RecivePipeline
, pipeSend.Name as SendPipeline
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
left join dbo.bts_porttype p on p.nAssemblyID = a.nID
inner join dbo.bts_sendportgroup spg on spg.nApplicationID = app.nID
inner join dbo.bts_spg_sendport spgs on spgs.nSendPortGroupID = spg.nID
inner join dbo.bts_sendport sp on sp.nID = spgs.nSendPortID and sp.nApplicationID = app.nID
inner join dbo.bts_sendport_transport st on sp.nId = st.nSendPortID
inner join dbo.adm_Adapter adp on adp.Id = st.nTransportTypeId
left join dbo.bts_pipeline pipeSend on pipeSend.Id = sp.nSendPipelineID
left join dbo.bts_pipeline pipeRecive on pipeRecive.Id = sp.nReceivePipelineID
where app.nID = application.nId
and sendPortgr.nID = spg.nID
for xml path(‘TransportType’),type) ‘transports’
, ‘SendPortGroups’ as bizTalkPart
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
inner join dbo.bts_sendportgroup sendPortgr on sendPortgr.nApplicationID = app.nID
where app.nID = application.nId
) as SendPortGroups
for xml path(‘SendPortGroup’),type) ‘SendPortGroups’
————————————————————————————————
— Send Ports
————————————————————————————————
,(
select
SendPorts.sendPortName as “@sendPortName”
, SendPorts. DateModified as “DateModified”
, transports
from
(
select
app.nID as appId
, a.nID as assemId
, app.nvcName as appName
, a.nvcFullName as assemName
, sendPort.nvcName as sendPortName
, sendPort.DateModified as DateModified
, ‘SendPorts’ as bizTalkPart
, ( — Send Ports transport
select distinct
case
when st.bIsPrimary = 0 then ‘Backup’
when st.bIsPrimary = 1 then ‘Primary’
end as “@Type”
, adp.Name as type
, st.nvcAddress as URL
, pipeRecive.Name as RecivePipeline
, pipeSend.Name as SendPipeline
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
left join dbo.bts_porttype p on p.nAssemblyID = a.nID
inner join dbo.bts_sendport sp on sp.nApplicationID = app.nID
left join dbo.bts_sendport_transport st on sp.nId = st.nSendPortID
left join dbo.bts_sendport_transform tr on sp.nId = tr.nSendPortID
left join dbo.bts_spg_sendport spgs on spgs.nSendPortID = sp.nId
left join dbo.adm_Adapter adp on adp.Id = st.nTransportTypeId
left join dbo.bts_pipeline pipeSend on pipeSend.Id = sp.nSendPipelineID
left join dbo.bts_pipeline pipeRecive on pipeRecive.Id = sp.nReceivePipelineID
where app.nID = application.nId
and sendPort.nId = sp.nId
for xml path(‘transport’),type) ‘transports’
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
inner join dbo.bts_sendport sendPort on sendPort.nApplicationID = app.nID
where app.nID = application.nId
) AS SendPorts
for xml path(‘SendPort’),type) ‘SendPorts’
————————————————————————————————
— Receive Ports
————————————————————————————————
,(select
resp.nvcName as “@reciverPortName”
, resp.DateModified as DateModified
, (
select
rl.Name as “reciveLocationName”
, rl.InboundTransportURL as URI
, adp.Name as type
, rp.nvcName as recivePort
, host.Name as reciveHandler
, pipeRecive.Name as RecivePipeline
, pipeSend.Name as SendPipeline
from dbo.bts_application app
inner join dbo.bts_receiveport rp on rp.nApplicationID = app.nID
left join dbo.bts_receiveport_transform tr on rp.nId = tr.nReceivePortID
left join dbo.adm_ReceiveLocation rl on rl.ReceivePortId = rp.nID
left join dbo.adm_ReceiveHandler rh on rh.Id = rl.ReceiveHandlerId
left join dbo.adm_Host host on host.Id = rh.HostId
left join dbo.bts_pipeline pipeSend on pipeSend.Id = rl.SendPipelineID
left join dbo.bts_pipeline pipeRecive on pipeRecive.Id = rl.ReceivePipelineID
left join dbo.adm_Adapter adp on adp.Id = rl.AdapterId
where app.nID = application.nId
and resp.nID = rp.nID
order by rl.Name
for xml path(‘ReciveLocation’),type) ReciveLocations
from dbo.bts_application app
inner join dbo.bts_receiveport resp on resp.nApplicationID = app.nID
where app.nID = application.nId
for xml path(‘ReceivePort’),type) ‘ReceivePorts’
————————————————————————————————
— Receive Locations
————————————————————————————————
,(
select
ReceiveLocations.reciveLocationName as “@reciveLocationName”
, ReceiveLocations.DateModified as “DateModified”
, ReceiveLocations.URI as “URI”
, ReceiveLocations.type as “type”
, ReceiveLocations.recivePort as “recivePort”
, ReceiveLocations.reciveHandler as “reciveHandler”
, ReceiveLocations.RecivePipeline as “RecivePipeline”
, ReceiveLocations.SendPipeline as “SendPipeline”
from (
select
app.nID as appId
, a.nID as assemId
, app.nvcName as appName
, a.nvcFullName as assemName
, rl.Name as reciveLocationName
, rl.DateModified as DateModified
, rl.InboundTransportURL as URI
, adp.Name as type
, rp.nvcName as recivePort
, host.Name as reciveHandler
, ‘ReceiveLocations’ as bizTalkPart
, pipeRecive.Name as RecivePipeline
, pipeSend.Name as SendPipeline
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
inner join dbo.bts_receiveport rp on rp.nApplicationID = app.nID
left join dbo.bts_receiveport_transform tr on rp.nId = tr.nReceivePortID
left join dbo.adm_ReceiveLocation rl on rl.ReceivePortId = rp.nID
left join dbo.adm_ReceiveHandler rh on rh.Id = rl.ReceiveHandlerId
left join dbo.adm_Adapter adp on adp.Id = rh.AdapterId
left join dbo.adm_Host host on host.Id = rh.HostId
left join dbo.bts_pipeline pipeSend on pipeSend.Id = rl.SendPipelineID
left join dbo.bts_pipeline pipeRecive on pipeRecive.Id = rl.ReceivePipelineID
where app.nID = application.nId
) as ReceiveLocations
for xml path(‘ReceiveLocation’),type) ‘ReceiveLocations’
————————————————————————————————
— Schemas
————————————————————————————————
,(
Select
Schemas.FullName as “@targetNamespace”
, Schemas.DateModified as “DateModified”
, Schemas.rootName as “RootName”
, Schemas.SchemaTypes as “SchemaType”
from (
select distinct
app.nID as appId
, a.nID as assemId
, app.nvcName as appName
, a.nvcFullName as assemName
, spc.date_modified as “DateModified”
,spc.schema_root_name as rootName
, ‘Schemas’ as bizTalkPart
,’http://’ + item.FullName as FullName
,case
when SchemaType = 1 then ‘Property’
when SchemaType = 0 then ‘Document’
end as SchemaTypes
–, *
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
left join dbo.bt_DocumentSpec spc on a.nID = spc.assemblyid
inner join dbo.bt_XMLShare xmls on xmls.id = spc.shareid
left join dbo.bts_item item on item.id = spc.itemid and item.AssemblyId = spc.assemblyid
where app.nID = application.nId
and property_clr_class is null
UNIONselect distinct
app.nID as appId
, a.nID as assemId
, app.nvcName as appName
, a.nvcFullName as assemName
, spc.date_modified as “DateModified”
, ‘ ‘ as rootName
, ‘Schemas’ as bizTalkPart
,’http://’ + item.FullName
,case
when SchemaType = 1 then ‘Property’
when SchemaType = 0 then ‘Document’
end as SchemaTypes
–, *
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
left join dbo.bt_DocumentSpec spc on a.nID = spc.assemblyid
inner join dbo.bt_XMLShare xmls on xmls.id = spc.shareid
left join dbo.bts_item item on item.id = spc.itemid and item.AssemblyId = spc.assemblyid
where app.nID = application.nId
and item.SchemaType = 1
) as Schemas
for xml path(‘Schema’),type) ‘Schemas’
————————————————————————————————
— Maps
————————————————————————————————
,(
Select
Maps.mapName as “@mapName”
, Maps.DateModified as “DateModified”
, Maps.sourceSchema as “sourceSchema”
, Maps.targetSchema as “targetSchema”
from (select app.nID as appId
, a.nID as assemId
,app.nvcName as appName
, a.nvcFullName as asseName
, map.date_modified as DateModified
, item.fullName as mapName
, map.indoc_docspec_name as sourceSchema
, map.outdoc_docspec_name as targetSchema
, ‘Maps’ as bizTalkPart
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
left join dbo.bts_item item on item.AssemblyId = a.nID
inner join dbo.bt_MapSpec map on map.itemid = item.id and map.assemblyid = a.nID
where app.nID = application.nId
) as Maps
for xml path(‘Map’),type) ‘Maps’
————————————————————————————————
— Pipelines
————————————————————————————————
,(
Select
Pipelines.pipelineName as “@pipelineName”
from (select app.nID as appId
, a.nID as assemId
, app.nvcName as appName
, a.nvcFullName as asseName
, pipe.Name as pipelineName
, ‘Pipelines’ as bizTalkPart
from dbo.bts_application app
left join dbo.[bts_assembly] a on a.nApplicationID = app.nID
inner join dbo.bts_pipeline pipe on pipe.nAssemblyID = a.nID
where app.nID = application.nId
) as Pipelines
for xml path(‘Pipeline’),type) ‘Pipelines’
————————————————————————————————
from dbo.bts_application application
— left join dbo.bts_assembly ____ on ____.nApplicationID = app.nID
— where ____.nApplicationID = @applicationId
order by application.nvcName
FOR XML path (‘Application’), ROOT(‘BizTalk’)####################################################################################
– M.P
June 30, 2010 at 2:08 AM in reply to: How to serialize parts of an orchestration (procedure invoking)? #25086Hi Daniel,
thanks for quick reply.
I do not use any Call or Start Orchestration shapes.
I only have the one orchestration. Shall I use any
of those shapes?
I use of course a Soap Message to start the procedure by a send port
using WCF-SQL Adpater.The proposed article seems to be interesting, I’ll let you know if it
could solve that problem.Hiwa
June 30, 2010 at 1:04 AM in reply to: BizTalk Server 2006 SOAP-adapter problem with proxy server #25085Hello Yonathan and others,
The webservice that I am using is asmx.
In the meanwhile I have found a solution for this problem, ans it is quit simple…
I have added the website, where I was sending the message to, to the list of addresses where the proxy server should not be used!
I have done this in Internet Explorer:
Tools -> Internet Options -> Connections -> LAN settings -> Advanced -> Add the website to the list of Exceptions.
Use semicolons to seperate entries, and do not use spaces in the list!I do not know if this is a option for everyone, but it works for me!
Robbish.
Yonathan,
Your sample is very helpful. Thank you!
Lynn
June 29, 2010 at 12:45 PM in reply to: How to serialize parts of an orchestration (procedure invoking)? #25083Hi,
How is your orchestration (which calls a MS SQL procedure by Send port) being invoked? Are you using a Call or Start Orchestration shape to invoke it?
Have you looked into implementing a Singleton Orchestration? Here’s an example that you can follow:
http://aspalliance.com/1208_Singleton_Orchestration_in_BizTalk_Server.all
Daniel.
Solved!
I have to use “regasm SSOSQL.dll” on framework and framework64!
cheers
wal
All I can suggest is a rebuild, redeploy and restarting the Host Instances and retesting.
If this does not work are you able to email me your schema and properties schema to greg.forsythe at gmail.com
Thanks for the reply.
Yes, I have created a message schema and a property Schema in my project. Then I created property promotion by doing quick promotion and verified that promotion appears in the Property Schema. Both these schema files were deployed.
When I see the message context, I do NOT see Schema.Destination promoted.
On the receive side I have a tried both using the XMLReceive and custom pipeline with XML Disassembler defined.
I am not using the distinguished fields.
Thanks
Kote
Are you using a property schema for promotion or a distinguished field.
You need to have a property schema with Source and Destination properties defined.
In your schema promote the Source and Destination fields to the appropriate properties. Do not use distinguished fields as these cannot be used for routing.If the message fails with a Routing error then you need to check the message context to see if your “Schema.Destination” property is promoted
Thanks Daniel…
I will look into that…
Mike
[quote user="lberan"]I typed xDoc.LoadXml(“……”); in the expression of Message Assignment shape within the construct shape. Is it correct?[/quote]
Yes, that’s right.
[quote user="lberan"]Is it the message in the Messages folder on Orchestration view?[/quote]
In that folder – you define your messages (every message must be or XmlDocument, or in your case – type of request schema)
[quote user="lberan"]where can I add those lines? [/quote]
In a Construct shape. Actually – to build Xml instance you can also in an Expression shape, but for learning purposes that’s OK with Construct shape too.
I have built a sample – for you to see how it should look. I put a rar file, within you will find a solution, a script for table and stored procedure, and a binding. For running this sample ( if you want to run it – deploy solution, after it deployed – go to administration console, right click on an application – import binding – let the binding file for WCF port to be created – you need two folders in and out on your C:\temp directory). If you have some test DB – create with that scripts table and a stored procedures, and fill table with some data. To run the sample you put the xml “Instance” to “In” folder and in out will appear the data from created table.
Download sample http://uploading.com/files/76ma5c8d/SelectTest.rar/
If you need some additional help – write here. :))
Hi Mike,
Based on this statement “This partner is indicating we have to make a call out to their web services.”, you can just use SOAP adapter to call third party web services in BizTalk 2006.
Daniel.
Hi Ziggy,
You can have your actual message in the body of the email sent, if you have a way of promoting that message string within your XML file schema. Then, do the following:
1) In your physical Send Port (in Administration Console), specify “Do not attach parts” in the dropdown list box in the Attachments tab in SMTP Transport Properties window, when configuring your Send Port; and specify “PassThruTransmit” as send pipeline.
2) In your orchestration, when constructing the message to assign to your logical Send Port (that binds to the physical port mentioned above), have the following lines in your Message Assignment shape:
YourMailMessage = YourXMLSchema.Record.MessageDescription;
YourMailMessage(SMTP.EmailBodyText) = YourXMLSchema.Record.MessageDescription;
Where MessageDescription is a Distinguished field in your XML schema (as an example).
Hope this helps,
Daniel.
In my case, the SAP-out variable would return either “OK”, “locked”, or some error message.
When Biztalk received a “locked” message, I send the user an email asking them to exit the order so biztalk can perform the update. I then delay biztalk for 60 and retry. I use the counter to keep track of how many times I retried (after 5 trys, Biztalk sends an email to a user group telling them what biztalk was attempting to do)
here are Biztalk details
I use Decide shape to test for “locked”
I use Expresssion to assign loop count to 0 “loopcount = 0;”
I use Delay shape to Delay 60 seconds “system.DateTime.UtcNow.AddSeconds(60);
I use Loop Shape to loop upto 5 times “loopcount < 5”
I resend
I increment loopcount loopcount = loopcount + 1;”
use decide shape to see if locked, if not locked, set loopcount to # higher than 5 “loopcount = 6;
Now the loop ends and Biztalk continues on its way.
I hope this helps.
-
AuthorPosts