You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Matt Madhavan <ma...@gmail.com> on 2011/05/18 17:55:50 UTC

Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Hello,
I ran into a strange issue today. I'm running Felix container (3.2.0) with
some provisioned bundles by invoking *mvn pax:provision*

The OpenJpa bundle does not resolve (its in the installed stage!). I see the
following issue in the Felix console!

[qtp9097155-32 - /system/console/bundles/87] WARN / - %bundles.pluginTitle:
Cann
ot start
org.osgi.framework.BundleException: Unable to resolve module
org.apache.openjpa
[87.0] because it is exposed to package 'javax.transaction.xa' from
org.apache.g
eronimo.specs.geronimo-jta_1.1_spec [33.0] and org.apache.felix.framework
[0] vi
a two dependency chains.

*Chain 1:*
*  org.apache.openjpa [87.0]*
*    import:
(&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))*
*
*
*     |*
*    export: package=javax.transaction.xa*
*  org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]*
*
*
*Chain 2:*
*  org.apache.openjpa [87.0]*
*    import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))*
*     |*
*    export: package=javax.jms; uses:=javax.transaction.xa*
*  org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]*
*    import: (package=javax.transaction.xa)*
*     |*
*    export: package=javax.transaction.xa*
*  org.apache.felix.framework [0]*

*So Obviously javax.transaction.xa is getting resolved from two places;*

   1.  How do I fix (or whats the best way to fix this issue) ?
   2. Does Felix framework even export javax.transaction.xa ? I did not see
   any reference to the javax.transaction.xa inside the
   org.apache.felix.main_3.2.0.jar?

I'm really confused now? Any idea/help will be appreciated.

Thanks
Matt

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Oops, I meant to send my last e-mail to all three lists.

