daisysendermoon Absent Member.
Absent Member.
5036 views

Get MIME format Mail Item.

Hi,

From Object Java API, I can use getMIME() from a Mail object to retrieve the MIME format of a Mail message.

But from GWSOAP interface, I can not find a way to do that.

http://forums.novell.com/novell-developer-forums/dev-groupwise-web-service-soap/364822-mime-data.html

The above is another post in this forum and Preston had provided an example for retrieving the attachment information but I still do not know how to get the information from a Mail Item like that.

Please help.

Thanks,

Richard
Labels (1)
0 Likes
13 Replies
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.



>>> On Thursday, June 04, 2009 at 6:16 AM,

daisysendermoon02<daisysendermoon02@no-mx.forums.novell.com> wrote:

> Hi,
>
> From Object Java API, I can use getMIME() from a Mail object to
> retrieve the MIME format of a Mail message.
>
> But from GWSOAP interface, I can not find a way to do that.
>
>

http://forums.novell.com/novell‑developer‑forums/dev‑groupwise‑webâ€
‘service‑soap/36
> 4822‑mime‑data.html
>
> The above is another post in this forum and Preston had provided an
> example for retrieving the attachment information but I still do not
> know how to get the information from a Mail Item like that.
>
> Please help.
>
> Thanks,
>
> Richard

0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Sorry, I pressed the wrong key.
To get a mime formatted message you have
to use the HTTP GET mechanism. You pass
the id of the item, plus mime=1/
HTTP GET /attachment?session=...&id=...&mime=1

The mime value can be 1 or true.
Here is an example.

GET
/attachment?session=kz4qLx26whEAEw_X&id=49E34D4E.domain.PO1.100.1776172.1.C9
C8.1%4011%3A7.domain.PO1.100.0.1.0.1%4016&mime=true HTTP/1.1

Preston

>>> On Thursday, June 04, 2009 at 11:22 AM, Preston

Stephenson<PStephenson@gw.novell.com> wrote:

>
>>>> On Thursday, June 04, 2009 at 6:16 AM,

> daisysendermoon02<daisysendermoon02@no‑mx.forums.novell.com> wrote:
>
>> Hi,
>>
>> From Object Java API, I can use getMIME() from a Mail object to
>> retrieve the MIME format of a Mail message.
>>
>> But from GWSOAP interface, I can not find a way to do that.
>>
>>

>

http://forums.novell.com/novell‑developer‑forums/dev‑groupwise‑web*

> ‘service‑soap/36
>> 4822‑mime‑data.html
>>
>> The above is another post in this forum and Preston had provided an
>> example for retrieving the attachment information but I still do not
>> know how to get the information from a Mail Item like that.
>>
>> Please help.
>>
>> Thanks,
>>
>> Richard

0 Likes
daisysendermoon Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Thanks Preston.

OK, I followed your directions and I ran the following lines.

URL url = new URL(str);
HttpURLConnection huc = (HttpURLConnection) url.openConnection();
InputStream is = huc.getInputStream();
byte[] b = new byte[16384];
FileOutputStream out = new FileOutputStream(new File("c:\\temp", "Mime.822"));

int len;
for (;;)
{
len = is.read(b, 0, 16384);
if (-1 == len) {
break;
}
out.write(b, 0, len);
}
out.flush();
out.close();


But everytime when "huc.getInputStream()" is called, the POA just crashed.

Is there anything I can do?

Thanks,

Richard
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

What version of the POA are you using?

>>> On Thursday, June 04, 2009 at 12:06 PM,

daisysendermoon02<daisysendermoon02@no-mx.forums.novell.com> wrote:

> Thanks Preston.
>
> OK, I followed your directions and I ran the following lines.
>
> URL url = new URL(str);
> HttpURLConnection huc = (HttpURLConnection) url.openConnection();
> InputStream is = huc.getInputStream();
> byte[] b = new byte[16384];
> FileOutputStream out = new FileOutputStream(new File("c:\\temp",
> "Mime.822"));
>
> int len;
> for (;;)
> {
> len = is.read(b, 0, 16384);
> if (‑1 == len) {
> break;
> }
> out.write(b, 0, len);
> }
> out.flush();
> out.close();
>
>
> But everytime when "huc.getInputStream()" is called, the POA just
> crashed.
>
> Is there anything I can do?
>
> Thanks,
>
> Richard

