Home Page › Forums › BizTalk 2004 – BizTalk 2010 › Error with BizTalk Http Adapter and Custom Pipeline Component
- This topic has 10 replies, 1 voice, and was last updated 8 years, 3 months ago by
community-content.
-
AuthorPosts
-
-
December 14, 2008 at 9:19 PM #21381
I have a problem with a BizTalk project. I am receiving a multi part message, over http, form an application called ‘Ponton ‘. While developing my custom pipeline component I used a ‘file’ receive port. The custom component is basically accessing the message stream and adds some header information that is required by the MIME component in the pipeline to process the multi part message. Using the file receive port it all works well. When I then tried to convert the receive port into an http receive port. I get an error server 500 error. When I look at the event log I get the following error message.
Event Type: Error
Event Source: BizTalk Server 2006
Event Category: BizTalk Server 2006
Event ID: 5719
Date: 14/12/2008
Time: 8:50:19 PM
User: N/A
Computer: 5SG5831VM2K3SRV
Description:
There was a failure executing the receive pipeline: “PAPINETPipelines.PontonPoReceive, CustomerIntegration2.PAPINET.Pipelines, Version=1.0.0.0, Culture=neutral, PublicKeyToken=4ca3635fbf092bbb” Source: “Pre Mime Decoder Component” Receive Port: “RecHttpPonton” URI: “/BizTalkHTTPReceive/BTSHTTPReceive.dll?PAPINet_PO3” Reason: The method or operation is not implemented.
The ‘Pre Mime Decoder Component’ mentioned in the error message is the custom component in the pipeline. I know the component is registered correctly as it works when the receive port is of type ‘file’. It only fails when the port is converted to an http receive port.
I have also been able to validate that the http adapter is correctly configured and can receive messages. I thought I’d found the problem at one stage. A MS article talks about trust level of the isolated Host process. So I created a new isolated host and made it trusted. Then I assigned the new isolated host to the http adapter. Unfortunately this did not resolve the problem.
-
December 15, 2008 at 1:55 AM #21384
Could it be that you, in your pipeline component tries to access context properties that – like the ReceivedFileName property – is no longer existing when you’re not using the http adapter?
Check the names and namespaces of all accessed context properties, you might find a FILE-word in there somewhere.
//Niklas
-
December 15, 2008 at 1:58 AM #21385
A lot of type-o’s and stuff there, I hope you understand.
-
December 15, 2008 at 10:45 AM #21397
Thanks for the response Niklas.
The only work done in the custom component is on the message stream. No other context properties are touched. The error also suggests that ‘The method or operation is not implemented‘. I am wondering if the Http adapter requires an additional method to be implemented in the custom component? It could also be access permissions but the modifications to the isolated host did not help.
Geordie
-
December 15, 2008 at 1:52 PM #21398
Ok. I now recall having this issue in an earlier project. Use the stream.Can… -methods to see what you can do with it, if you cant do what you want, wrap it in another stream. This method we used to be able to read a an incomming stream from whatever (as far as we needed) it came.
/// <summary>
/// This method ensures that the stream is seekable so that it can be written to archive.
/// </summary>
/// <param name=”stream”>The stream to ensure is seekable.</param>
public static Stream EnsureSeekableStream(Stream stream)
{
if (!stream.CanSeek)
{
stream = new Microsoft.BizTalk.Streaming.ReadOnlySeekableStream(stream);
}
return stream;
}//Niklas
-
December 15, 2008 at 8:09 PM #21399
Thanks for the reply Niklas.
I’ll give it a go tomorrow and let you know how I get on.
Thanks,
Geordie
-
December 16, 2008 at 2:53 PM #21403
Hi Niklas
Thanks again for your reply. I tried implementing the method you suggested in the custom component but there was no change in the error message. It still appears to be missing some method in the component if the error message is accurate… ‘Reason: The method or operation is not implemented.‘
Any other thoughts would be appreciated.
Geordie
-
December 16, 2008 at 10:56 PM #21406
Hummm… I really am sorry, but I’ve kind of run out of ideas. My only hint from here would be to start debugging the pipeline. Attach to BTSNTSvc.exe, breakepoints set in the Execute method of the component, run a message through the pipeline and see where it hits the fan. Besides that, I’m out of luck. Sorry.
//Niklas
-
December 18, 2008 at 3:54 PM #21427
I created a MS trouble ticket for this issue and we were able to identify the problem.
In the custom component code’s Execute method I was grabbing the <inputmsg>.MsgPart.Data property and checking for length etc. The file adatper implements the Data property as both a getter and setter. The http adapter on the other hand only implements the setter. Hence the error message. To get the data you need to use the call the GetOriginalDataStream method.
Hope this helps anyone else who runs into this inconsistency.
Geordie
-
December 18, 2008 at 10:47 PM #21429
Aaah, the GetOriginalDataStream-method. Of course, when you mention this, I recall using the method, not where I’ve used it or why though but now I know.
Thanks for posting the answer here.
Happy bts:ing!
//Niklas
-
August 5, 2009 at 1:23 AM #22966
I had also tried HTTP Adapter but thier is no access realted issues … why iam nt able to configure
-
-
-
-
-
-
-
-
-
-
AuthorPosts
- The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.