2011/5/20 Bartosz Kowalewski <ko...@gmail.com>:
> Hi,
>
> Honestly, I've never used this Maven plugin, so I'm not the right
> person to answer your questions :).
>
> Anyway, source code for this Mojo suggests, that 'mvn pax:provision'
> will always check reactor projects. If these are bundles, they're
> going to be provisioned and there's no way to disable this feature. If
> you want to exclude these created bundled, you need to change your
> multi-module Maven structure and place your generated bundle projects
> outside of the project from which you run 'mvn pax:provision'
>
> ... of course you an contribute a new feature for this plugin - a way
> to disable this behavior through plugin's <configuration>.
>
> Thanks,
>  Bartek
>
> 2011/5/19 Matt Madhavan <ma...@gmail.com>:
>> Hi Bartosz,
>> Thank you very much for the attachments. I now get it!
>> Also couple of quick questions! When I run bunch of maven-import-bundle it
>> adds the bundle as a dependency inside the provision/pom.xml.
>> When you run mvn pax:provision it provisions the bundles form
>> provision/pom.xml dependencies and also scans all the other "created bundles
>> - via pax:createbundle"'pom.xml dependencies as well.
>> I do not want this feature! I want the bundles to be provisioned only from
>> the provision/pom.xml file's dependencies - kind of like the Apache Aries
>> blog sample's assembly project!
>> How to I ensure that mvn pax:provision provisions bundles only from the
>> dependencies defined in the provision/pom.xml file only?
>> Any ideas?
>> Thanks in advance!
>> Matt
>> PS: Where are you from?
>>
>> On Thu, May 19, 2011 at 10:20 AM, Bartosz Kowalewski
>> <ko...@gmail.com> wrote:
>>>
>>> Hi Matt,
>>>
>>> There's no way to modify config.ini as it gets generated. You can only
>>> modify Pax Runner settings.
>>>
>>> Just copy the two files attached to this e-mail to the location from
>>> where you run: 'mvn pax:provision' and invoke:
>>> 'mvn pax:provision -Dargs=file:runner.args'.
>>>
>>> // I hope these mailing lists do accept attachements.
>>>
>>> The new profile (My-J2SE-1.5.profile) is based on
>>>
>>> https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
>>> with JTA packages "blocked". I you want to base your profile on a
>>> different Pax Runner execution env, you need to take a look at:
>>>
>>> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>>>
>>> Oh, it's probably possible to do this in a more straightforward way -
>>> keep on experimenting. Have fun! :)
>>>
>>> Bartek
>>>
>>> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>>> > Hello All,
>>> > Thanks for the reply! I kind of get the recommended solution! This is my
>>> > working scenerio
>>> >
>>> > I create the project using mvn pax:createproject
>>> > Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
>>> >  -Dversion=xxx
>>> > when I do mvn pax:provision - a folder called runner is created and
>>> > bunch of
>>> > bundles are provisioned into the runner/bundles folder.
>>> > Another folder called felix is also created with the felix/config.ini
>>> > inside
>>> > that
>>> > config.ini - contains all the bundle list and the config from the link
>>> > you
>>> > guys sent me earlier.
>>> >
>>> > This is my problem/question!
>>> > Every time I run mvn pax:provision the config.ini is overwritten! How do
>>> > I
>>> > override this?
>>> > Bartosz,
>>> > You offered the following solution
>>> > What you need to do is:
>>> > 1) set  --ee to None
>>> > 2) set the org.osgi.framework.executionenvironment property to
>>> >
>>> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>>> > 3) set system packages so that nearly the same set as the one
>>> > specified in the 1.5 profile is used; however JTA packages need to be
>>> > removed or somewhat "blocked for import"; you can "block" them using:
>>> > "javax.transaction; javax.transaction.xa; partial=true;
>>> > mandatory:=partial"
>>> > Can you be more explicit how do I do this in mvn pax:provision? And can
>>> > you
>>> > share some more info on the above steps? Also I would like to customize
>>> > the
>>> > config.ini creation as well like changing bundle start-level etc like
>>> > Richard suggests! How do I do that?
>>> > May be this is a question to Toni?
>>> > Thanks for the help and any more help will be appreciated!
>>> > Thanks
>>> > Matt
>>> >
>>> >
>>> >
>>> >
>>> > On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org>
>>> > wrote:
>>> >>
>>> >> Hi,
>>> >>
>>> >> It would also be worth asking the geronimo project to take a look. The
>>> >> geronimo JMS and geronimo JTA bundles do not seem to work nicely
>>> >> together which is a shame.
>>> >>
>>> >> Alasdair
>>> >>
>>> >> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
>>> >> wrote:
>>> >> > Hi,
>>> >> >
>>> >> > Felix itself does not provide JTA packages, but the system bundle
>>> >> > exports plenty of javax.* (and non-javax) packages. The packages that
>>> >> > are exported are defined in Pax Runner Profiles:
>>> >> >
>>> >> >
>>> >> > https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>>> >> >
>>> >> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
>>> >> > think that it's possible to remove only some of these packages. If
>>> >> > you
>>> >> > really want to play with the set of system packages, you can override
>>> >> > Pax Runner's profile completely. This is what we did in our Pax Exam
>>> >> > based tests. It's also possible to do it when using pure Pax Runner
>>> >> > or
>>> >> > the maven plugin. However, you'll probably need an external config
>>> >> > file for Pax Runner (and the 'args' parameter).
>>> >> >
>>> >> > What you need to do is:
>>> >> > 1) set  --ee to None
>>> >> > 2) set the org.osgi.framework.executionenvironment property to
>>> >> >
>>> >> >
>>> >> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>>> >> > 3) set system packages so that nearly the same set as the one
>>> >> > specified in the 1.5 profile is used; however JTA packages need to be
>>> >> > removed or somewhat "blocked for import"; you can "block" them using:
>>> >> > "javax.transaction; javax.transaction.xa; partial=true;
>>> >> > mandatory:=partial"
>>> >> >
>>> >> > Best regards,
>>> >> >  Bartek
>>> >> >
>>> >> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>>> >> >> Hello,
>>> >> >> I ran into a strange issue today. I'm running Felix container
>>> >> >> (3.2.0)
>>> >> >> with
>>> >> >> some provisioned bundles by invoking mvn pax:provision
>>> >> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
>>> >> >> see the
>>> >> >> following issue in the Felix console!
>>> >> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
>>> >> >> %bundles.pluginTitle:
>>> >> >> Cann
>>> >> >> ot start
>>> >> >> org.osgi.framework.BundleException: Unable to resolve module
>>> >> >> org.apache.openjpa
>>> >> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
>>> >> >> org.apache.g
>>> >> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
>>> >> >> org.apache.felix.framework
>>> >> >> [0] vi
>>> >> >> a two dependency chains.
>>> >> >> Chain 1:
>>> >> >>   org.apache.openjpa [87.0]
>>> >> >>     import:
>>> >> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>>> >> >>      |
>>> >> >>     export: package=javax.transaction.xa
>>> >> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>>> >> >> Chain 2:
>>> >> >>   org.apache.openjpa [87.0]
>>> >> >>     import:
>>> >> >> (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>>> >> >>      |
>>> >> >>     export: package=javax.jms; uses:=javax.transaction.xa
>>> >> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>>> >> >>     import: (package=javax.transaction.xa)
>>> >> >>      |
>>> >> >>     export: package=javax.transaction.xa
>>> >> >>   org.apache.felix.framework [0]
>>> >> >> So Obviously javax.transaction.xa is getting resolved from two
>>> >> >> places;
>>> >> >>
>>> >> >>  How do I fix (or whats the best way to fix this issue) ?
>>> >> >> Does Felix framework even export javax.transaction.xa ? I did not
>>> >> >> see
>>> >> >> any
>>> >> >> reference to the javax.transaction.xa inside the
>>> >> >> org.apache.felix.main_3.2.0.jar?
>>> >> >>
>>> >> >> I'm really confused now? Any idea/help will be appreciated.
>>> >> >> Thanks
>>> >> >> Matt
>>> >> >
>>> >> > ---------------------------------------------------------------------
>>> >> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> >> > For additional commands, e-mail: users-help@felix.apache.org
>>> >> >
>>> >> >
>>> >>
>>> >>
>>> >>
>>> >> --
>>> >> Alasdair Nottingham
>>> >> not@apache.org
>>> >>
>>> >> ---------------------------------------------------------------------
>>> >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> >> For additional commands, e-mail: users-help@felix.apache.org
>>> >>
>>> >
>>> >
>>
>>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Oops, I meant to send my last e-mail to all three lists.

2011/5/20 Bartosz Kowalewski <ko...@gmail.com>:
> Hi,
>
> Honestly, I've never used this Maven plugin, so I'm not the right
> person to answer your questions :).
>
> Anyway, source code for this Mojo suggests, that 'mvn pax:provision'
> will always check reactor projects. If these are bundles, they're
> going to be provisioned and there's no way to disable this feature. If
> you want to exclude these created bundled, you need to change your
> multi-module Maven structure and place your generated bundle projects
> outside of the project from which you run 'mvn pax:provision'
>
> ... of course you an contribute a new feature for this plugin - a way
> to disable this behavior through plugin's <configuration>.
>
> Thanks,
>  Bartek
>
> 2011/5/19 Matt Madhavan <ma...@gmail.com>:
>> Hi Bartosz,
>> Thank you very much for the attachments. I now get it!
>> Also couple of quick questions! When I run bunch of maven-import-bundle it
>> adds the bundle as a dependency inside the provision/pom.xml.
>> When you run mvn pax:provision it provisions the bundles form
>> provision/pom.xml dependencies and also scans all the other "created bundles
>> - via pax:createbundle"'pom.xml dependencies as well.
>> I do not want this feature! I want the bundles to be provisioned only from
>> the provision/pom.xml file's dependencies - kind of like the Apache Aries
>> blog sample's assembly project!
>> How to I ensure that mvn pax:provision provisions bundles only from the
>> dependencies defined in the provision/pom.xml file only?
>> Any ideas?
>> Thanks in advance!
>> Matt
>> PS: Where are you from?
>>
>> On Thu, May 19, 2011 at 10:20 AM, Bartosz Kowalewski
>> <ko...@gmail.com> wrote:
>>>
>>> Hi Matt,
>>>
>>> There's no way to modify config.ini as it gets generated. You can only
>>> modify Pax Runner settings.
>>>
>>> Just copy the two files attached to this e-mail to the location from
>>> where you run: 'mvn pax:provision' and invoke:
>>> 'mvn pax:provision -Dargs=file:runner.args'.
>>>
>>> // I hope these mailing lists do accept attachements.
>>>
>>> The new profile (My-J2SE-1.5.profile) is based on
>>>
>>> https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
>>> with JTA packages "blocked". I you want to base your profile on a
>>> different Pax Runner execution env, you need to take a look at:
>>>
>>> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>>>
>>> Oh, it's probably possible to do this in a more straightforward way -
>>> keep on experimenting. Have fun! :)
>>>
>>> Bartek
>>>
>>> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>>> > Hello All,
>>> > Thanks for the reply! I kind of get the recommended solution! This is my
>>> > working scenerio
>>> >
>>> > I create the project using mvn pax:createproject
>>> > Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
>>> >  -Dversion=xxx
>>> > when I do mvn pax:provision - a folder called runner is created and
>>> > bunch of
>>> > bundles are provisioned into the runner/bundles folder.
>>> > Another folder called felix is also created with the felix/config.ini
>>> > inside
>>> > that
>>> > config.ini - contains all the bundle list and the config from the link
>>> > you
>>> > guys sent me earlier.
>>> >
>>> > This is my problem/question!
>>> > Every time I run mvn pax:provision the config.ini is overwritten! How do
>>> > I
>>> > override this?
>>> > Bartosz,
>>> > You offered the following solution
>>> > What you need to do is:
>>> > 1) set  --ee to None
>>> > 2) set the org.osgi.framework.executionenvironment property to
>>> >
>>> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>>> > 3) set system packages so that nearly the same set as the one
>>> > specified in the 1.5 profile is used; however JTA packages need to be
>>> > removed or somewhat "blocked for import"; you can "block" them using:
>>> > "javax.transaction; javax.transaction.xa; partial=true;
>>> > mandatory:=partial"
>>> > Can you be more explicit how do I do this in mvn pax:provision? And can
>>> > you
>>> > share some more info on the above steps? Also I would like to customize
>>> > the
>>> > config.ini creation as well like changing bundle start-level etc like
>>> > Richard suggests! How do I do that?
>>> > May be this is a question to Toni?
>>> > Thanks for the help and any more help will be appreciated!
>>> > Thanks
>>> > Matt
>>> >
>>> >
>>> >
>>> >
>>> > On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org>
>>> > wrote:
>>> >>
>>> >> Hi,
>>> >>
>>> >> It would also be worth asking the geronimo project to take a look. The
>>> >> geronimo JMS and geronimo JTA bundles do not seem to work nicely
>>> >> together which is a shame.
>>> >>
>>> >> Alasdair
>>> >>
>>> >> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
>>> >> wrote:
>>> >> > Hi,
>>> >> >
>>> >> > Felix itself does not provide JTA packages, but the system bundle
>>> >> > exports plenty of javax.* (and non-javax) packages. The packages that
>>> >> > are exported are defined in Pax Runner Profiles:
>>> >> >
>>> >> >
>>> >> > https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>>> >> >
>>> >> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
>>> >> > think that it's possible to remove only some of these packages. If
>>> >> > you
>>> >> > really want to play with the set of system packages, you can override
>>> >> > Pax Runner's profile completely. This is what we did in our Pax Exam
>>> >> > based tests. It's also possible to do it when using pure Pax Runner
>>> >> > or
>>> >> > the maven plugin. However, you'll probably need an external config
>>> >> > file for Pax Runner (and the 'args' parameter).
>>> >> >
>>> >> > What you need to do is:
>>> >> > 1) set  --ee to None
>>> >> > 2) set the org.osgi.framework.executionenvironment property to
>>> >> >
>>> >> >
>>> >> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>>> >> > 3) set system packages so that nearly the same set as the one
>>> >> > specified in the 1.5 profile is used; however JTA packages need to be
>>> >> > removed or somewhat "blocked for import"; you can "block" them using:
>>> >> > "javax.transaction; javax.transaction.xa; partial=true;
>>> >> > mandatory:=partial"
>>> >> >
>>> >> > Best regards,
>>> >> >  Bartek
>>> >> >
>>> >> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>>> >> >> Hello,
>>> >> >> I ran into a strange issue today. I'm running Felix container
>>> >> >> (3.2.0)
>>> >> >> with
>>> >> >> some provisioned bundles by invoking mvn pax:provision
>>> >> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
>>> >> >> see the
>>> >> >> following issue in the Felix console!
>>> >> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
>>> >> >> %bundles.pluginTitle:
>>> >> >> Cann
>>> >> >> ot start
>>> >> >> org.osgi.framework.BundleException: Unable to resolve module
>>> >> >> org.apache.openjpa
>>> >> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
>>> >> >> org.apache.g
>>> >> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
>>> >> >> org.apache.felix.framework
>>> >> >> [0] vi
>>> >> >> a two dependency chains.
>>> >> >> Chain 1:
>>> >> >>   org.apache.openjpa [87.0]
>>> >> >>     import:
>>> >> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>>> >> >>      |
>>> >> >>     export: package=javax.transaction.xa
>>> >> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>>> >> >> Chain 2:
>>> >> >>   org.apache.openjpa [87.0]
>>> >> >>     import:
>>> >> >> (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>>> >> >>      |
>>> >> >>     export: package=javax.jms; uses:=javax.transaction.xa
>>> >> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>>> >> >>     import: (package=javax.transaction.xa)
>>> >> >>      |
>>> >> >>     export: package=javax.transaction.xa
>>> >> >>   org.apache.felix.framework [0]
>>> >> >> So Obviously javax.transaction.xa is getting resolved from two
>>> >> >> places;
>>> >> >>
>>> >> >>  How do I fix (or whats the best way to fix this issue) ?
>>> >> >> Does Felix framework even export javax.transaction.xa ? I did not
>>> >> >> see
>>> >> >> any
>>> >> >> reference to the javax.transaction.xa inside the
>>> >> >> org.apache.felix.main_3.2.0.jar?
>>> >> >>
>>> >> >> I'm really confused now? Any idea/help will be appreciated.
>>> >> >> Thanks
>>> >> >> Matt
>>> >> >
>>> >> > ---------------------------------------------------------------------
>>> >> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> >> > For additional commands, e-mail: users-help@felix.apache.org
>>> >> >
>>> >> >
>>> >>
>>> >>
>>> >>
>>> >> --
>>> >> Alasdair Nottingham
>>> >> not@apache.org
>>> >>
>>> >> ---------------------------------------------------------------------
>>> >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> >> For additional commands, e-mail: users-help@felix.apache.org
>>> >>
>>> >
>>> >
>>
>>
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Hi,

Honestly, I've never used this Maven plugin, so I'm not the right
person to answer your questions :).

