views:

597

answers:

3

I want to send a large blob from biztalk with some metadata to a WCF service.

I can control both the service settings and the biztalk settings freely, though I have to use http to reach the service.

The blob may well be in the gigabyte range, so the plain WCF BizTalk adapter with BasicHttp or WSHttp is out of question since it serializes the message content into XML.

My current scenario would put the metadata as XML into the first part of the biztalk multipart message and the payload into a second part.

To call the service I would prepare a WCF MessageContract to put the metadata into the message header and the payload into the body. I would also set both client and server side to "Streamed" transport mode.

This scenario works fine with a "normal" WCF client but how can I configure the Biztalk WCF adapter to do the same without ever putting the whole payload into memory?

It could certainly be done wih a self written adapter, but I wonder if there's a way to do it with the WCF custom adapter plus a behavior or two?

A: 

do you got Biztalk 2006 ? since previous releases of BizTalk mapping of documents always occurred in-memory.

ThorHalvor
AFAIK Biztalk 2004 has no WCF-Adapter at all. I'm currently working with Biztalk 2009 Beta, but the question applies to the WCF-Adapter, which includes 2006 R2 also.
TToni
+1  A: 

Hi

Not a full answer I'm afriad - never had the chance to look at this, but - in case you haven't looked at that already, have a look at the OracleDB adapter in the WCF adapter pack. it's documentation suggests that it supports streaming (I've read Streaming and the Oracle Database Adapter and WCF LOB Adapter SDK and BizTalk Adapter Pack) And as I believe this is based on the out of the box WCF adapter, this may point at the right direction.

Basically, if the WCF adpater code supports streaming you are likely to need to use the WCF-Custom adapter and supply the correct configuration yourslef (either by using the supplied UI or by importing configuration from a config file, which is sometimes easier for complex configuration)

Sorry for the rather "generic" response, I hope it helps somewhat

Yossi Dahan
Thank's, the bit aout the ODA is actually quite useful since it provides some details about the internal workings of the WCF-CustomAdapter. This gives me some new hope that my scenario is actually doable without writing an own adapter from scratch.
TToni
+1  A: 

WCF adapters in BizTalk support streaming out-of-the box. You must use WCF-Custom to enable it, though. Please, see this blog post for more information.

Maxime Labelle
Yay! That's what I was looking for!
TToni