/** * Creates a new instance. * The created service will automatically {@link Service#configure(ServiceProfile) configured} * by using this profile. * @param variables the variable resolver * @return the created instance. * @throws InterruptedException if interrupted in configuring the target service * @throws IOException if failed to create or configure the service * @deprecated use {@link #newInstance()} instead */ @Deprecated public T newInstance(VariableResolver variables) throws InterruptedException, IOException { if (variables == null) { throw new IllegalArgumentException("variables must not be null"); //$NON-NLS-1$ } return newInstance(); }
subPrefix), e); ExecutionScriptHandler<T> subInstance = subProfile.newInstance(); results.put(key, subInstance);
ExecutionMonitorProvider monitors = profile.getMonitors().newInstance(); ExecutionLockProvider locks = profile.getLocks().newInstance(); JobScheduler scheduler = profile.getScheduler().newInstance(); HadoopScriptHandler hadoopHandler = profile.getHadoopHandler().newInstance(); for (Map.Entry<String, ServiceProfile<CommandScriptHandler>> entry : profile.getCommandHandlers().entrySet()) { commandHandlers.put(entry.getKey(), entry.getValue().newInstance());