Anyway, source code for this Mojo suggests, that 'mvn pax:provision'
will always check reactor projects. If these are bundles, they're
going to be provisioned and there's no way to disable this feature. If
you want to exclude these created bundled, you need to change your
multi-module Maven structure and place your generated bundle projects
outside of the project from which you run 'mvn pax:provision'

... of course you an contribute a new feature for this plugin - a way
to disable this behavior through plugin's <configuration>.

Thanks,
  Bartek

2011/5/19 Matt Madhavan <ma...@gmail.com>:
> Hi Bartosz,
> Thank you very much for the attachments. I now get it!
> Also couple of quick questions! When I run bunch of maven-import-bundle it
> adds the bundle as a dependency inside the provision/pom.xml.
> When you run mvn pax:provision it provisions the bundles form
> provision/pom.xml dependencies and also scans all the other "created bundles
> - via pax:createbundle"'pom.xml dependencies as well.
> I do not want this feature! I want the bundles to be provisioned only from
> the provision/pom.xml file's dependencies - kind of like the Apache Aries
> blog sample's assembly project!
> How to I ensure that mvn pax:provision provisions bundles only from the
> dependencies defined in the provision/pom.xml file only?
> Any ideas?
> Thanks in advance!
> Matt
> PS: Where are you from?
>
> On Thu, May 19, 2011 at 10:20 AM, Bartosz Kowalewski
> <ko...@gmail.com> wrote:
>>
>> Hi Matt,
>>
>> There's no way to modify config.ini as it gets generated. You can only
>> modify Pax Runner settings.
>>
>> Just copy the two files attached to this e-mail to the location from
>> where you run: 'mvn pax:provision' and invoke:
>> 'mvn pax:provision -Dargs=file:runner.args'.
>>
>> // I hope these mailing lists do accept attachements.
>>
>> The new profile (My-J2SE-1.5.profile) is based on
>>
>> https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
>> with JTA packages "blocked". I you want to base your profile on a
>> different Pax Runner execution env, you need to take a look at:
>>
>> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>>
>> Oh, it's probably possible to do this in a more straightforward way -
>> keep on experimenting. Have fun! :)
>>
>> Bartek
>>
>> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>> > Hello All,
>> > Thanks for the reply! I kind of get the recommended solution! This is my
>> > working scenerio
>> >
>> > I create the project using mvn pax:createproject
>> > Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
>> >  -Dversion=xxx
>> > when I do mvn pax:provision - a folder called runner is created and
>> > bunch of
>> > bundles are provisioned into the runner/bundles folder.
>> > Another folder called felix is also created with the felix/config.ini
>> > inside
>> > that
>> > config.ini - contains all the bundle list and the config from the link
>> > you
>> > guys sent me earlier.
>> >
>> > This is my problem/question!
>> > Every time I run mvn pax:provision the config.ini is overwritten! How do
>> > I
>> > override this?
>> > Bartosz,
>> > You offered the following solution
>> > What you need to do is:
>> > 1) set  --ee to None
>> > 2) set the org.osgi.framework.executionenvironment property to
>> >
>> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>> > 3) set system packages so that nearly the same set as the one
>> > specified in the 1.5 profile is used; however JTA packages need to be
>> > removed or somewhat "blocked for import"; you can "block" them using:
>> > "javax.transaction; javax.transaction.xa; partial=true;
>> > mandatory:=partial"
>> > Can you be more explicit how do I do this in mvn pax:provision? And can
>> > you
>> > share some more info on the above steps? Also I would like to customize
>> > the
>> > config.ini creation as well like changing bundle start-level etc like
>> > Richard suggests! How do I do that?
>> > May be this is a question to Toni?
>> > Thanks for the help and any more help will be appreciated!
>> > Thanks
>> > Matt
>> >
>> >
>> >
>> >
>> > On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org>
>> > wrote:
>> >>
>> >> Hi,
>> >>
>> >> It would also be worth asking the geronimo project to take a look. The
>> >> geronimo JMS and geronimo JTA bundles do not seem to work nicely
>> >> together which is a shame.
>> >>
>> >> Alasdair
>> >>
>> >> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
>> >> wrote:
>> >> > Hi,
>> >> >
>> >> > Felix itself does not provide JTA packages, but the system bundle
>> >> > exports plenty of javax.* (and non-javax) packages. The packages that
>> >> > are exported are defined in Pax Runner Profiles:
>> >> >
>> >> >
>> >> > https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>> >> >
>> >> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
>> >> > think that it's possible to remove only some of these packages. If
>> >> > you
>> >> > really want to play with the set of system packages, you can override
>> >> > Pax Runner's profile completely. This is what we did in our Pax Exam
>> >> > based tests. It's also possible to do it when using pure Pax Runner
>> >> > or
>> >> > the maven plugin. However, you'll probably need an external config
>> >> > file for Pax Runner (and the 'args' parameter).
>> >> >
>> >> > What you need to do is:
>> >> > 1) set  --ee to None
>> >> > 2) set the org.osgi.framework.executionenvironment property to
>> >> >
>> >> >
>> >> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>> >> > 3) set system packages so that nearly the same set as the one
>> >> > specified in the 1.5 profile is used; however JTA packages need to be
>> >> > removed or somewhat "blocked for import"; you can "block" them using:
>> >> > "javax.transaction; javax.transaction.xa; partial=true;
>> >> > mandatory:=partial"
>> >> >
>> >> > Best regards,
>> >> >  Bartek
>> >> >
>> >> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>> >> >> Hello,
>> >> >> I ran into a strange issue today. I'm running Felix container
>> >> >> (3.2.0)
>> >> >> with
>> >> >> some provisioned bundles by invoking mvn pax:provision
>> >> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
>> >> >> see the
>> >> >> following issue in the Felix console!
>> >> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
>> >> >> %bundles.pluginTitle:
>> >> >> Cann
>> >> >> ot start
>> >> >> org.osgi.framework.BundleException: Unable to resolve module
>> >> >> org.apache.openjpa
>> >> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
>> >> >> org.apache.g
>> >> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
>> >> >> org.apache.felix.framework
>> >> >> [0] vi
>> >> >> a two dependency chains.
>> >> >> Chain 1:
>> >> >>   org.apache.openjpa [87.0]
>> >> >>     import:
>> >> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>> >> >>      |
>> >> >>     export: package=javax.transaction.xa
>> >> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>> >> >> Chain 2:
>> >> >>   org.apache.openjpa [87.0]
>> >> >>     import:
>> >> >> (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>> >> >>      |
>> >> >>     export: package=javax.jms; uses:=javax.transaction.xa
>> >> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>> >> >>     import: (package=javax.transaction.xa)
>> >> >>      |
>> >> >>     export: package=javax.transaction.xa
>> >> >>   org.apache.felix.framework [0]
>> >> >> So Obviously javax.transaction.xa is getting resolved from two
>> >> >> places;
>> >> >>
>> >> >>  How do I fix (or whats the best way to fix this issue) ?
>> >> >> Does Felix framework even export javax.transaction.xa ? I did not
>> >> >> see
>> >> >> any
>> >> >> reference to the javax.transaction.xa inside the
>> >> >> org.apache.felix.main_3.2.0.jar?
>> >> >>
>> >> >> I'm really confused now? Any idea/help will be appreciated.
>> >> >> Thanks
>> >> >> Matt
>> >> >
>> >> > ---------------------------------------------------------------------
>> >> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> >> > For additional commands, e-mail: users-help@felix.apache.org
>> >> >
>> >> >
>> >>
>> >>
>> >>
>> >> --
>> >> Alasdair Nottingham
>> >> not@apache.org
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> >> For additional commands, e-mail: users-help@felix.apache.org
>> >>
>> >
>> >
>
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Matt Madhavan <ma...@gmail.com>.
Hi Bartosz,
Thank you very much for the attachments. I now get it!

Also couple of quick questions! When I run bunch of *maven-import-bundle* it
adds the bundle as a dependency inside the provision/pom.xml.
When you run mvn pax:provision it provisions the bundles form
provision/pom.xml dependencies and also scans all the other "created bundles
- via pax:createbundle"'pom.xml dependencies as well.

I do not want this feature! I want the bundles to be provisioned only from
the provision/pom.xml file's dependencies - kind of like the Apache Aries
blog sample's assembly project!

How to I ensure that mvn pax:provision provisions bundles only from the
dependencies defined in the provision/pom.xml file only?

Any ideas?

Thanks in advance!

Matt
PS: Where are you from?


On Thu, May 19, 2011 at 10:20 AM, Bartosz Kowalewski <
kowalewski.bartosz@gmail.com> wrote:

> Hi Matt,
>
> There's no way to modify config.ini as it gets generated. You can only
> modify Pax Runner settings.
>
> Just copy the two files attached to this e-mail to the location from
> where you run: 'mvn pax:provision' and invoke:
> 'mvn pax:provision -Dargs=file:runner.args'.
>
> // I hope these mailing lists do accept attachements.
>
> The new profile (My-J2SE-1.5.profile) is based on
>
> https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
> with JTA packages "blocked". I you want to base your profile on a
> different Pax Runner execution env, you need to take a look at:
>
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>
> Oh, it's probably possible to do this in a more straightforward way -
> keep on experimenting. Have fun! :)
>
> Bartek
>
> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> > Hello All,
> > Thanks for the reply! I kind of get the recommended solution! This is my
> > working scenerio
> >
> > I create the project using mvn pax:createproject
> > Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
>  -Dversion=xxx
> > when I do mvn pax:provision - a folder called runner is created and bunch
> of
> > bundles are provisioned into the runner/bundles folder.
> > Another folder called felix is also created with the felix/config.ini
> inside
> > that
> > config.ini - contains all the bundle list and the config from the link
> you
> > guys sent me earlier.
> >
> > This is my problem/question!
> > Every time I run mvn pax:provision the config.ini is overwritten! How do
> I
> > override this?
> > Bartosz,
> > You offered the following solution
> > What you need to do is:
> > 1) set  --ee to None
> > 2) set the org.osgi.framework.executionenvironment property to
> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> > 3) set system packages so that nearly the same set as the one
> > specified in the 1.5 profile is used; however JTA packages need to be
> > removed or somewhat "blocked for import"; you can "block" them using:
> > "javax.transaction; javax.transaction.xa; partial=true;
> > mandatory:=partial"
> > Can you be more explicit how do I do this in mvn pax:provision? And can
> you
> > share some more info on the above steps? Also I would like to customize
> the
> > config.ini creation as well like changing bundle start-level etc like
> > Richard suggests! How do I do that?
> > May be this is a question to Toni?
> > Thanks for the help and any more help will be appreciated!
> > Thanks
> > Matt
> >
> >
> >
> >
> > On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org>
> wrote:
> >>
> >> Hi,
> >>
> >> It would also be worth asking the geronimo project to take a look. The
> >> geronimo JMS and geronimo JTA bundles do not seem to work nicely
> >> together which is a shame.
> >>
> >> Alasdair
> >>
> >> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
> >> wrote:
> >> > Hi,
> >> >
> >> > Felix itself does not provide JTA packages, but the system bundle
> >> > exports plenty of javax.* (and non-javax) packages. The packages that
> >> > are exported are defined in Pax Runner Profiles:
> >> >
> >> >
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
> >> >
> >> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
> >> > think that it's possible to remove only some of these packages. If you
> >> > really want to play with the set of system packages, you can override
> >> > Pax Runner's profile completely. This is what we did in our Pax Exam
> >> > based tests. It's also possible to do it when using pure Pax Runner or
> >> > the maven plugin. However, you'll probably need an external config
> >> > file for Pax Runner (and the 'args' parameter).
> >> >
> >> > What you need to do is:
> >> > 1) set  --ee to None
> >> > 2) set the org.osgi.framework.executionenvironment property to
> >> >
> >> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> >> > 3) set system packages so that nearly the same set as the one
> >> > specified in the 1.5 profile is used; however JTA packages need to be
> >> > removed or somewhat "blocked for import"; you can "block" them using:
> >> > "javax.transaction; javax.transaction.xa; partial=true;
> >> > mandatory:=partial"
> >> >
> >> > Best regards,
> >> >  Bartek
> >> >
> >> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> >> >> Hello,
> >> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
> >> >> with
> >> >> some provisioned bundles by invoking mvn pax:provision
> >> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
> >> >> see the
> >> >> following issue in the Felix console!
> >> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
> >> >> %bundles.pluginTitle:
> >> >> Cann
> >> >> ot start
> >> >> org.osgi.framework.BundleException: Unable to resolve module
> >> >> org.apache.openjpa
> >> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
> >> >> org.apache.g
> >> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
> >> >> org.apache.felix.framework
> >> >> [0] vi
> >> >> a two dependency chains.
> >> >> Chain 1:
> >> >>   org.apache.openjpa [87.0]
> >> >>     import:
> >> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
> >> >>      |
> >> >>     export: package=javax.transaction.xa
> >> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> >> >> Chain 2:
> >> >>   org.apache.openjpa [87.0]
> >> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
> >> >>      |
> >> >>     export: package=javax.jms; uses:=javax.transaction.xa
> >> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
> >> >>     import: (package=javax.transaction.xa)
> >> >>      |
> >> >>     export: package=javax.transaction.xa
> >> >>   org.apache.felix.framework [0]
> >> >> So Obviously javax.transaction.xa is getting resolved from two
> places;
> >> >>
> >> >>  How do I fix (or whats the best way to fix this issue) ?
> >> >> Does Felix framework even export javax.transaction.xa ? I did not see
> >> >> any
> >> >> reference to the javax.transaction.xa inside the
> >> >> org.apache.felix.main_3.2.0.jar?
> >> >>
> >> >> I'm really confused now? Any idea/help will be appreciated.
> >> >> Thanks
> >> >> Matt
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> >> > For additional commands, e-mail: users-help@felix.apache.org
> >> >
> >> >
> >>
> >>
> >>
> >> --
> >> Alasdair Nottingham
> >> not@apache.org
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> >> For additional commands, e-mail: users-help@felix.apache.org
> >>
> >
> >
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Matt Madhavan <ma...@gmail.com>.
Hi Bartosz,
Thank you very much for the attachments. I now get it!

