Class OakOSGiRepositoryFactory
- java.lang.Object
-
- org.apache.jackrabbit.oak.run.osgi.OakOSGiRepositoryFactory
-
- All Implemented Interfaces:
RepositoryFactory
public class OakOSGiRepositoryFactory extends Object implements RepositoryFactory
RepositoryFactory which constructs an instance of Oak repository. Thi factory supports following parameters- org.osgi.framework.BundleActivator
- (Optional) BundleActivator instance which would be notified about the startup and shutdown
- org.apache.jackrabbit.oak.repository.config
- (Optional) Config key which refers to the map of config where key in that map refers to OSGi config
- org.apache.jackrabbit.oak.repository.configFile
- Comma separated list of file names which referred to config stored in form of JSON. The JSON content consist of pid as the key and config map as the value
- org.apache.jackrabbit.repository.home
- Used to specify the absolute path of the repository home directory
- org.apache.jackrabbit.oak.repository.bundleFilter
- Used to specify the bundle filter string which is passed to ClasspathScanner
- org.apache.jackrabbit.oak.repository.timeoutInSecs
- Timeout in seconds for the repository startup/shutdown should wait. Defaults to 10 minutes
- org.apache.jackrabbit.oak.repository.shutDownOnTimeout
- Boolean flag to determine if the OSGi container should be shutdown upon timeout. Defaults to false
-
-
Field Summary
Fields Modifier and Type Field Description static StringREPOSITORY_BUNDLE_FILTERstatic StringREPOSITORY_BUNDLE_FILTER_DEFAULTstatic StringREPOSITORY_CONFIGConfig key which refers to the map of config where key in that map refers to OSGi configstatic StringREPOSITORY_CONFIG_FILEComma separated list of file names which referred to config stored in form of JSON.static StringREPOSITORY_ENV_SPRING_BOOTstatic StringREPOSITORY_HOMEName of the repository home parameter.static StringREPOSITORY_SHUTDOWN_ON_TIMEOUTstatic StringREPOSITORY_TIMEOUT_IN_SECSTimeout in seconds for the repository startup should wait
-
Constructor Summary
Constructors Constructor Description OakOSGiRepositoryFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RepositorygetRepository(Map parameters)protected voidpostProcessRegistry(org.apache.felix.connect.launch.PojoServiceRegistry registry)Enables post processing of service registry e.g.protected voidpreProcessRegistry(org.apache.felix.connect.launch.PojoServiceRegistry registry)Enables pre processing of service registry by sub classes.protected List<org.apache.felix.connect.launch.BundleDescriptor>processDescriptors(List<org.apache.felix.connect.launch.BundleDescriptor> descriptors)
-
-
-
Field Detail
-
REPOSITORY_HOME
public static final String REPOSITORY_HOME
Name of the repository home parameter.- See Also:
- Constant Field Values
-
REPOSITORY_TIMEOUT_IN_SECS
public static final String REPOSITORY_TIMEOUT_IN_SECS
Timeout in seconds for the repository startup should wait- See Also:
- Constant Field Values
-
REPOSITORY_CONFIG
public static final String REPOSITORY_CONFIG
Config key which refers to the map of config where key in that map refers to OSGi config- See Also:
- Constant Field Values
-
REPOSITORY_CONFIG_FILE
public static final String REPOSITORY_CONFIG_FILE
Comma separated list of file names which referred to config stored in form of JSON. The JSON content consist of pid as the key and config map as the value- See Also:
- Constant Field Values
-
REPOSITORY_BUNDLE_FILTER
public static final String REPOSITORY_BUNDLE_FILTER
- See Also:
- Constant Field Values
-
REPOSITORY_SHUTDOWN_ON_TIMEOUT
public static final String REPOSITORY_SHUTDOWN_ON_TIMEOUT
- See Also:
- Constant Field Values
-
REPOSITORY_ENV_SPRING_BOOT
public static final String REPOSITORY_ENV_SPRING_BOOT
- See Also:
- Constant Field Values
-
REPOSITORY_BUNDLE_FILTER_DEFAULT
public static final String REPOSITORY_BUNDLE_FILTER_DEFAULT
- See Also:
- Constant Field Values
-
-
Method Detail
-
getRepository
public Repository getRepository(Map parameters) throws RepositoryException
- Specified by:
getRepositoryin interfaceRepositoryFactory- Throws:
RepositoryException
-
preProcessRegistry
protected void preProcessRegistry(org.apache.felix.connect.launch.PojoServiceRegistry registry)
Enables pre processing of service registry by sub classes. This can be used to register services before any bundle gets started- Parameters:
registry- service registry
-
postProcessRegistry
protected void postProcessRegistry(org.apache.felix.connect.launch.PojoServiceRegistry registry)
Enables post processing of service registry e.g. registering new services etc by sub classes- Parameters:
registry- service registry
-
-