You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by Rajika Kumarasiri <ra...@gmail.com> on 2007/08/15 07:02:52 UTC
Mail Transport for Axis2/c- Problem with building MIME message for SOAP 1.2
hello there,
While building the MIME message(using the mail API) for SOAP 1.2 to use with
Mail Transport, I encountered the following problem.
In the specification for Mail
Transport([1]<http://people.apache.org/%7Epzf/SMTPBase64Binding-0.2.html>)
it is said that the MIME message should be a multi part MIME message where
the content of the first part is empty. It is not a MUST but RECOMMENDED to
that this part has not content(Please refer section 2.1 at
[1]<http://people.apache.org/%7Epzf/SMTPBase64Binding-0.2.html>
).
So when trying to build a MIME message with the API it gave the following
result.
1. First I built a multi part MIME message
From: soap@client.com
To: soap@example.org
Subject: Anything
X-Service-Path: "/my/service/urlpath"
MIME-Version: 1.0
Content-Type: multipart/mixed;
boundary=-------6b8b462f327b248e6b8b462f327b248e
This is a multi-part message in MIME format
---------6b8b462f327b248e6b8b462f327b248e
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
empty
---------6b8b462f327b248e6b8b462f327b248e
Content-Type: application/soap+xml
Content-Description: test.xml
Content-Transfer-Encoding: base64
PHNvYXBlbnY6RW52ZWxvcGUKeG1sbnM6c29hcGVudj0iaHR0cDovL3NjaGVtYXMueG1sc29h
cC5vcmcvc29hcC9lbnZlbG9wZS8iPjxzb2FwZW52OkhlYWRlci8+PHNvYXBlbnY6Qm9keT48
bnMxOmVjaG9TdHJpbmcKeG1sbnM6bnMxPSJodHRwOi8vd3MuYXBhY2hlLm9yZy9heGlzMi9j
L3NhbXBsZXMiPjx0ZXh0PkhlbGxvCldvcmxkITwvdGV4dD48L25zMTplY2hvU3RyaW5nPjwv
c29hcGVudjpCb2R5Pjwvc29hcGVudjpFbnZlbG9wZT4K
---------6b8b462f327b248e6b8b462f327b248e--
2. Then I built a MIME message with the first part empty which gave the
following mime message.
From: soap@client.com
To: soap@example.org
Subject: Anything
X-Service-Path: "/my/service/urlpath"
MIME-Version: 1.0
Content-Type: application/soap+xml
Content-Description: test.xml
Content-Transfer-Encoding: base64
PHNvYXBlbnY6RW52ZWxvcGUKeG1sbnM6c29hcGVudj0iaHR0cDovL3NjaGVtYXMueG1sc29h
cC5vcmcvc29hcC9lbnZlbG9wZS8iPjxzb2FwZW52OkhlYWRlci8+PHNvYXBlbnY6Qm9keT48
bnMxOmVjaG9TdHJpbmcKeG1sbnM6bnMxPSJodHRwOi8vd3MuYXBhY2hlLm9yZy9heGlzMi9j
L3NhbXBsZXMiPjx0ZXh0PkhlbGxvCldvcmxkITwvdGV4dD48L25zMTplY2hvU3RyaW5nPjwv
c29hcGVudjpCb2R5Pjwvc29hcGVudjpFbnZlbG9wZT4K
So according to this the API ignores the first part if it has not any
content. So is it okay to use the first(1) MIME message since the spec.
described that it is not a MUST that the content should be empty but it is
RECOMMENDED?
Thank you,
Best regards,
Rajika
[1] - http://people.apache.org/~pzf/SMTPBase64Binding-0.2.html
Re: Mail Transport for Axis2/c- Problem with building MIME message for SOAP 1.2
Posted by Rajika Kumarasiri <ra...@gmail.com>.
On 8/15/07, Dinesh Premalal <xy...@gmail.com> wrote:
>
> Hi Rajika,
> Please find my comments inline.
See my replies inline,
"Rajika Kumarasiri" <ra...@gmail.com> writes:
>
> > So according to this the API ignores the first part if it has not any
> content.
> > So is it okay to use the first(1) MIME message since the spec.
> described that
> > it is not a MUST that the content should be empty but it is
> > RECOMMENDED?
> I'm confused :(
I am not clear why you are confused. Please let me know more about this
I think to answer this need knowledge about Mail transport not
> Axis2/C.
That's true. That is something related to the implementation of the Mail
Transport, not Axis2/C
itself.
Moreover, as far as you use standard transport implementation
> and someone can interoperate your implementation with other
> implementations, You can make good implementation decision about it.
>
> What does your mentor think ?
Well, he helped me to figure out the problem and suggested me the solution,
it works!
Now I am on track and the MIME message is built according to the
specification.
thanks,
> Dinesh
>
> --
> Dinesh Premalal
> http://xydinesh.wordpress.com/
> GPG ID : A255955C
> GPG Key Finger Print : C481 E5D4 C27E DC34 9257 0229 4F44 266E A255 955C
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-dev-help@ws.apache.org
>
>
Re: Mail Transport for Axis2/c- Problem with building MIME message for SOAP 1.2
Posted by Dinesh Premalal <xy...@gmail.com>.
Hi Rajika,
Please find my comments inline.
"Rajika Kumarasiri" <ra...@gmail.com> writes:
> So according to this the API ignores the first part if it has not any content.
> So is it okay to use the first(1) MIME message since the spec. described that
> it is not a MUST that the content should be empty but it is
> RECOMMENDED?
I'm confused :(
I think to answer this need knowledge about Mail transport not
Axis2/C. Moreover, as far as you use standard transport implementation
and someone can interoperate your implementation with other
implementations, You can make good implementation decision about it.
What does your mentor think ?
thanks,
Dinesh
--
Dinesh Premalal
http://xydinesh.wordpress.com/
GPG ID : A255955C
GPG Key Finger Print : C481 E5D4 C27E DC34 9257 0229 4F44 266E A255 955C
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-dev-help@ws.apache.org