[hibernate-issues] [Hibernate-JIRA] Issue Comment Edited: (HV-267) Enhance distribution jar to make it OSGi bundle

Hardy Ferentschik (JIRA) noreply at atlassian.com
Mon Mar 15 15:00:46 EDT 2010


    [ http://opensource.atlassian.com/projects/hibernate/browse/HV-267?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=34454#action_34454 ] 

Hardy Ferentschik edited comment on HV-267 at 3/15/10 1:59 PM:
---------------------------------------------------------------

I guess we could use the Felix Bundle Plugin and do something like this:
{code}
<plugin>
  <artifactId>maven-jar-plugin</artifactId>
  <configuration>
    <archive>  
      <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
    </archive> 
  </configuration>
</plugin>  
<plugin>   
  <groupId>org.apache.felix</groupId>
  <artifactId>maven-bundle-plugin</artifactId>
  <executions>
    <execution>
      <id>bundle-manifest</id>
      <phase>process-classes</phase>
      <goals>    
        <goal>manifest</goal>
      </goals>   
    </execution>
  </executions>
</plugin>
{code}

However, this also lists jtype as dependency which means that the bundle plugin works so well together with the shade plugin. I guess the bundle manifest should be created from the dependency reduced pom. 
I also need to understand the Import/Export Package entries better and what these different versions mean.

      was (Author: hardy.ferentschik):
    I guess we could use the Felix Bundle Plugin and do something like this:

			<plugin>
			  <artifactId>maven-jar-plugin</artifactId>
			  <configuration>
			    <archive>  
			      <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
			    </archive> 
			  </configuration>
			</plugin>  
			<plugin>   
			  <groupId>org.apache.felix</groupId>
			  <artifactId>maven-bundle-plugin</artifactId>
			  <executions>
			    <execution>
			      <id>bundle-manifest</id>
			      <phase>process-classes</phase>
			      <goals>    
			        <goal>manifest</goal>
			      </goals>   
			    </execution>
			  </executions>
			</plugin>

However, this also lists jtype as dependency which means that the bundle plugin works so well together with the shade plugin. I guess the bundle manifest should be created from the dependency reduced pom. 
I also need to understand the Import/Export Package entries better and what these different versions mean.
  
> Enhance distribution jar to make it OSGi bundle
> -----------------------------------------------
>
>                 Key: HV-267
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HV-267
>             Project: Hibernate Validator
>          Issue Type: Improvement
>          Components: build
>    Affects Versions: 4.0.1.GA
>            Reporter: Jaro Kuruc
>             Fix For: 4.1.0-Beta-1
>
>         Attachments: maven-bundle-plugin.patch
>
>
> Hi, please consider enhancing validator's maven build to produce OSGi compliant bundle by adding OSGi specific manifest headers. At the moment, there are 2 options to do that:
> 1. Felix Bundle Plugin
> http://felix.apache.org/site/apache-felix-maven-bundle-plugin-bnd.html
> 2. SpringSource Bundlor
> http://static.springsource.org/s2-bundlor/1.0.x/user-guide/html/ch03s03.html
> Also, take a look at the bundle which has been produced by SpringSource
> http://www.springsource.com/repository/app/bundle/version/detail?name=com.springsource.org.hibernate.validator&version=4.0.0.GA

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list