![]() As such, these packages will never be looked up in package wirings as are packages imported by listing them in the Import-Package bundle manifest header. ![]() - This property lists packages, which are always used from the environment.These packages are used in the resolution process just as any package listed in an Export-Package bundle manifest header. .packages - This property lists package names which are added to the list of exported packages of the system bundle of the OSGi framework.To cope with this sharing issue, the OSGi core specification defines two properties, which may list packages to be used from the environment: In the case of a Sling Application accessing a JCR Repository launched in a different Web Application, this mainly concerns an API packages as well as the JNDI Initial Factory package(s). This is especially true for OSGi framework instances launched in embedding such as Servlet Containers. Some packages may have to be shared between bundles in an OSGi framework and the rest of Java VM in which the framework has been launched. This is used to include the JRE package list to be made visible inside the OSGi framework. Make sure the property is set defining a sensible default value if missing.Overwrite with any properties provided by the main class or the Sling Servlet.This is mainly used to resolve the correct JRE package definitions for the JRE version used. Load core properties from the embedded sling.properties file.The properties are prepared as a instance as follows (later steps may overwrite properties defined in earlier steps) : The Sling launcher is responsible to provide the Framework properties to the OSGi framework. This class is used by the standalone main class ( .main.Main) and the Sling Servlet ( .servlet.SlingServlet) to control the lifecycle. The lifecycle of the OSGi framework implemented by an instance of the .Felix class is managed by the Sling launcher class .Sling. Components may but are not required to make use of Framework properties by accessing the BundleContext through the ComponentContext given to the activate(ComponentContext) method of the component. The descriptor property values may be seen as configuration default values set by the component developer, which may be overwritten by user configuration through the Configuration Admin Service. Configuration properties provided to ManagedService and ManagedServiceFactory instances by the Configuration Admin Service.įor the discussion to follow we differentiate between initial configuration provided by Framework and system properties and managed configuration provided by the Configuration Admin Service.Ĭomponents managed by the Service Component Runtime are generally configured (as listed above) through the descriptor properties and configuration set by Configuration Admin Service configuration.Properties set in the component descriptor.Properties retrieved from the Configuration Admin Service.Configuration specified specifically for factory components.Components managed by the Service Component Runtime and declared in component descriptor files listed in the Service-Component manifest header access configuration properties through the ComponentContext.getProperties() method. ![]() In fact, all main manifest attributes are available through these methods. ![]() These header values are set by the bundle developer in the META-INF/MANIFEST.MF file.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |