PAX-URL: “Protocol not supported” at Felix's s

2019-07-07 04:02发布

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!

1条回答
唯我独甜
2楼-- · 2019-07-07 04:19

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

查看更多
登录 后发表回答