0 Likes
daisysendermoon Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

GW 7.0.3

Thanks,

Richard
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

The mime code is only in 8.0.0 and later.
Preston

>>> On Thursday, June 04, 2009 at 1:26 PM,

daisysendermoon02<daisysendermoon02@no-mx.forums.novell.com> wrote:

> GW 7.0.3
>
> Thanks,
>
> Richard

0 Likes
daisysendermoon Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Thanks a lot Preston.

Richard Liu

Preston Stephenson;1803108 wrote:
The mime code is only in 8.0.0 and later.
Preston

>>> On Thursday, June 04, 2009 at 1:26 PM,

daisysendermoon02<daisysendermoon02@no-mx.forums.novell.com> wrote:

> GW 7.0.3
>
> Thanks,
>
> Richard
0 Likes
vip8439 Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

daisysendermoon02;1804502 wrote:
Thanks a lot Preston.

Richard Liu


I hope it is not the case that this is not supported. It is in Novell's documentation that 7.0.3 supports this. I certainly hope so as we had a prominent customer update to 7.0.3 w/ Hot Patch 3 so we could use attachment streaming and now it causes the POA to crash every time we try to pull from that URL. The very same attachment streaming code with 8.0 does not cause the POA to crash. Unfortunately, updating to 8.0 is not an option at this customer site.

Here is the link for the documenation:

Novell Documentation

Go to GroupWise Web Service and click on GroupWise 7 SP3 changes. Attachment streaming is pretty much the only change listed. Also, click on 'Using Streaming Attachments'. The very first line says to make sure you are connecting to a 7.0.3 POA.
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Attachment streaming is supported, but not generating
a MIME (rfc822) attachment if the rfc822 attachment doesn't
already exist.

>>> On Monday, July 20, 2009 at 1:46 PM,

vip8439<vip8439@no-mx.forums.novell.com>
wrote:

> daisysendermoon02;1804502 Wrote:
>> Thanks a lot Preston.
>>
>> Richard Liu

>
> I hope it is not the case that this is not supported. It is in
> Novell's documentation that 7.0.3 supports this. I certainly hope so as
> we had a prominent customer update to 7.0.3 w/ Hot Patch 3 so we could
> use attachment streaming and now it causes the POA to crash every time
> we try to pull from that URL. The very same attachment streaming code
> with 8.0 does not cause the POA to crash. Unfortunately, updating to
> 8.0 is not an option at this customer site.
>
> Here is the link for the documenation:
>
> 'Novell Documentation'
>

(http://developer.novell.com/documentation/gwsoap/gwwbserv/index.html?page=/

> documentation/gwsoap/gwwbserv/data/bktitle.html)
>
> Go to GroupWise Web Service and click on GroupWise 7 SP3 changes.
> Attachment streaming is pretty much the only change listed. Also, click
> on 'Using Streaming Attachments'. The very first line says to make sure
> you are connecting to a 7.0.3 POA.

0 Likes
vip8439 Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Preston Stephenson;1828000 wrote:
Attachment streaming is supported, but not generating
a MIME (rfc822) attachment if the rfc822 attachment doesn't
already exist.

>>> On Monday, July 20, 2009 at 1:46 PM,

vip8439<vip8439@no-mx.forums.novell.com>
wrote:

> daisysendermoon02;1804502 Wrote:
>> Thanks a lot Preston.
>>
>> Richard Liu

>
> I hope it is not the case that this is not supported. It is in
> Novell's documentation that 7.0.3 supports this. I certainly hope so as
> we had a prominent customer update to 7.0.3 w/ Hot Patch 3 so we could
> use attachment streaming and now it causes the POA to crash every time
> we try to pull from that URL. The very same attachment streaming code
> with 8.0 does not cause the POA to crash. Unfortunately, updating to
> 8.0 is not an option at this customer site.
>
> Here is the link for the documenation:
>
> 'Novell Documentation'
>

