summaryrefslogtreecommitdiffstats
path: root/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/aws/CloudEvent.java
blob: 59fd84aec74f2a8ae77dc1ba6a8561ce6e5f5259 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package com.yahoo.vespa.hosted.controller.api.integration.aws;

import java.util.Date;
import java.util.Optional;
import java.util.Set;

public final class CloudEvent {
    public final String instanceEventId;
    public final String code;
    public final String description;
    public final Optional<Date> notBefore;
    public final Optional<Date> notBeforeDeadline;
    public final Optional<Date> notAfter;

    public String awsRegionName;
    public Set<String> affectedHostnames;

    public CloudEvent(String instanceEventId, String code, String description, Date notAfter, Date notBefore, Date notBeforeDeadline,
                      String awsRegionName, Set<String> affectedHostnames) {
        this.instanceEventId = instanceEventId;
        this.code = code;
        this.description = description;
        this.notBefore = Optional.ofNullable(notBefore);
        this.notBeforeDeadline = Optional.ofNullable(notBeforeDeadline);
        this.notAfter = Optional.ofNullable(notAfter);

        this.awsRegionName = awsRegionName;
        this.affectedHostnames = affectedHostnames;
    }
}