Skip to content

Commit 10c2f79

Browse files
committed
removed the handleApplicationName method signature from StepFlowHandler
1 parent 06091ce commit 10c2f79

File tree

3 files changed

+4
-11
lines changed

3 files changed

+4
-11
lines changed

multiapps-controller-process/src/main/java/org/cloudfoundry/multiapps/controller/process/Messages.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,6 @@ public class Messages {
161161
public static final String ERROR_MONITORING_OPERATIONS_OVER_SERVICES = "Error monitoring operations over services";
162162
public static final String ERROR_DELETING_REMAINING_FILE_PARTS = "Error deleting remaining file parts";
163163
public static final String ERROR_DETECTING_APPLICATIONS_TO_RENAME = "Error detecting applications to rename";
164-
public static final String ERROR_RENAMING_NEW_APPLICATIONS = "Error renaming new applications";
165164
public static final String ERROR_MONITORING_CREATION_OR_UPDATE_OF_SERVICES = "Error monitoring creation or update of services";
166165
public static final String ERROR_MONITORING_DELETION_OF_SERVICES = "Error monitoring deletion of services";
167166
public static final String SERVICE_IS_ALREADY_DELETED = "Service \"{0}\" is already deleted";

multiapps-controller-process/src/main/java/org/cloudfoundry/multiapps/controller/process/steps/CreateOrUpdateAppStep.java

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ protected StepPhase executeStep(ProcessContext context) throws FileStorageExcept
8181
flowHandler.injectServiceKeysCredentialsInAppEnv();
8282
flowHandler.handleApplicationAttributes();
8383
flowHandler.handleApplicationServices();
84-
flowHandler.handleApplicationName();
8584
flowHandler.printStepEndMessage();
8685

8786
return StepPhase.DONE;
@@ -157,8 +156,6 @@ private Map<String, String> buildServiceKeysCredentials(CloudControllerClient cl
157156

158157
public abstract void handleApplicationAttributes();
159158

160-
public abstract void handleApplicationName();
161-
162159
public abstract void handleApplicationServices();
163160

164161
public abstract void printStepEndMessage();
@@ -199,10 +196,6 @@ public void handleApplicationServices() {
199196
context.setVariable(Variables.SERVICES_TO_UNBIND_BIND, app.getServices());
200197
}
201198

202-
@Override
203-
public void handleApplicationName() {
204-
}
205-
206199
@Override
207200
public void printStepStartMessage() {
208201
getStepLogger().info(Messages.CREATING_APP_FROM_MODULE, app.getName(), app.getModuleName());
@@ -247,7 +240,9 @@ public void handleApplicationAttributes() {
247240

248241
reportApplicationUpdateStatus(app, arePropertiesChanged);
249242
context.setVariable(Variables.VCAP_APP_PROPERTIES_CHANGED, arePropertiesChanged);
243+
250244
updateApplicationEnvironment();
245+
updateApplicationName();
251246
}
252247

253248
private void updateApplicationEnvironment() {
@@ -295,8 +290,7 @@ private UpdateStrategy getEnvUpdateStrategy() {
295290
.shouldKeepExistingEnv() ? UpdateStrategy.MERGE : UpdateStrategy.REPLACE;
296291
}
297292

298-
@Override
299-
public void handleApplicationName() {
293+
public void updateApplicationName() {
300294
boolean processIsBlueGreenWithIdleSuffix = StepsUtil.getAppSuffixDeterminer(context)
301295
.shouldAppendIdleSuffix();
302296
if (!processIsBlueGreenWithIdleSuffix) {

multiapps-controller-process/src/main/java/org/cloudfoundry/multiapps/controller/process/steps/StepsUtil.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ static ApplicationCloudModelBuilder getApplicationCloudModelBuilder(ProcessConte
216216
shouldApplyIncrementalInstancesUpdate(context));
217217
}
218218

219-
static AppSuffixDeterminer getAppSuffixDeterminer(ProcessContext context) {
219+
public static AppSuffixDeterminer getAppSuffixDeterminer(ProcessContext context) {
220220
boolean keepOriginalNamesAfterDeploy = context.getVariable(Variables.KEEP_ORIGINAL_APP_NAMES_AFTER_DEPLOY);
221221
boolean isAfterResumePhase = context.getVariable(Variables.PHASE) == Phase.AFTER_RESUME;
222222
return new AppSuffixDeterminer(keepOriginalNamesAfterDeploy, isAfterResumePhase);

0 commit comments

Comments
 (0)