(Novell Documentation

> documentation/gwsoap/gwwbserv/data/bktitle.html)
>
> Go to GroupWise Web Service and click on GroupWise 7 SP3 changes.
> Attachment streaming is pretty much the only change listed. Also, click
> on 'Using Streaming Attachments'. The very first line says to make sure
> you are connecting to a 7.0.3 POA.


Thank you for your reply Preston. I will try connecting without mime=1 in the URL and see if that prevents the POA from crashing. However, even if that works I do not think this will be a practical solution as I am creating a cursor with a filter that will only grab the Mail type so there should be rfc822 attachments, right? It would not surprise me that much if it did, but does GW store internal to internal Mail items in a non-rfc822 format? With 8.0 this method is working 100% of the time with no POA crashes. I am using Attachment Streaming with our customers that have 8.0 in order to obtain the full raw message on one go as the SOAP methods for getting an entire message just seem silly to me. Am I correct in going with Attachment Streaming to pull the full raw message in rfc822 or should I be looking at something else? By the way, the messages must be in rfc822 for our archiving appliance so that is another reason I stayed away from the SOAP methods like getMime() since it appeared I might have to "fudge" message boundaries and what not if I had to make multiple requests to get all of the content for a larger Mail item. Was I correct in that assumption or can you pretty much just take the MIME from the multiple responses and append them?
0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

Look, if you do not use getMIME, which is not available in 7, you have
to understand groupwise objects and build your own fake mime. Period.



vip8439 wrote:
> Preston Stephenson;1828000 Wrote:
>> Attachment streaming is supported, but not generating
>> a MIME (rfc822) attachment if the rfc822 attachment doesn't
>> already exist.
>>
>>>>> On Monday, July 20, 2009 at 1:46 PM,

>> vip8439<vip8439@no-mx.forums.novell.com>
>> wrote:
>>
>>> daisysendermoon02;1804502 Wrote:
>>>> Thanks a lot Preston.
>>>>
>>>> Richard Liu
>>> I hope it is not the case that this is not supported. It is in
>>> Novell's documentation that 7.0.3 supports this. I certainly hope so

>> as
>>> we had a prominent customer update to 7.0.3 w/ Hot Patch 3 so we

>> could
>>> use attachment streaming and now it causes the POA to crash every

>> time
>>> we try to pull from that URL. The very same attachment streaming

>> code
>>> with 8.0 does not cause the POA to crash. Unfortunately, updating

>> to
>>> 8.0 is not an option at this customer site.
>>>
>>> Here is the link for the documenation:
>>>
>>> 'Novell Documentation'
>>>