Also couple of quick questions! When I run bunch of *maven-import-bundle* it
adds the bundle as a dependency inside the provision/pom.xml.
When you run mvn pax:provision it provisions the bundles form
provision/pom.xml dependencies and also scans all the other "created bundles
- via pax:createbundle"'pom.xml dependencies as well.

I do not want this feature! I want the bundles to be provisioned only from
the provision/pom.xml file's dependencies - kind of like the Apache Aries
blog sample's assembly project!

How to I ensure that mvn pax:provision provisions bundles only from the
dependencies defined in the provision/pom.xml file only?

Any ideas?

Thanks in advance!

Matt
PS: Where are you from?


On Thu, May 19, 2011 at 10:20 AM, Bartosz Kowalewski <
kowalewski.bartosz@gmail.com> wrote:

> Hi Matt,
>
> There's no way to modify config.ini as it gets generated. You can only
> modify Pax Runner settings.
>
> Just copy the two files attached to this e-mail to the location from
> where you run: 'mvn pax:provision' and invoke:
> 'mvn pax:provision -Dargs=file:runner.args'.
>
> // I hope these mailing lists do accept attachements.
>
> The new profile (My-J2SE-1.5.profile) is based on
>
> https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
> with JTA packages "blocked". I you want to base your profile on a
> different Pax Runner execution env, you need to take a look at:
>
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>
> Oh, it's probably possible to do this in a more straightforward way -
> keep on experimenting. Have fun! :)
>
> Bartek
>
> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> > Hello All,
> > Thanks for the reply! I kind of get the recommended solution! This is my
> > working scenerio
> >
> > I create the project using mvn pax:createproject
> > Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
>  -Dversion=xxx
> > when I do mvn pax:provision - a folder called runner is created and bunch
> of
> > bundles are provisioned into the runner/bundles folder.
> > Another folder called felix is also created with the felix/config.ini
> inside
> > that
> > config.ini - contains all the bundle list and the config from the link
> you
> > guys sent me earlier.
> >
> > This is my problem/question!
> > Every time I run mvn pax:provision the config.ini is overwritten! How do
> I
> > override this?
> > Bartosz,
> > You offered the following solution
> > What you need to do is:
> > 1) set  --ee to None
> > 2) set the org.osgi.framework.executionenvironment property to
> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> > 3) set system packages so that nearly the same set as the one
> > specified in the 1.5 profile is used; however JTA packages need to be
> > removed or somewhat "blocked for import"; you can "block" them using:
> > "javax.transaction; javax.transaction.xa; partial=true;
> > mandatory:=partial"
> > Can you be more explicit how do I do this in mvn pax:provision? And can
> you
> > share some more info on the above steps? Also I would like to customize
> the
> > config.ini creation as well like changing bundle start-level etc like
> > Richard suggests! How do I do that?
> > May be this is a question to Toni?
> > Thanks for the help and any more help will be appreciated!
> > Thanks
> > Matt
> >
> >
> >
> >
> > On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org>
> wrote:
> >>
> >> Hi,
> >>
> >> It would also be worth asking the geronimo project to take a look. The
> >> geronimo JMS and geronimo JTA bundles do not seem to work nicely
> >> together which is a shame.
> >>
> >> Alasdair
> >>
> >> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
> >> wrote:
> >> > Hi,
> >> >
> >> > Felix itself does not provide JTA packages, but the system bundle
> >> > exports plenty of javax.* (and non-javax) packages. The packages that
> >> > are exported are defined in Pax Runner Profiles:
> >> >
> >> >
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
> >> >
> >> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
> >> > think that it's possible to remove only some of these packages. If you
> >> > really want to play with the set of system packages, you can override
> >> > Pax Runner's profile completely. This is what we did in our Pax Exam
> >> > based tests. It's also possible to do it when using pure Pax Runner or
> >> > the maven plugin. However, you'll probably need an external config
> >> > file for Pax Runner (and the 'args' parameter).
> >> >
> >> > What you need to do is:
> >> > 1) set  --ee to None
> >> > 2) set the org.osgi.framework.executionenvironment property to
> >> >
> >> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> >> > 3) set system packages so that nearly the same set as the one
> >> > specified in the 1.5 profile is used; however JTA packages need to be
> >> > removed or somewhat "blocked for import"; you can "block" them using:
> >> > "javax.transaction; javax.transaction.xa; partial=true;
> >> > mandatory:=partial"
> >> >
> >> > Best regards,
> >> >  Bartek
> >> >
> >> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> >> >> Hello,
> >> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
> >> >> with
> >> >> some provisioned bundles by invoking mvn pax:provision
> >> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
> >> >> see the
> >> >> following issue in the Felix console!
> >> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
> >> >> %bundles.pluginTitle:
> >> >> Cann
> >> >> ot start
> >> >> org.osgi.framework.BundleException: Unable to resolve module
> >> >> org.apache.openjpa
> >> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
> >> >> org.apache.g
> >> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
> >> >> org.apache.felix.framework
> >> >> [0] vi
> >> >> a two dependency chains.
> >> >> Chain 1:
> >> >>   org.apache.openjpa [87.0]
> >> >>     import:
> >> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
> >> >>      |
> >> >>     export: package=javax.transaction.xa
> >> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> >> >> Chain 2:
> >> >>   org.apache.openjpa [87.0]
> >> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
> >> >>      |
> >> >>     export: package=javax.jms; uses:=javax.transaction.xa
> >> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
> >> >>     import: (package=javax.transaction.xa)
> >> >>      |
> >> >>     export: package=javax.transaction.xa
> >> >>   org.apache.felix.framework [0]
> >> >> So Obviously javax.transaction.xa is getting resolved from two
> places;
> >> >>
> >> >>  How do I fix (or whats the best way to fix this issue) ?
> >> >> Does Felix framework even export javax.transaction.xa ? I did not see
> >> >> any
> >> >> reference to the javax.transaction.xa inside the
> >> >> org.apache.felix.main_3.2.0.jar?
> >> >>
> >> >> I'm really confused now? Any idea/help will be appreciated.
> >> >> Thanks
> >> >> Matt
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> >> > For additional commands, e-mail: users-help@felix.apache.org
> >> >
> >> >
> >>
> >>
> >>
> >> --
> >> Alasdair Nottingham
> >> not@apache.org
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> >> For additional commands, e-mail: users-help@felix.apache.org
> >>
> >
> >
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Hi Matt,

