Changing Receive port address dynamically
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > BizTalk Server > BizTalk Server General > Changing Receive port address dynamically




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Changing Receive port address dynamically  
Yaniv Rahimi


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-23-06 06:15 PM

Hello,

I'm trying to find out how to change address of receive port dynamically
(like it can be done for dynamic send port)... Is there is any way to do it?
If yes - how? If not, how I can implement following logic:
Let's say an orchestration receives some XML message, which also have an
information about additional file (for example Word Document, or PDF
document) in one of its fields.
From received XML message orchestration knows the FileName and FileLocation
of this additional file and there is additional message type
(System.Xml.XmlDocument type)  to get this second file. This second file
should been routed to some send port untouched.

There is no problem to parse first XML message, to receive FileName and
FileLocation from it, no problem to route 'file contained' message  via
"Microsoft.BizTalk.DefaultPipelines.PassThruTransmit" to its final
destination. The only problem is to get this file dynamicly, based on data
received by orchestration. Is there is any way to do it in orchestration?
I'm aware about possability to perform all logic of copying file from
FileLocation to its final destination in an external assembly, but trying to
stay in orchestration.

Thanks for help!





[ Post a follow-up to this message ]



    Re: Changing Receive port address dynamically  
Scott Colestock


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-24-06 12:15 AM

I guess if the additional file is available on, say, a UNC share that is
accessible to the orchestration host, I wouldn't necessarily shy away from
using the static Copy method on the File class to copy the file to a
location where you have a receive location watching.

There isn't really a clean alternative that I can think of - you wouldn't
want to use wmi/OM to be altering a receive location at run time, for
instance (that would only work if your orchestrations ran serially, and even
then it sounds like a bad idea.)

Scott Colestock
www.traceofthought.net


"Yaniv Rahimi" <Yaniv.Rahimi@newsgroup.nospam> wrote in message
news:4529ACF8-FF97-429C-A60F-FB24E3EE671A@microsoft.com...
> Hello,
>
> I'm trying to find out how to change address of receive port dynamically
> (like it can be done for dynamic send port)... Is there is any way to do
> it?
> If yes - how? If not, how I can implement following logic:
> Let's say an orchestration receives some XML message, which also have an
> information about additional file (for example Word Document, or PDF
> document) in one of its fields.
> From received XML message orchestration knows the FileName and
> FileLocation
> of this additional file and there is additional message type
> (System.Xml.XmlDocument type)  to get this second file. This second file
> should been routed to some send port untouched.
>
> There is no problem to parse first XML message, to receive FileName and
> FileLocation from it, no problem to route 'file contained' message  via
> "Microsoft.BizTalk.DefaultPipelines.PassThruTransmit" to its final
> destination. The only problem is to get this file dynamicly, based on data
> received by orchestration. Is there is any way to do it in orchestration?
> I'm aware about possability to perform all logic of copying file from
> FileLocation to its final destination in an external assembly, but trying
> to
> stay in orchestration.
>
> Thanks for help!







[ Post a follow-up to this message ]



    Re: Changing Receive port address dynamically  
Yaniv Rahimi


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-24-06 12:15 PM

Hi Scott,

The receive location is already watching on this share. The main problem is
to have receive port to get VERY SPECIFIC file. The file itself is being
created in shared folder, and it's name is being populated in XML (main)
message. My problem is how to get this specific known (one and only one) fil
e
from known location. Can you think of any kind of correlation, which I can
make between them? Is there any way to make correlation between one of XML
Message fields and %SourceFileName% of additional message?

Thanks for help.

"Scott Colestock" wrote:

> I guess if the additional file is available on, say, a UNC share that is
> accessible to the orchestration host, I wouldn't necessarily shy away from
> using the static Copy method on the File class to copy the file to a
> location where you have a receive location watching.
>
> There isn't really a clean alternative that I can think of - you wouldn't
> want to use wmi/OM to be altering a receive location at run time, for
> instance (that would only work if your orchestrations ran serially, and ev
en
> then it sounds like a bad idea.)
>
> Scott Colestock
> www.traceofthought.net
>
>
> "Yaniv Rahimi" <Yaniv.Rahimi@newsgroup.nospam> wrote in message
> news:4529ACF8-FF97-429C-A60F-FB24E3EE671A@microsoft.com... 
>
>
>





[ Post a follow-up to this message ]



    Re: Changing Receive port address dynamically  
Dinesh


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-24-06 12:15 PM

Not sure whether you have thought about this option
Why not calling a .NET component within the orchestration to do file
handling mechanism.You can read and write the file to any location.

Thanks
Dinesh

"Yaniv Rahimi" wrote:
[vbcol=seagreen]
> Hi Scott,
>
> The receive location is already watching on this share. The main problem i
s
> to have receive port to get VERY SPECIFIC file. The file itself is being
> created in shared folder, and it's name is being populated in XML (main)
> message. My problem is how to get this specific known (one and only one) f
ile
> from known location. Can you think of any kind of correlation, which I can
> make between them? Is there any way to make correlation between one of XML
> Message fields and %SourceFileName% of additional message?
>
> Thanks for help.
>
> "Scott Colestock" wrote:
> 





[ Post a follow-up to this message ]



    Re: Changing Receive port address dynamically  
Scott Colestock


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-24-06 06:14 PM

Ahhh, now I understand better.  You should take a look at the Charles Young
article on "flexible correlation" - you can get this done if you want to...

http://geekswithblogs.net/cyoung/articles/17364.aspx

Consider having a MessageContextBase property in a property schema that you
can use for correlation.  Following Charles' guidelines, you will want to
initialize a correlation based on that custom property with the content in
your xml field that contains the file name.

When receiving via the file receive location, you will want to have a custom
receive pipeline that promotes that same custom property with the name of
the file that you are receiving -- so you can have a receive shape in your
orch that follows the correlation.

This will let your orch rendezvous with the correct file...

Scott Colestock
www.traceofthought.net


"Yaniv Rahimi" <Yaniv.Rahimi@newsgroup.nospam> wrote in message
news:5C2B82C1-BB1A-4693-975C-6856FC116C9C@microsoft.com...[vbcol=seagreen]
> Hi Scott,
>
> The receive location is already watching on this share. The main problem
> is
> to have receive port to get VERY SPECIFIC file. The file itself is being
> created in shared folder, and it's name is being populated in XML (main)
> message. My problem is how to get this specific known (one and only one)
> file
> from known location. Can you think of any kind of correlation, which I can
> make between them? Is there any way to make correlation between one of XML
> Message fields and %SourceFileName% of additional message?
>
> Thanks for help.
>
> "Scott Colestock" wrote:
> 







[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 10:55 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register