>> ('Novell Documentation'
>> (http://developer.novell.com/documentation/gwsoap/gwwbserv/index.html?page=/)
>>
>>> documentation/gwsoap/gwwbserv/data/bktitle.html)
>>>
>>> Go to GroupWise Web Service and click on GroupWise 7 SP3 changes.
>>> Attachment streaming is pretty much the only change listed. Also,

>> click
>>> on 'Using Streaming Attachments'. The very first line says to make

>> sure
>>> you are connecting to a 7.0.3 POA.

>
> Thank you for your reply Preston. I will try connecting without mime=1
> in the URL and see if that prevents the POA from crashing. However,
> even if that works I do not think this will be a practical solution as I
> am creating a cursor with a filter that will only grab the Mail type so
> there should be rfc822 attachments, right? It would not surprise me
> that much if it did, but does GW store internal to internal Mail items
> in a non-rfc822 format? With 8.0 this method is working 100% of the
> time with no POA crashes. I am using Attachment Streaming with our
> customers that have 8.0 in order to obtain the full raw message on one
> go as the SOAP methods for getting an entire message just seem silly to
> me. Am I correct in going with Attachment Streaming to pull the full
> raw message in rfc822 or should I be looking at something else? By the
> way, the messages must be in rfc822 for our archiving appliance so that
> is another reason I stayed away from the SOAP methods like getMime()
> since it appeared I might have to "fudge" message boundaries and what
> not if I had to make multiple requests to get all of the content for a
> larger Mail item. Was I correct in that assumption or can you pretty
> much just take the MIME from the multiple responses and append them?
>
>

0 Likes
Anonymous_User Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

The mime.822 attachment is only available on items that
come in through the internet (GWIA).

Items sent within GroupWise do not have that attachment.
We do not store messages internally in MIME format.

Getting GroupWise items as MIME is not practical. You
incur a lot of overhead to convert GroupWise items into
MIME.

Preston

>>> On Tuesday, July 21, 2009 at 6:56 AM,

vip8439<vip8439@no-mx.forums.novell.com>
wrote:

> Preston Stephenson;1828000 Wrote:
>> Attachment streaming is supported, but not generating
>> a MIME (rfc822) attachment if the rfc822 attachment doesn't
>> already exist.
>>
>> >>> On Monday, July 20, 2009 at 1:46 PM,

>> vip8439<vip8439@no‑mx.forums.novell.com>
>> wrote:
>>
>> > daisysendermoon02;1804502 Wrote:
>> >> Thanks a lot Preston.
>> >>
>> >> Richard Liu
>> >
>> > I hope it is not the case that this is not supported. It is in
>> > Novell's documentation that 7.0.3 supports this. I certainly hope so

>> as
>> > we had a prominent customer update to 7.0.3 w/ Hot Patch 3 so we

>> could
>> > use attachment streaming and now it causes the POA to crash every

>> time
>> > we try to pull from that URL. The very same attachment streaming

>> code
>> > with 8.0 does not cause the POA to crash. Unfortunately, updating

>> to
>> > 8.0 is not an option at this customer site.
>> >
>> > Here is the link for the documenation:
>> >
>> > 'Novell Documentation'
>> >

>> ('Novell Documentation'
>>

>

(http://developer.novell.com/documentation/gwsoap/gwwbserv/index.html?page=/
)
>>
>> > documentation/gwsoap/gwwbserv/data/bktitle.html)
>> >
>> > Go to GroupWise Web Service and click on GroupWise 7 SP3 changes.
>> > Attachment streaming is pretty much the only change listed. Also,

>> click
>> > on 'Using Streaming Attachments'. The very first line says to make

>> sure
>> > you are connecting to a 7.0.3 POA.

>
> Thank you for your reply Preston. I will try connecting without mime=1
> in the URL and see if that prevents the POA from crashing. However,
> even if that works I do not think this will be a practical solution as I
> am creating a cursor with a filter that will only grab the Mail type so
> there should be rfc822 attachments, right? It would not surprise me
> that much if it did, but does GW store internal to internal Mail items
> in a non‑rfc822 format? With 8.0 this method is working 100% of the
> time with no POA crashes. I am using Attachment Streaming with our
> customers that have 8.0 in order to obtain the full raw message on one
> go as the SOAP methods for getting an entire message just seem silly to
> me. Am I correct in going with Attachment Streaming to pull the full
> raw message in rfc822 or should I be looking at something else? By the
> way, the messages must be in rfc822 for our archiving appliance so that
> is another reason I stayed away from the SOAP methods like getMime()
> since it appeared I might have to "fudge" message boundaries and what
> not if I had to make multiple requests to get all of the content for a
> larger Mail item. Was I correct in that assumption or can you pretty
> much just take the MIME from the multiple responses and append them?

0 Likes
vip8439 Absent Member.
Absent Member.

Re: Get MIME format Mail Item.

vip8439;1828237 wrote:
Thank you for your reply Preston. I will try connecting without mime=1 in the URL and see if that prevents the POA from crashing. However, even if that works I do not think this will be a practical solution as I am creating a cursor with a filter that will only grab the Mail type so there should be rfc822 attachments, right? It would not surprise me that much if it did, but does GW store internal to internal Mail items in a non-rfc822 format? With 8.0 this method is working 100% of the time with no POA crashes. I am using Attachment Streaming with our customers that have 8.0 in order to obtain the full raw message on one go as the SOAP methods for getting an entire message just seem silly to me. Am I correct in going with Attachment Streaming to pull the full raw message in rfc822 or should I be looking at something else? By the way, the messages must be in rfc822 for our archiving appliance so that is another reason I stayed away from the SOAP methods like getMime() since it appeared I might have to "fudge" message boundaries and what not if I had to make multiple requests to get all of the content for a larger Mail item. Was I correct in that assumption or can you pretty much just take the MIME from the multiple responses and append them?


Thank you for the info guys.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.