There's no way to modify config.ini as it gets generated. You can only
modify Pax Runner settings.

Just copy the two files attached to this e-mail to the location from
where you run: 'mvn pax:provision' and invoke:
'mvn pax:provision -Dargs=file:runner.args'.

// I hope these mailing lists do accept attachements.

The new profile (My-J2SE-1.5.profile) is based on
https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
with JTA packages "blocked". I you want to base your profile on a
different Pax Runner execution env, you need to take a look at:
https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee

Oh, it's probably possible to do this in a more straightforward way -
keep on experimenting. Have fun! :)

Bartek

2011/5/18 Matt Madhavan <ma...@gmail.com>:
> Hello All,
> Thanks for the reply! I kind of get the recommended solution! This is my
> working scenerio
>
> I create the project using mvn pax:createproject
> Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx  -Dversion=xxx
> when I do mvn pax:provision - a folder called runner is created and bunch of
> bundles are provisioned into the runner/bundles folder.
> Another folder called felix is also created with the felix/config.ini inside
> that
> config.ini - contains all the bundle list and the config from the link you
> guys sent me earlier.
>
> This is my problem/question!
> Every time I run mvn pax:provision the config.ini is overwritten! How do I
> override this?
> Bartosz,
> You offered the following solution
> What you need to do is:
> 1) set  --ee to None
> 2) set the org.osgi.framework.executionenvironment property to
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> 3) set system packages so that nearly the same set as the one
> specified in the 1.5 profile is used; however JTA packages need to be
> removed or somewhat "blocked for import"; you can "block" them using:
> "javax.transaction; javax.transaction.xa; partial=true;
> mandatory:=partial"
> Can you be more explicit how do I do this in mvn pax:provision? And can you
> share some more info on the above steps? Also I would like to customize the
> config.ini creation as well like changing bundle start-level etc like
> Richard suggests! How do I do that?
> May be this is a question to Toni?
> Thanks for the help and any more help will be appreciated!
> Thanks
> Matt
>
>
>
>
> On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org> wrote:
>>
>> Hi,
>>
>> It would also be worth asking the geronimo project to take a look. The
>> geronimo JMS and geronimo JTA bundles do not seem to work nicely
>> together which is a shame.
>>
>> Alasdair
>>
>> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
>> wrote:
>> > Hi,
>> >
>> > Felix itself does not provide JTA packages, but the system bundle
>> > exports plenty of javax.* (and non-javax) packages. The packages that
>> > are exported are defined in Pax Runner Profiles:
>> >
>> > https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>> >
>> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
>> > think that it's possible to remove only some of these packages. If you
>> > really want to play with the set of system packages, you can override
>> > Pax Runner's profile completely. This is what we did in our Pax Exam
>> > based tests. It's also possible to do it when using pure Pax Runner or
>> > the maven plugin. However, you'll probably need an external config
>> > file for Pax Runner (and the 'args' parameter).
>> >
>> > What you need to do is:
>> > 1) set  --ee to None
>> > 2) set the org.osgi.framework.executionenvironment property to
>> >
>> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>> > 3) set system packages so that nearly the same set as the one
>> > specified in the 1.5 profile is used; however JTA packages need to be
>> > removed or somewhat "blocked for import"; you can "block" them using:
>> > "javax.transaction; javax.transaction.xa; partial=true;
>> > mandatory:=partial"
>> >
>> > Best regards,
>> >  Bartek
>> >
>> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>> >> Hello,
>> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
>> >> with
>> >> some provisioned bundles by invoking mvn pax:provision
>> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
>> >> see the
>> >> following issue in the Felix console!
>> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
>> >> %bundles.pluginTitle:
>> >> Cann
>> >> ot start
>> >> org.osgi.framework.BundleException: Unable to resolve module
>> >> org.apache.openjpa
>> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
>> >> org.apache.g
>> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
>> >> org.apache.felix.framework
>> >> [0] vi
>> >> a two dependency chains.
>> >> Chain 1:
>> >>   org.apache.openjpa [87.0]
>> >>     import:
>> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>> >>      |
>> >>     export: package=javax.transaction.xa
>> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>> >> Chain 2:
>> >>   org.apache.openjpa [87.0]
>> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>> >>      |
>> >>     export: package=javax.jms; uses:=javax.transaction.xa
>> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>> >>     import: (package=javax.transaction.xa)
>> >>      |
>> >>     export: package=javax.transaction.xa
>> >>   org.apache.felix.framework [0]
>> >> So Obviously javax.transaction.xa is getting resolved from two places;
>> >>
>> >>  How do I fix (or whats the best way to fix this issue) ?
>> >> Does Felix framework even export javax.transaction.xa ? I did not see
>> >> any
>> >> reference to the javax.transaction.xa inside the
>> >> org.apache.felix.main_3.2.0.jar?
>> >>
>> >> I'm really confused now? Any idea/help will be appreciated.
>> >> Thanks
>> >> Matt
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> > For additional commands, e-mail: users-help@felix.apache.org
>> >
>> >
>>
>>
>>
>> --
>> Alasdair Nottingham
>> not@apache.org
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>
>


Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Hi Matt,

