/** * Returns the ZooKeeper client or throwns an exception if its not configured properly */ protected CuratorFramework getCurator() { CuratorFramework curator = fabricService.adapt(CuratorFramework.class); notNull(curator, "curator"); return curator; }
public void start() { missingChecksums.clear(); Objects.notNull(fabricService, "fabricService"); fabricService.get().trackConfiguration(fabricConfigureChangeRunnable); // start the watch thread if (running.compareAndSet(false, true)) { if (watchURLs.size() > 0) { Thread thread = new Thread(this); thread.start(); } } }
@Activate void activate() throws Exception { Objects.notNull(fabricService, "fabricService"); Objects.notNull(profileService, "profileService"); mqService = createMQService(fabricService, runtimeProperties); if (mbeanServer != null) { StandardMBean mbean = new StandardMBean(this, MQManagerMXBean.class); JMXUtils.registerMBean(mbean, mbeanServer, OBJECT_NAME); } }
@Activate void activate(BundleContext bundleContext) throws Exception { this.bundleContext = bundleContext; bundleUtils = new BundleUtils(bundleContext); Objects.notNull(metaTypeService, "metaTypeService"); Objects.notNull(bundleContext, "bundleContext"); if (mbeanServer != null) { StandardMBean mbean = new StandardMBean(this, MetaTypeFacadeMXBean.class); JMXUtils.registerMBean(mbean, mbeanServer, OBJECT_NAME); } }
@Override public DeployResults deployProjectJson(String requirementsJson) throws Exception { ProjectRequirements requirements = DtoHelper.getMapper().readValue(requirementsJson, ProjectRequirements.class); Objects.notNull(requirements, "ProjectRequirements"); return deployProject(requirements); }
Objects.notNull(containerProvider, "No ContainerProvider available for scheme: " + containerProviderScheme); if (!containerProvider.isValidProvider()) { throw new IllegalArgumentException("ContainerProvider for scheme: " + containerProviderScheme + " is not valid in current environment");