openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin Sutter (Commented) (JIRA)" <>
Subject [jira] [Commented] (OPENJPA-2044) Invalid header in MetaModel classes generated by AnnotationProcessor
Date Thu, 13 Oct 2011 13:46:11 GMT


Kevin Sutter commented on OPENJPA-2044:

I already committed the changes to trunk.  Since the original URL processing code was localized
to AnnotationProcessor6, I followed the same pattern.  Moving this type of simple change to
Files seemed like overkill.  And, since the actual processing of the stream into Comment format
is pretty unique to the SourceCode file, I really didn't see a need to generalize it for Files.
> Invalid header in MetaModel classes generated by AnnotationProcessor
> --------------------------------------------------------------------
>                 Key: OPENJPA-2044
>                 URL:
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: criteria
>    Affects Versions: 2.0.1, 2.1.1, 2.2.0
>         Environment: Any
>            Reporter: Dale Lane
>            Assignee: Kevin Sutter
>            Priority: Trivial
>              Labels: openjpa
>             Fix For: 2.2.0
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
> The documentation at
talks about an option available in org.apache.openjpa.persistence.meta.AnnotationProcessor6:
> -Aopenjpa.header=<url> : A url whose content will appear as comment header to the
generated file(s). 
> This option does not work.
> If I give it a URL - either an http or a file URL - it doesn't put the contents from
these URLs into the header of the generated files. It puts something like:
> content.text.PlainTextInputStream@9ea09ea 
> in the header instead.
> I suspect that the AnnotationProcessor is essentially doing:
> URL headerurl = new URL(<openjpa.header value>);
> String newHeaderComment = headerurl.getContent().toString();
> The getContent() is returning an InputStream - as documented here in the absence of a
content handler factory:
> Then the toString() call just returns the string representation of the instance of the
InputStream object. 
> I think the AnnotationProcessor should read from the stream instead?

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message