There's no way to modify config.ini as it gets generated. You can only
modify Pax Runner settings.

Just copy the two files attached to this e-mail to the location from
where you run: 'mvn pax:provision' and invoke:
'mvn pax:provision -Dargs=file:runner.args'.

// I hope these mailing lists do accept attachements.

The new profile (My-J2SE-1.5.profile) is based on
https://github.com/ops4j/org.ops4j.pax.runner/blob/master/pax-runner-platform/src/main/resources/META-INF/platform/ee/J2SE-1.5.profile
with JTA packages "blocked". I you want to base your profile on a
different Pax Runner execution env, you need to take a look at:
https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee

Oh, it's probably possible to do this in a more straightforward way -
keep on experimenting. Have fun! :)

Bartek

2011/5/18 Matt Madhavan <ma...@gmail.com>:
> Hello All,
> Thanks for the reply! I kind of get the recommended solution! This is my
> working scenerio
>
> I create the project using mvn pax:createproject
> Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx  -Dversion=xxx
> when I do mvn pax:provision - a folder called runner is created and bunch of
> bundles are provisioned into the runner/bundles folder.
> Another folder called felix is also created with the felix/config.ini inside
> that
> config.ini - contains all the bundle list and the config from the link you
> guys sent me earlier.
>
> This is my problem/question!
> Every time I run mvn pax:provision the config.ini is overwritten! How do I
> override this?
> Bartosz,
> You offered the following solution
> What you need to do is:
> 1) set  --ee to None
> 2) set the org.osgi.framework.executionenvironment property to
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> 3) set system packages so that nearly the same set as the one
> specified in the 1.5 profile is used; however JTA packages need to be
> removed or somewhat "blocked for import"; you can "block" them using:
> "javax.transaction; javax.transaction.xa; partial=true;
> mandatory:=partial"
> Can you be more explicit how do I do this in mvn pax:provision? And can you
> share some more info on the above steps? Also I would like to customize the
> config.ini creation as well like changing bundle start-level etc like
> Richard suggests! How do I do that?
> May be this is a question to Toni?
> Thanks for the help and any more help will be appreciated!
> Thanks
> Matt
>
>
>
>
> On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org> wrote:
>>
>> Hi,
>>
>> It would also be worth asking the geronimo project to take a look. The
>> geronimo JMS and geronimo JTA bundles do not seem to work nicely
>> together which is a shame.
>>
>> Alasdair
>>
>> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
>> wrote:
>> > Hi,
>> >
>> > Felix itself does not provide JTA packages, but the system bundle
>> > exports plenty of javax.* (and non-javax) packages. The packages that
>> > are exported are defined in Pax Runner Profiles:
>> >
>> > https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>> >
>> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
>> > think that it's possible to remove only some of these packages. If you
>> > really want to play with the set of system packages, you can override
>> > Pax Runner's profile completely. This is what we did in our Pax Exam
>> > based tests. It's also possible to do it when using pure Pax Runner or
>> > the maven plugin. However, you'll probably need an external config
>> > file for Pax Runner (and the 'args' parameter).
>> >
>> > What you need to do is:
>> > 1) set  --ee to None
>> > 2) set the org.osgi.framework.executionenvironment property to
>> >
>> > OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
>> > 3) set system packages so that nearly the same set as the one
>> > specified in the 1.5 profile is used; however JTA packages need to be
>> > removed or somewhat "blocked for import"; you can "block" them using:
>> > "javax.transaction; javax.transaction.xa; partial=true;
>> > mandatory:=partial"
>> >
>> > Best regards,
>> >  Bartek
>> >
>> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>> >> Hello,
>> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
>> >> with
>> >> some provisioned bundles by invoking mvn pax:provision
>> >> The OpenJpa bundle does not resolve (its in the installed stage!). I
>> >> see the
>> >> following issue in the Felix console!
>> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
>> >> %bundles.pluginTitle:
>> >> Cann
>> >> ot start
>> >> org.osgi.framework.BundleException: Unable to resolve module
>> >> org.apache.openjpa
>> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
>> >> org.apache.g
>> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
>> >> org.apache.felix.framework
>> >> [0] vi
>> >> a two dependency chains.
>> >> Chain 1:
>> >>   org.apache.openjpa [87.0]
>> >>     import:
>> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>> >>      |
>> >>     export: package=javax.transaction.xa
>> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>> >> Chain 2:
>> >>   org.apache.openjpa [87.0]
>> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>> >>      |
>> >>     export: package=javax.jms; uses:=javax.transaction.xa
>> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>> >>     import: (package=javax.transaction.xa)
>> >>      |
>> >>     export: package=javax.transaction.xa
>> >>   org.apache.felix.framework [0]
>> >> So Obviously javax.transaction.xa is getting resolved from two places;
>> >>
>> >>  How do I fix (or whats the best way to fix this issue) ?
>> >> Does Felix framework even export javax.transaction.xa ? I did not see
>> >> any
>> >> reference to the javax.transaction.xa inside the
>> >> org.apache.felix.main_3.2.0.jar?
>> >>
>> >> I'm really confused now? Any idea/help will be appreciated.
>> >> Thanks
>> >> Matt
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> > For additional commands, e-mail: users-help@felix.apache.org
>> >
>> >
>>
>>
>>
>> --
>> Alasdair Nottingham
>> not@apache.org
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Matt Madhavan <ma...@gmail.com>.
Hello All,
Thanks for the reply! I kind of get the recommended solution! This is my
working scenerio


   1. I create the project using mvn pax:createproject
   2. Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
    -Dversion=xxx
   3. when I do mvn pax:provision - a folder called runner is created and
   bunch of bundles are provisioned into the runner/bundles folder.
   4. Another folder called felix is also created with the felix/config.ini
   inside that
   5. config.ini - contains all the bundle list and the config from the link
   you guys sent me earlier.

This is my problem/question!
Every time I run mvn pax:provision the config.ini is overwritten! How do I
override this?

Bartosz,
You offered the following solution

*What you need to do is:
1) set  --ee to None
2) set the org.osgi.framework.executionenvironment property to
OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
3) set system packages so that nearly the same set as the one
specified in the 1.5 profile is used; however JTA packages need to be
removed or somewhat "blocked for import"; you can "block" them using:
"javax.transaction; javax.transaction.xa; partial=true;
mandatory:=partial"*

Can you be more explicit how do I do this in mvn pax:provision? And can you
share some more info on the above steps? Also I would like to customize the
config.ini creation as well like changing bundle start-level etc like
Richard suggests! How do I do that?

May be this is a question to Toni?

Thanks for the help and any more help will be appreciated!

Thanks
Matt





On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org> wrote:

