Commit 3a546c69 authored by Gianluca Filippone's avatar Gianluca Filippone
Browse files

Fixed console errors while executing actions on choreographies

parent e4dc153c
......@@ -181,23 +181,115 @@ public class ChoreographyResource implements ChoreographyApi {
}
@Override
public Response start(final String choreography_id) {
return null;
public Response start(final String choreographyId) {
String choreographyName = DEPLOYED.get(choreographyId);
return Response.accepted().
entity(new TaskSummary(
UUID.randomUUID().toString(),
"Start Task for " + choreographyId,
null,
choreographyId,
choreographyName,
null,
new Date().getTime(),
new Date().getTime(),
new Date().getTime(),
"SUBMITTED",
null,
false,
false,
null,
null,
null,
null,
null,
null,
null)).
build();
}
@Override
public Response stop(final String choreographyId) {
return null;
String choreographyName = DEPLOYED.get(choreographyId);
return Response.accepted().
entity(new TaskSummary(
UUID.randomUUID().toString(),
"Stop Task for " + choreographyId,
null,
choreographyId,
choreographyName,
null,
new Date().getTime(),
new Date().getTime(),
new Date().getTime(),
"SUBMITTED",
null,
false,
false,
null,
null,
null,
null,
null,
null,
null)).
build();
}
@Override
public Response pause(final String choreography_id) {
return null;
public Response pause(final String choreographyId) {
String choreographyName = DEPLOYED.get(choreographyId);
return Response.accepted().
entity(new TaskSummary(
UUID.randomUUID().toString(),
"Pause Task for " + choreographyId,
null,
choreographyId,
choreographyName,
null,
new Date().getTime(),
new Date().getTime(),
new Date().getTime(),
"SUBMITTED",
null,
false,
false,
null,
null,
null,
null,
null,
null,
null)).
build();
}
@Override
public Response resize(final String choreographyId, final Integer newSize) {
return null;
String choreographyName = DEPLOYED.get(choreographyId);
return Response.accepted().
entity(new TaskSummary(
UUID.randomUUID().toString(),
"Resize Task for " + choreographyId,
null,
choreographyId,
choreographyName,
null,
new Date().getTime(),
new Date().getTime(),
new Date().getTime(),
"SUBMITTED",
null,
false,
false,
null,
null,
null,
null,
null,
null,
null)).
build();
}
@Override
......
......@@ -150,7 +150,7 @@ public class ChoreographyDirectoryPanel extends GroupDirectoryPanel {
SyncopeConsoleSession.get().info(getString(Constants.OPERATION_SUCCEEDED));
target.add(container);
} catch (SyncopeClientException e) {
LOG.error("While sopping choreography {}", model.getObject().getKey(), e);
LOG.error("While stopping choreography {}", model.getObject().getKey(), e);
SyncopeConsoleSession.get().error(StringUtils.isBlank(e.getMessage())
? e.getClass().getName() : e.getMessage());
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment