Package org.apache.karaf.features

Examples of org.apache.karaf.features.FeaturesService.addRepository()


                try {
                    Kar kar = new Kar(file.toURI());
                    kar.extract(new File(system.getPath()), new File(workDirectory));
                    for (URI repoUri : kar.getFeatureRepos()) {
                        featuresService.removeRepository(repoUri);
                        featuresService.addRepository(repoUri);
                    }
                } catch (Exception e) {
                    throw new RuntimeException("Could not install kar: " + artifact.toString() + "\n", e);
                    //buf.append("Could not install kar: ").append(artifact.toString()).append("\n");
                    //buf.append(e.getMessage()).append("\n\n");
View Full Code Here


                        }
                    }

                }
                try {
                    featuresService.addRepository(URI.create(uri));
                } catch (Exception e) {
                    buf.append("Could not install feature: ").append(artifact.toString()).append("\n");
                    buf.append(e.getMessage()).append("\n\n");
                }
            }
View Full Code Here

                try {
                    Kar kar = new Kar(file.toURI());
                    kar.extract(new File(system.getPath()), new File(workDirectory));
                    for (URI repoUri : kar.getFeatureRepos()) {
                        featuresService.removeRepository(repoUri);
                        featuresService.addRepository(repoUri);
                    }
                } catch (Exception e) {
                    throw new RuntimeException("Could not install kar: " + artifact.toString() + "\n", e);
                    //buf.append("Could not install kar: ").append(artifact.toString()).append("\n");
                    //buf.append(e.getMessage()).append("\n\n");
View Full Code Here

                        }
                    }

                }
                try {
                    featuresService.addRepository(URI.create(uri));
                } catch (Exception e) {
                    buf.append("Could not install feature: ").append(artifact.toString()).append("\n");
                    buf.append(e.getMessage()).append("\n\n");
                }
            }
View Full Code Here

                try {
                    Kar kar = new Kar(file.toURI());
                    kar.extract(new File(system.getPath()), new File(workDirectory));
                    for (URI repoUri : kar.getFeatureRepos()) {
                        featuresService.removeRepository(repoUri);
                        featuresService.addRepository(repoUri);
                    }
                } catch (Exception e) {
                    throw new RuntimeException("Could not install kar: " + artifact.toString() + "\n", e);
                    //buf.append("Could not install kar: ").append(artifact.toString()).append("\n");
                    //buf.append(e.getMessage()).append("\n\n");
View Full Code Here

                        }
                    }

                }
                try {
                    featuresService.addRepository(URI.create(uri));
                } catch (Exception e) {
                    buf.append("Could not install feature: ").append(artifact.toString()).append("\n");
                    buf.append(e.getMessage()).append("\n\n");
                }
            }
View Full Code Here

        try {
            final FeaturesService service = (FeaturesService) bundleContext.getService(reference);

            for (URI uri : info.getFeatureURLs()) {
                try {
                    service.addRepository(uri);
                } catch (Exception e) {
                    LOG.warn("Unable to add feature repository URL {} - FAB {} may not get installed properly", uri, url);
                }
            }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.