> Hi,
>
> It would also be worth asking the geronimo project to take a look. The
> geronimo JMS and geronimo JTA bundles do not seem to work nicely
> together which is a shame.
>
> Alasdair
>
> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
> wrote:
> > Hi,
> >
> > Felix itself does not provide JTA packages, but the system bundle
> > exports plenty of javax.* (and non-javax) packages. The packages that
> > are exported are defined in Pax Runner Profiles:
> >
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
> >
> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
> > think that it's possible to remove only some of these packages. If you
> > really want to play with the set of system packages, you can override
> > Pax Runner's profile completely. This is what we did in our Pax Exam
> > based tests. It's also possible to do it when using pure Pax Runner or
> > the maven plugin. However, you'll probably need an external config
> > file for Pax Runner (and the 'args' parameter).
> >
> > What you need to do is:
> > 1) set  --ee to None
> > 2) set the org.osgi.framework.executionenvironment property to
> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> > 3) set system packages so that nearly the same set as the one
> > specified in the 1.5 profile is used; however JTA packages need to be
> > removed or somewhat "blocked for import"; you can "block" them using:
> > "javax.transaction; javax.transaction.xa; partial=true;
> > mandatory:=partial"
> >
> > Best regards,
> >  Bartek
> >
> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> >> Hello,
> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
> with
> >> some provisioned bundles by invoking mvn pax:provision
> >> The OpenJpa bundle does not resolve (its in the installed stage!). I see
> the
> >> following issue in the Felix console!
> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
> %bundles.pluginTitle:
> >> Cann
> >> ot start
> >> org.osgi.framework.BundleException: Unable to resolve module
> >> org.apache.openjpa
> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
> >> org.apache.g
> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
> org.apache.felix.framework
> >> [0] vi
> >> a two dependency chains.
> >> Chain 1:
> >>   org.apache.openjpa [87.0]
> >>     import:
> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
> >>      |
> >>     export: package=javax.transaction.xa
> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> >> Chain 2:
> >>   org.apache.openjpa [87.0]
> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
> >>      |
> >>     export: package=javax.jms; uses:=javax.transaction.xa
> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
> >>     import: (package=javax.transaction.xa)
> >>      |
> >>     export: package=javax.transaction.xa
> >>   org.apache.felix.framework [0]
> >> So Obviously javax.transaction.xa is getting resolved from two places;
> >>
> >>  How do I fix (or whats the best way to fix this issue) ?
> >> Does Felix framework even export javax.transaction.xa ? I did not see
> any
> >> reference to the javax.transaction.xa inside the
> >> org.apache.felix.main_3.2.0.jar?
> >>
> >> I'm really confused now? Any idea/help will be appreciated.
> >> Thanks
> >> Matt
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> > For additional commands, e-mail: users-help@felix.apache.org
> >
> >
>
>
>
> --
> Alasdair Nottingham
> not@apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Matt Madhavan <ma...@gmail.com>.
Hello All,
Thanks for the reply! I kind of get the recommended solution! This is my
working scenerio


   1. I create the project using mvn pax:createproject
   2. Then I run bunch of mvn pax:create-bundle -Dpackage=com.xxx
    -Dversion=xxx
   3. when I do mvn pax:provision - a folder called runner is created and
   bunch of bundles are provisioned into the runner/bundles folder.
   4. Another folder called felix is also created with the felix/config.ini
   inside that
   5. config.ini - contains all the bundle list and the config from the link
   you guys sent me earlier.

This is my problem/question!
Every time I run mvn pax:provision the config.ini is overwritten! How do I
override this?

Bartosz,
You offered the following solution

*What you need to do is:
1) set  --ee to None
2) set the org.osgi.framework.executionenvironment property to
OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
3) set system packages so that nearly the same set as the one
specified in the 1.5 profile is used; however JTA packages need to be
removed or somewhat "blocked for import"; you can "block" them using:
"javax.transaction; javax.transaction.xa; partial=true;
mandatory:=partial"*

Can you be more explicit how do I do this in mvn pax:provision? And can you
share some more info on the above steps? Also I would like to customize the
config.ini creation as well like changing bundle start-level etc like
Richard suggests! How do I do that?

May be this is a question to Toni?

Thanks for the help and any more help will be appreciated!

Thanks
Matt





On Wed, May 18, 2011 at 1:15 PM, Alasdair Nottingham <no...@apache.org> wrote:

> Hi,
>
> It would also be worth asking the geronimo project to take a look. The
> geronimo JMS and geronimo JTA bundles do not seem to work nicely
> together which is a shame.
>
> Alasdair
>
> On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com>
> wrote:
> > Hi,
> >
> > Felix itself does not provide JTA packages, but the system bundle
> > exports plenty of javax.* (and non-javax) packages. The packages that
> > are exported are defined in Pax Runner Profiles:
> >
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
> >
> > JTA packages are exported in both the 1.5 and 1.6 profile. I don't
> > think that it's possible to remove only some of these packages. If you
> > really want to play with the set of system packages, you can override
> > Pax Runner's profile completely. This is what we did in our Pax Exam
> > based tests. It's also possible to do it when using pure Pax Runner or
> > the maven plugin. However, you'll probably need an external config
> > file for Pax Runner (and the 'args' parameter).
> >
> > What you need to do is:
> > 1) set  --ee to None
> > 2) set the org.osgi.framework.executionenvironment property to
> >
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> > 3) set system packages so that nearly the same set as the one
> > specified in the 1.5 profile is used; however JTA packages need to be
> > removed or somewhat "blocked for import"; you can "block" them using:
> > "javax.transaction; javax.transaction.xa; partial=true;
> > mandatory:=partial"
> >
> > Best regards,
> >  Bartek
> >
> > 2011/5/18 Matt Madhavan <ma...@gmail.com>:
> >> Hello,
> >> I ran into a strange issue today. I'm running Felix container (3.2.0)
> with
> >> some provisioned bundles by invoking mvn pax:provision
> >> The OpenJpa bundle does not resolve (its in the installed stage!). I see
> the
> >> following issue in the Felix console!
> >> [qtp9097155-32 - /system/console/bundles/87] WARN / -
> %bundles.pluginTitle:
> >> Cann
> >> ot start
> >> org.osgi.framework.BundleException: Unable to resolve module
> >> org.apache.openjpa
> >> [87.0] because it is exposed to package 'javax.transaction.xa' from
> >> org.apache.g
> >> eronimo.specs.geronimo-jta_1.1_spec [33.0] and
> org.apache.felix.framework
> >> [0] vi
> >> a two dependency chains.
> >> Chain 1:
> >>   org.apache.openjpa [87.0]
> >>     import:
> >> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
> >>      |
> >>     export: package=javax.transaction.xa
> >>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> >> Chain 2:
> >>   org.apache.openjpa [87.0]
> >>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
> >>      |
> >>     export: package=javax.jms; uses:=javax.transaction.xa
> >>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
> >>     import: (package=javax.transaction.xa)
> >>      |
> >>     export: package=javax.transaction.xa
> >>   org.apache.felix.framework [0]
> >> So Obviously javax.transaction.xa is getting resolved from two places;
> >>
> >>  How do I fix (or whats the best way to fix this issue) ?
> >> Does Felix framework even export javax.transaction.xa ? I did not see
> any
> >> reference to the javax.transaction.xa inside the
> >> org.apache.felix.main_3.2.0.jar?
> >>
> >> I'm really confused now? Any idea/help will be appreciated.
> >> Thanks
> >> Matt
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> > For additional commands, e-mail: users-help@felix.apache.org
> >
> >
>
>
>
> --
> Alasdair Nottingham
> not@apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Alasdair Nottingham <no...@apache.org>.
Hi,

It would also be worth asking the geronimo project to take a look. The
geronimo JMS and geronimo JTA bundles do not seem to work nicely
together which is a shame.

Alasdair

On 18 May 2011 18:09, Bartosz Kowalewski <ko...@gmail.com> wrote:
> Hi,
>
> Felix itself does not provide JTA packages, but the system bundle
> exports plenty of javax.* (and non-javax) packages. The packages that
> are exported are defined in Pax Runner Profiles:
> https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee
>
> JTA packages are exported in both the 1.5 and 1.6 profile. I don't
> think that it's possible to remove only some of these packages. If you
> really want to play with the set of system packages, you can override
> Pax Runner's profile completely. This is what we did in our Pax Exam
> based tests. It's also possible to do it when using pure Pax Runner or
> the maven plugin. However, you'll probably need an external config
> file for Pax Runner (and the 'args' parameter).
>
> What you need to do is:
> 1) set  --ee to None
> 2) set the org.osgi.framework.executionenvironment property to
> OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
> 3) set system packages so that nearly the same set as the one
> specified in the 1.5 profile is used; however JTA packages need to be
> removed or somewhat "blocked for import"; you can "block" them using:
> "javax.transaction; javax.transaction.xa; partial=true;
> mandatory:=partial"
>
> Best regards,
>  Bartek
>
> 2011/5/18 Matt Madhavan <ma...@gmail.com>:
>> Hello,
>> I ran into a strange issue today. I'm running Felix container (3.2.0) with
>> some provisioned bundles by invoking mvn pax:provision
>> The OpenJpa bundle does not resolve (its in the installed stage!). I see the
>> following issue in the Felix console!
>> [qtp9097155-32 - /system/console/bundles/87] WARN / - %bundles.pluginTitle:
>> Cann
>> ot start
>> org.osgi.framework.BundleException: Unable to resolve module
>> org.apache.openjpa
>> [87.0] because it is exposed to package 'javax.transaction.xa' from
>> org.apache.g
>> eronimo.specs.geronimo-jta_1.1_spec [33.0] and org.apache.felix.framework
>> [0] vi
>> a two dependency chains.
>> Chain 1:
>>   org.apache.openjpa [87.0]
>>     import:
>> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>>      |
>>     export: package=javax.transaction.xa
>>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
>> Chain 2:
>>   org.apache.openjpa [87.0]
>>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>>      |
>>     export: package=javax.jms; uses:=javax.transaction.xa
>>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>>     import: (package=javax.transaction.xa)
>>      |
>>     export: package=javax.transaction.xa
>>   org.apache.felix.framework [0]
>> So Obviously javax.transaction.xa is getting resolved from two places;
>>
>>  How do I fix (or whats the best way to fix this issue) ?
>> Does Felix framework even export javax.transaction.xa ? I did not see any
>> reference to the javax.transaction.xa inside the
>> org.apache.felix.main_3.2.0.jar?
>>
>> I'm really confused now? Any idea/help will be appreciated.
>> Thanks
>> Matt
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>



