@Test public void testPuppetPlugin_withInit_update() throws Exception { Assume.assumeTrue( isLinuxSystem()); copyResources( "/with-init" ); Map<String,String> variables = new HashMap<> (); variables.put( "ip", "127.0.0.1" ); this.plugin.update( this.inst, new Import( "/some/path", "component1", variables ), InstanceStatus.DEPLOYED_STARTED ); checkGeneratedFiles( "WithInit", "" ); }
@Override public void update(Instance instance, Import importChanged, InstanceStatus statusChanged) throws PluginException { this.logger.fine( this.agentId + " is updating instance " + instance.getName()); File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance ); try { callPuppetScript( instance, "update", PuppetState.UNDEF, importChanged, (statusChanged == InstanceStatus.DEPLOYED_STARTED), instanceDirectory ); } catch( Exception e ) { throw new PluginException( e ); } }
PluginPuppet implements PluginInterface { @Override public void update(Instance instance, Import importChanged, InstanceStatus statusChanged) throws PluginException { this.logger.fine( this.agentId + " is updating instance " + instance.getName()); File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance ); try { callPuppetScript( instance, "update", PuppetState.UNDEF, importChanged, (statusChanged == InstanceStatus.DEPLOYED_STARTED), instanceDirectory ); } catch( Exception e ) { throw new PluginException( e ); } } }
PluginPuppet implements PluginInterface { @Override public void update(Instance instance, Import importChanged, InstanceStatus statusChanged) throws PluginException { this.logger.fine( this.agentId + " is updating instance " + instance.getName()); File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance ); try { callPuppetScript( instance, "update", PuppetState.UNDEF, importChanged, (statusChanged == InstanceStatus.DEPLOYED_STARTED), instanceDirectory ); } catch( Exception e ) { throw new PluginException( e ); } }  }
PluginPuppet implements PluginInterface { @Override public void update(Instance instance, Import importChanged, InstanceStatus statusChanged) throws PluginException { this.logger.fine( this.agentId + " is updating instance " + instance.getName()); File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance ); try { callPuppetScript( instance, "update", PuppetState.UNDEF, importChanged, (statusChanged == InstanceStatus.DEPLOYED_STARTED), instanceDirectory ); } catch( Exception e ) { throw new PluginException( e ); } }  @Override String getPluginName(); @Override void setNames( String applicationName, String scopedInstancePath ); @Override void initialize( Instance instance ); @Override void deploy( Instance instance ); @Override void start( Instance instance ); @Override void update(Instance instance, Import importChanged, InstanceStatus statusChanged); @Override void stop( Instance instance ); @Override void undeploy( Instance instance ); }
PluginPuppet implements PluginInterface { @Override public void update(Instance instance, Import importChanged, InstanceStatus statusChanged) throws PluginException { this.logger.fine( this.agentId + " is updating instance " + instance.getName()); File instanceDirectory = InstanceHelpers.findInstanceDirectoryOnAgent( instance ); try { callPuppetScript( instance, "update", PuppetState.UNDEF, importChanged, (statusChanged == InstanceStatus.DEPLOYED_STARTED), instanceDirectory ); } catch( Exception e ) { throw new PluginException( e ); } }  @Override String getPluginName(); @Override void setNames( String applicationName, String scopedInstancePath ); @Override void initialize( Instance instance ); @Override void deploy( Instance instance ); @Override void start( Instance instance ); @Override void update(Instance instance, Import importChanged, InstanceStatus statusChanged); @Override void stop( Instance instance ); @Override void undeploy( Instance instance ); static final String PLUGIN_NAME; }