[ 
https://issues.apache.org/jira/browse/FELIX-3461?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13255581#comment-13255581
 ] 

Göktürk Gezer commented on FELIX-3461:
--------------------------------------

Unfortunately this issue is not easy to reproduce or wrap in TestCase. At least 
i don't know an easy way to write it. But here is the steps for you to see it 
in action:

* Create a simple bundle which is not manipulated with either mave-ipojo or 
bnd-ipojo plugin with the content:
@Component
public class TestComponent
{
  public TestComponent(@Property String hi){}
  
  @Validate
  public void validated()
}

* Manipulate that jar using Pojoization.pojoization() method.
I did it by creating seperate project under manipulator, and using Pojoization 
to simply do pojoization.

* Copy the MANIFEST in manipulated jar somewhere. This MANIFEST will be correct 
without any error.

* And then re-run pojoization on manipulated jar again.(The one manipulator 
extracted as <bundleName>_out.jar

* Then look into MANIFEST file of 2. manipulated jar, and you'll see "validate" 
transition is gone, and constructor argument @Property "hi" will be interpreted 
as "ipojo.InstanceManager" type. And you will see __M methods in manipulation 
section. If you try adding more annotations you'll see more errors in final 
MANIFEST.
                
> Re-manipulation with annotated component produces corrupted MANIFEST
> --------------------------------------------------------------------
>
>                 Key: FELIX-3461
>                 URL: https://issues.apache.org/jira/browse/FELIX-3461
>             Project: Felix
>          Issue Type: Bug
>          Components: iPOJO
>            Reporter: Göktürk Gezer
>              Labels: ipojo-manipulator
>         Attachments: FELIX-3461-GSA.patch, 
> org.apache.felix.ipojo.manipulator.patch
>
>
> As the manipulation process alters the annotations of original classes on 
> generated ones. It leaves it in inconsistent state for re-manipulation. While 
> re-manipulation process does not touch classes, re-manipulated bundle is 
> unable to function because of a corrupted MANIFEST.
> Broken MANIFEST is missing some handler declarations because of the filters 
> and have entries in manipulation section those should have been hided.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to