-- 
Alasdair Nottingham
not@apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Hi,

Felix itself does not provide JTA packages, but the system bundle
exports plenty of javax.* (and non-javax) packages. The packages that
are exported are defined in Pax Runner Profiles:
https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee

JTA packages are exported in both the 1.5 and 1.6 profile. I don't
think that it's possible to remove only some of these packages. If you
really want to play with the set of system packages, you can override
Pax Runner's profile completely. This is what we did in our Pax Exam
based tests. It's also possible to do it when using pure Pax Runner or
the maven plugin. However, you'll probably need an external config
file for Pax Runner (and the 'args' parameter).

What you need to do is:
1) set  --ee to None
2) set the org.osgi.framework.executionenvironment property to
OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
3) set system packages so that nearly the same set as the one
specified in the 1.5 profile is used; however JTA packages need to be
removed or somewhat "blocked for import"; you can "block" them using:
"javax.transaction; javax.transaction.xa; partial=true;
mandatory:=partial"

Best regards,
  Bartek

2011/5/18 Matt Madhavan <ma...@gmail.com>:
> Hello,
> I ran into a strange issue today. I'm running Felix container (3.2.0) with
> some provisioned bundles by invoking mvn pax:provision
> The OpenJpa bundle does not resolve (its in the installed stage!). I see the
> following issue in the Felix console!
> [qtp9097155-32 - /system/console/bundles/87] WARN / - %bundles.pluginTitle:
> Cann
> ot start
> org.osgi.framework.BundleException: Unable to resolve module
> org.apache.openjpa
> [87.0] because it is exposed to package 'javax.transaction.xa' from
> org.apache.g
> eronimo.specs.geronimo-jta_1.1_spec [33.0] and org.apache.felix.framework
> [0] vi
> a two dependency chains.
> Chain 1:
>   org.apache.openjpa [87.0]
>     import:
> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>      |
>     export: package=javax.transaction.xa
>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> Chain 2:
>   org.apache.openjpa [87.0]
>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>      |
>     export: package=javax.jms; uses:=javax.transaction.xa
>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>     import: (package=javax.transaction.xa)
>      |
>     export: package=javax.transaction.xa
>   org.apache.felix.framework [0]
> So Obviously javax.transaction.xa is getting resolved from two places;
>
>  How do I fix (or whats the best way to fix this issue) ?
> Does Felix framework even export javax.transaction.xa ? I did not see any
> reference to the javax.transaction.xa inside the
> org.apache.felix.main_3.2.0.jar?
>
> I'm really confused now? Any idea/help will be appreciated.
> Thanks
> Matt

Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by "Richard S. Hall" <he...@ungoverned.org>.
[removing the cross posting]

You have a few choices:

   1. Resolve bundle 33 before 88, which will raise the priority of its
      javax.transaction.xa package.
   2. Modify 88's import of javax.transaction.xa to include a version
      range that excludes 0.0.0 (i.e., the system bundle).
   3. Modify the framework to not export javax.transaction.xa (i.e.,
      create an org.osgi.framework.system.packages property in
      conf/config.properties that doesn't include it -- you can just
      copy this property from the default.properties file inside the
      Felix framework JAR file and remove the offending package).

-> richard


On 5/18/11 11:55, Matt Madhavan wrote:
> Hello,
> I ran into a strange issue today. I'm running Felix container (3.2.0) 
> with some provisioned bundles by invoking *mvn pax:provision*
>
> The OpenJpa bundle does not resolve (its in the installed stage!). I 
> see the following issue in the Felix console!
>
> [qtp9097155-32 - /system/console/bundles/87] WARN / - 
> %bundles.pluginTitle: Cann
> ot start
> org.osgi.framework.BundleException: Unable to resolve module 
> org.apache.openjpa
> [87.0] because it is exposed to package 'javax.transaction.xa' from 
> org.apache.g
> eronimo.specs.geronimo-jta_1.1_spec [33.0] and 
> org.apache.felix.framework [0] vi
> a two dependency chains.
>
> *Chain 1:*
> *  org.apache.openjpa [87.0]*
> *    import: 
> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))*
> *
> *
> *     |*
> *    export: package=javax.transaction.xa*
> *  org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]*
> *
> *
> *Chain 2:*
> *  org.apache.openjpa [87.0]*
> *    import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))*
> *     |*
> *    export: package=javax.jms; uses:=javax.transaction.xa*
> *  org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]*
> *    import: (package=javax.transaction.xa)*
> *     |*
> *    export: package=javax.transaction.xa*
> *  org.apache.felix.framework [0]*
>
> _So Obviously javax.transaction.xa is getting resolved from two places;_
>
>    1.  How do I fix (or whats the best way to fix this issue) ?
>    2. Does Felix framework even export javax.transaction.xa ? I did
>       not see any reference to the javax.transaction.xa inside the
>       org.apache.felix.main_3.2.0.jar?
>
> I'm really confused now? Any idea/help will be appreciated.
>
> Thanks
> Matt
>
>
> _______________________________________________
> general mailing list
> general@lists.ops4j.org
> http://lists.ops4j.org/mailman/listinfo/general

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix/pax runner cyclic dependency issue - whats the common way to solve this?

Posted by Bartosz Kowalewski <ko...@gmail.com>.
Hi,

Felix itself does not provide JTA packages, but the system bundle
exports plenty of javax.* (and non-javax) packages. The packages that
are exported are defined in Pax Runner Profiles:
https://github.com/ops4j/org.ops4j.pax.runner/tree/master/pax-runner-platform/src/main/resources/META-INF/platform/ee

JTA packages are exported in both the 1.5 and 1.6 profile. I don't
think that it's possible to remove only some of these packages. If you
really want to play with the set of system packages, you can override
Pax Runner's profile completely. This is what we did in our Pax Exam
based tests. It's also possible to do it when using pure Pax Runner or
the maven plugin. However, you'll probably need an external config
file for Pax Runner (and the 'args' parameter).

What you need to do is:
1) set  --ee to None
2) set the org.osgi.framework.executionenvironment property to
OSGi/Minimum-1.0,OSGi/Minimum-1.1,OSGi/Minimum-1.0,JRE-1.1,J2SE-1.2,J2SE-1.3,J2SE-1.4,J2SE-1.5
3) set system packages so that nearly the same set as the one
specified in the 1.5 profile is used; however JTA packages need to be
removed or somewhat "blocked for import"; you can "block" them using:
"javax.transaction; javax.transaction.xa; partial=true;
mandatory:=partial"

Best regards,
  Bartek

2011/5/18 Matt Madhavan <ma...@gmail.com>:
> Hello,
> I ran into a strange issue today. I'm running Felix container (3.2.0) with
> some provisioned bundles by invoking mvn pax:provision
> The OpenJpa bundle does not resolve (its in the installed stage!). I see the
> following issue in the Felix console!
> [qtp9097155-32 - /system/console/bundles/87] WARN / - %bundles.pluginTitle:
> Cann
> ot start
> org.osgi.framework.BundleException: Unable to resolve module
> org.apache.openjpa
> [87.0] because it is exposed to package 'javax.transaction.xa' from
> org.apache.g
> eronimo.specs.geronimo-jta_1.1_spec [33.0] and org.apache.felix.framework
> [0] vi
> a two dependency chains.
> Chain 1:
>   org.apache.openjpa [87.0]
>     import:
> (&(package=javax.transaction.xa)(version>=1.1.0)(!(version>=1.2.0)))
>      |
>     export: package=javax.transaction.xa
>   org.apache.geronimo.specs.geronimo-jta_1.1_spec [33.0]
> Chain 2:
>   org.apache.openjpa [87.0]
>     import: (&(package=javax.jms)(version>=1.1.0)(!(version>=1.2.0)))
>      |
>     export: package=javax.jms; uses:=javax.transaction.xa
>   org.apache.geronimo.specs.geronimo-jms_1.1_spec [88.0]
>     import: (package=javax.transaction.xa)
>      |
>     export: package=javax.transaction.xa
>   org.apache.felix.framework [0]
> So Obviously javax.transaction.xa is getting resolved from two places;
>
>  How do I fix (or whats the best way to fix this issue) ?
> Does Felix framework even export javax.transaction.xa ? I did not see any
> reference to the javax.transaction.xa inside the
> org.apache.felix.main_3.2.0.jar?
>
> I'm really confused now? Any idea/help will be appreciated.
> Thanks
> Matt

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org