use of org.onap.appc.client.lcm.model.Flags in project so by onap.
the class ApplicationControllerClient method createRequestFlags.
public Flags createRequestFlags() {
Flags flags = new Flags();
flags.setTtl(6000);
return flags;
}
use of org.onap.appc.client.lcm.model.Flags in project so by onap.
the class ApplicationControllerClient method buildCommonHeader.
protected CommonHeader buildCommonHeader(String requestId, String requestorId) {
CommonHeader commonHeader = new CommonHeader();
commonHeader.setApiVer(API_VER);
commonHeader.setOriginatorId(ORIGINATOR_ID);
commonHeader.setRequestId(requestId == null ? UUID.randomUUID().toString() : requestId);
commonHeader.setSubRequestId(UUID.randomUUID().toString());
Flags flags = new Flags();
String flagsMode = "NORMAL";
Mode mode = Mode.valueOf(flagsMode);
flags.setMode(mode);
String flagsForce = "FALSE";
Force force = Force.valueOf(flagsForce);
flags.setForce(force);
flags.setTtl(FLAGS_TTL);
commonHeader.setFlags(flags);
Instant timestamp = Instant.now();
ZULU zulu = new ZULU(timestamp.toString());
commonHeader.setTimestamp(zulu);
return commonHeader;
}
use of org.onap.appc.client.lcm.model.Flags in project so by onap.
the class ApplicationControllerClient method createRequestFlags.
public Flags createRequestFlags() {
Flags flags = new Flags();
flags.setTtl(6000);
return flags;
}
use of org.onap.appc.client.lcm.model.Flags in project so by onap.
the class ApplicationControllerClient method buildCommonHeader.
private CommonHeader buildCommonHeader(String requestId) {
CommonHeader commonHeader = new CommonHeader();
commonHeader.setApiVer(API_VER);
commonHeader.setOriginatorId(ORIGINATOR_ID);
commonHeader.setRequestId(requestId == null ? UUID.randomUUID().toString() : requestId);
commonHeader.setSubRequestId(UUID.randomUUID().toString());
Flags flags = new Flags();
String flagsMode = "NORMAL";
Mode mode = Mode.valueOf(flagsMode);
flags.setMode(mode);
String flagsForce = "FALSE";
Force force = Force.valueOf(flagsForce);
flags.setForce(force);
flags.setTtl(FLAGS_TTL);
commonHeader.setFlags(flags);
ZULU zulu = new ZULU(generateCurrentTimestamp(this.controllerType));
commonHeader.setTimestamp(zulu);
return commonHeader;
}