Package org.apache.karaf.features
Interface FeaturesService
-
- All Known Implementing Classes:
FeaturesServiceImpl
public interface FeaturesService
The service managing features repositories.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
FeaturesService.Option
static class
FeaturesService.ServiceRequirementsBehavior
Configuration options for handling requirements fromServiceNamespace.SERVICE_NAMESPACE
namespacestatic class
FeaturesService.SnapshotUpdateBehavior
Configuration options for checking whether update'able bundle should really be updated
-
Field Summary
Fields Modifier and Type Field Description static boolean
DEFAULT_AUTO_REFRESH
static String
DEFAULT_BUNDLE_UPDATE_RANGE
static boolean
DEFAULT_CONFIG_CFG_STORE
static boolean
DEFAULT_DIGRAPH_MBEAN
static int
DEFAULT_DOWNLOAD_THREADS
static String
DEFAULT_FEATURE_RESOLUTION_RANGE
static long
DEFAULT_REPOSITORY_EXPIRATION
static long
DEFAULT_SCHEDULE_DELAY
static int
DEFAULT_SCHEDULE_MAX_RUN
static FeaturesService.SnapshotUpdateBehavior
DEFAULT_UPDATE_SNAPSHOTS
static String
ROOT_REGION
static String
UPDATEABLE_URIS
-
Method Summary
-
-
-
Field Detail
-
ROOT_REGION
static final String ROOT_REGION
- See Also:
- Constant Field Values
-
DEFAULT_UPDATE_SNAPSHOTS
static final FeaturesService.SnapshotUpdateBehavior DEFAULT_UPDATE_SNAPSHOTS
-
DEFAULT_FEATURE_RESOLUTION_RANGE
static final String DEFAULT_FEATURE_RESOLUTION_RANGE
- See Also:
- Constant Field Values
-
DEFAULT_BUNDLE_UPDATE_RANGE
static final String DEFAULT_BUNDLE_UPDATE_RANGE
- See Also:
- Constant Field Values
-
UPDATEABLE_URIS
static final String UPDATEABLE_URIS
- See Also:
- Constant Field Values
-
DEFAULT_DOWNLOAD_THREADS
static final int DEFAULT_DOWNLOAD_THREADS
- See Also:
- Constant Field Values
-
DEFAULT_SCHEDULE_DELAY
static final long DEFAULT_SCHEDULE_DELAY
- See Also:
- Constant Field Values
-
DEFAULT_SCHEDULE_MAX_RUN
static final int DEFAULT_SCHEDULE_MAX_RUN
- See Also:
- Constant Field Values
-
DEFAULT_REPOSITORY_EXPIRATION
static final long DEFAULT_REPOSITORY_EXPIRATION
- See Also:
- Constant Field Values
-
DEFAULT_AUTO_REFRESH
static final boolean DEFAULT_AUTO_REFRESH
- See Also:
- Constant Field Values
-
DEFAULT_CONFIG_CFG_STORE
static final boolean DEFAULT_CONFIG_CFG_STORE
- See Also:
- Constant Field Values
-
DEFAULT_DIGRAPH_MBEAN
static final boolean DEFAULT_DIGRAPH_MBEAN
- See Also:
- Constant Field Values
-
-
Method Detail
-
validateRepository
void validateRepository(URI uri) throws Exception
Validate repository contents.- Parameters:
uri
- Repository uri.- Throws:
Exception
- When validation fails.
-
isRepositoryUriBlacklisted
boolean isRepositoryUriBlacklisted(URI uri)
-
repositoryProvidedFeatures
Feature[] repositoryProvidedFeatures(URI uri) throws Exception
- Throws:
Exception
-
removeRepository
void removeRepository(URI uri, boolean uninstall) throws Exception
- Throws:
Exception
-
listRequiredRepositories
Repository[] listRequiredRepositories() throws Exception
- Throws:
Exception
-
listRepositories
Repository[] listRepositories() throws Exception
- Throws:
Exception
-
getRepository
Repository getRepository(String repoName) throws Exception
- Throws:
Exception
-
getRepository
Repository getRepository(URI uri) throws Exception
- Throws:
Exception
-
setResolutionOutputFile
void setResolutionOutputFile(String outputFile)
-
installFeature
void installFeature(String name, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
installFeature
void installFeature(String name, String version, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
installFeature
void installFeature(Feature f, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
installFeatures
void installFeatures(Set<String> features, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
installFeatures
void installFeatures(Set<String> features, String region, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
addRequirements
void addRequirements(Map<String,Set<String>> requirements, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
uninstallFeature
void uninstallFeature(String name, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
uninstallFeature
void uninstallFeature(String name, String version, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
uninstallFeature
void uninstallFeature(String name, String version) throws Exception
- Throws:
Exception
-
uninstallFeatures
void uninstallFeatures(Set<String> features, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
uninstallFeatures
void uninstallFeatures(Set<String> features, String region, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
removeRequirements
void removeRequirements(Map<String,Set<String>> requirements, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
updateFeaturesState
void updateFeaturesState(Map<String,Map<String,FeatureState>> stateChanges, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
updateReposAndRequirements
void updateReposAndRequirements(Set<URI> repos, Map<String,Set<String>> requirements, EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
createRepository
Repository createRepository(URI uri) throws Exception
- Throws:
Exception
-
isRequired
boolean isRequired(Feature f)
-
isInstalled
boolean isInstalled(Feature f)
-
getRepositoryNames
String[] getRepositoryNames()
-
registerListener
void registerListener(FeaturesListener listener)
-
unregisterListener
void unregisterListener(FeaturesListener listener)
-
registerListener
void registerListener(DeploymentListener listener)
-
unregisterListener
void unregisterListener(DeploymentListener listener)
-
getState
FeatureState getState(String featureId)
-
refreshFeatures
void refreshFeatures(EnumSet<FeaturesService.Option> options) throws Exception
- Throws:
Exception
-
-