[
https://issues.apache.org/jira/browse/FELIX-1462?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12740582#action_12740582
]
Richard S. Hall commented on FELIX-1462:
----------------------------------------
I committed a patch.
It was fairly straightforward:
1) I refactored AutoActivator to be AutoProcessor and it no longer implements
BundleActivator. Otherwise, it basically works the same as it did before.
2) I modified Main to use the FrameworkFactory to create the framework instance.
The framework factory is discovered by querying the class loader for the
META-INF/services framework factory resource. This means, if you want to use
the launcher with a different R4.2 framework you must put it on the class path.
Since the main.jar contains Felix' framework implementation, I would assume you
would launch a different framework by putting its JAR file on the class path
first. If this doesn't work, you could compile Main and package it without
embedding Felix' framework, then it would for sure work with any R4.2 framework
on the class path.
I will leave this issue open for now. One thing I was wondering about, should
we add a shutdown hook to the launcher? In the past, if someone does a
control-C, we just exit and the framework doesn't shut down. Should we add a
shutdown hook to try to make a clean shutdown or not worry about it?
> Felix framework launcher should only use standard launching API
> ---------------------------------------------------------------
>
> Key: FELIX-1462
> URL: https://issues.apache.org/jira/browse/FELIX-1462
> Project: Felix
> Issue Type: Improvement
> Components: Main
> Affects Versions: felix-1.8.1
> Reporter: Richard S. Hall
> Priority: Minor
> Fix For: felix-2.0.0
>
>
> Currently, the Felix framework launcher uses Felix-specific mechanisms to
> launch the framework. Specifically, it uses Felix' custom system bundle
> activator mechanism to handle processing of the auto properties for
> installing/starting bundles. We would need to restructure the launcher to do
> this processing externally, which would be fairly straightforward, then the
> launcher could be used with any R4.2 framework. Whether or not this is
> ultimately useful is debatable, but it would serve as a good example of how
> to create a generic launcher.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.