You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Jinhua Wang <iv...@gmail.com> on 2012/10/15 10:35:34 UTC

Attachment header migrating problem

Hello

I have a migrating problem for headers in attachment.
For example, the message sent out contains* Content-ID:<foo>*,
Content-ID header value is "*<foo>*" instead of "*foo*" at server side.

When creating attachment of the following code:
org.apache.cxf.attachment.*AttachmentUtil.createAttachment*(InputStream,
InternetHeaders)
There's a id conversion at first. But in the following header processing,
there's no id conversion for Content-ID.

Since Content-ID conversion is needed for id(*"new AttachmentImpl(id)"*), I
think it is also useful for headers.
specification:http://www.ietf.org/rfc/rfc2392


Attachment is a example change for AttachmentUtil.

Best Regards

Re: Attachment header migrating problem

Posted by Jinhua Wang <iv...@gmail.com>.
Hello

The jira issue has been created at
https://issues.apache.org/jira/browse/CXF-4570
Please help to review the problem and patch.

Thanks.


On Tue, Oct 16, 2012 at 9:37 AM, Freeman Fang <fr...@gmail.com>wrote:

> Hi,
>
> As you already have a patch, could you please create a jira and append
> your patch there? It's for better track.
>
> -------------
> Freeman(Yue) Fang
>
> Red Hat, Inc.
> FuseSource is now part of Red Hat
> Web: http://fusesource.com | http://www.redhat.com/
> Twitter: freemanfang
> Blog: http://freemanfang.blogspot.com
> http://blog.sina.com.cn/u/1473905042
> weibo: http://weibo.com/u/1473905042
>
> On 2012-10-15, at 下午5:24, ivywjhua wrote:
>
> > Hello
> >
> >
> > The change attachment is as following.
> >
> > AttachmentUtil.java.patch
> > <http://cxf.547215.n5.nabble.com/file/n5716624/AttachmentUtil.java.patch
> >
> >
> >
> >
> >
> >
> > --
> > View this message in context:
> http://cxf.547215.n5.nabble.com/Attachment-header-migrating-problem-tp5716613p5716624.html
> > Sent from the cxf-user mailing list archive at Nabble.com.
>
>


-- 
Best Regards
Shanghai China

Re: Attachment header migrating problem

Posted by Freeman Fang <fr...@gmail.com>.
Hi,

As you already have a patch, could you please create a jira and append your patch there? It's for better track.

-------------
Freeman(Yue) Fang

Red Hat, Inc. 
FuseSource is now part of Red Hat
Web: http://fusesource.com | http://www.redhat.com/
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
http://blog.sina.com.cn/u/1473905042
weibo: http://weibo.com/u/1473905042

On 2012-10-15, at 下午5:24, ivywjhua wrote:

> Hello
> 
> 
> The change attachment is as following.
> 
> AttachmentUtil.java.patch
> <http://cxf.547215.n5.nabble.com/file/n5716624/AttachmentUtil.java.patch>  
> 
> 
> 
> 
> 
> --
> View this message in context: http://cxf.547215.n5.nabble.com/Attachment-header-migrating-problem-tp5716613p5716624.html
> Sent from the cxf-user mailing list archive at Nabble.com.


Re: Attachment header migrating problem

Posted by ivywjhua <iv...@gmail.com>.
Hello


The change attachment is as following.

AttachmentUtil.java.patch
<http://cxf.547215.n5.nabble.com/file/n5716624/AttachmentUtil.java.patch>  





--
View this message in context: http://cxf.547215.n5.nabble.com/Attachment-header-migrating-problem-tp5716613p5716624.html
Sent from the cxf-user mailing list archive at Nabble.com.

Re: Attachment header migrating problem

Posted by Freeman Fang <fr...@gmail.com>.
Hi,

If you wanna append attachment, you should attach it with nabble[1], the mailing list generally will filter out all attachment so we can't see your change for  AttachmentUtil.

[1]http://cxf.547215.n5.nabble.com/Attachment-header-migrating-problem-td5716613.html
-------------
Freeman(Yue) Fang

Red Hat, Inc. 
FuseSource is now part of Red Hat
Web: http://fusesource.com | http://www.redhat.com/
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
http://blog.sina.com.cn/u/1473905042
weibo: http://weibo.com/u/1473905042

On 2012-10-15, at 下午4:35, Jinhua Wang wrote:

> Hello
> 
> I have a migrating problem for headers in attachment. 
> For example, the message sent out contains Content-ID:<foo>,
> Content-ID header value is "<foo>" instead of "foo" at server side.
> 
> When creating attachment of the following code:
> org.apache.cxf.attachment.AttachmentUtil.createAttachment(InputStream, InternetHeaders)
> There's a id conversion at first. But in the following header processing, there's no id conversion for Content-ID.
> 
> Since Content-ID conversion is needed for id("new AttachmentImpl(id)"), I think it is also useful for headers.
> specification:http://www.ietf.org/rfc/rfc2392
> 
> 
> Attachment is a example change for AttachmentUtil.
> 
> Best Regards
> 
>