3

I'm using PAX-URL to launch a Felix based project from Eclipse. I use the assembly protocol to avoid having to pre-pack my bundles.

In the project, felix is started using the felix.jar and a config.properties which includes felix.auto.start.1=assembly:foo/bar/classes to start one of my unpacked bundles.

The trouble is, felix doesn't know about the pax-url protocols until after it's finished reading that config file, so I get an "Unknown Protocol: assembly" error.

What am I doing wrong? Is it possible to tell Felix to load pax-url at boot time already?

Thanks!


The same problem is solved by this question. The way it's asked gives you a different way to look for the solution, so I'm going to not mark this question as a duplicate. Thanks Bjorn for the tip!

Community
  • 1
  • 1
Miquel
  • 15,405
  • 8
  • 54
  • 87

1 Answers1

4

You can cheat, adding pax url to the bootclasspath (depends on how you actually launch felix) and add the following system property to the starting vm: -Djava.protocol.handler.pkgs=org.ops4j.pax.url

Toni Menzel
  • 764
  • 3
  • 10
  • Thanks for your reply! I ultimately got it to work following the advice and link [here](http://stackoverflow.com/questions/5103505/cannot-use-pax-urls-assembly-protocol-with-auto-started-bundles-in-felix-config). I was able to do it without any bootclasspath changes – Miquel Aug 03 '11 at 12:45
  • 1
    @Miquel: If you find a good solution yourself, please post it as an answer and accept it. This helps others find it faster (users often don't read the comments, they just skim the accepted answer). – Björn Pollex Apr 18 '12 at 19:19
  • Thanks @Björn Pollex, I've added the answer explicitly – Miquel Apr 20 '12 at 16:42