diff --git a/parametermanager/pom.xml b/parametermanager/pom.xml index 33cd5ffdc52..2da84f3a7e0 100644 --- a/parametermanager/pom.xml +++ b/parametermanager/pom.xml @@ -61,13 +61,6 @@ protobuf-java-util - - org.projectlombok - lombok - 1.18.30 - provided - - junit @@ -107,13 +100,6 @@ 11 11 - - - org.projectlombok - lombok - 1.18.30 - - diff --git a/run/idp-sql/pom.xml b/run/idp-sql/pom.xml index d65e9e30836..ace3adc10a5 100644 --- a/run/idp-sql/pom.xml +++ b/run/idp-sql/pom.xml @@ -47,7 +47,7 @@ limitations under the License. com.google.cloud spring-cloud-gcp-dependencies - 3.7.7 + 3.9.18 pom import @@ -108,12 +108,8 @@ limitations under the License. - org.projectlombok - lombok - - - com.squareup.okhttp3 - okhttp + com.squareup.okhttp3 + okhttp com.google.gms diff --git a/run/idp-sql/src/main/java/com/example/cloudrun/Vote.java b/run/idp-sql/src/main/java/com/example/cloudrun/Vote.java index 5c4af49c35d..8f3297eb792 100644 --- a/run/idp-sql/src/main/java/com/example/cloudrun/Vote.java +++ b/run/idp-sql/src/main/java/com/example/cloudrun/Vote.java @@ -17,16 +17,62 @@ package com.example.cloudrun; import com.google.gson.JsonObject; -import edu.umd.cs.findbugs.annotations.NonNull; import java.sql.Timestamp; -import lombok.Data; +import java.util.Objects; -/** Lombok notation to generate methods: toString, equals, hashCode, getters, and setters */ -@Data public class Vote { - @NonNull private String uid; - @NonNull private String candidate; - @NonNull private Timestamp timeCast; + private String uid; + private String candidate; + private Timestamp timeCast; + + public Vote(String uid, String candidate, Timestamp timeCast) { + this.uid = Objects.requireNonNull(uid); + this.candidate = Objects.requireNonNull(candidate); + this.timeCast = Objects.requireNonNull(timeCast); + } + + public String getUid() { + return uid; + } + + public void setUid(String uid) { + this.uid = Objects.requireNonNull(uid); + } + + public String getCandidate() { + return candidate; + } + + public void setCandidate(String candidate) { + this.candidate = Objects.requireNonNull(candidate); + } + + public Timestamp getTimeCast() { + return timeCast; + } + + public void setTimeCast(Timestamp timeCast) { + this.timeCast = Objects.requireNonNull(timeCast); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + Vote vote = (Vote) o; + return Objects.equals(uid, vote.uid) + && Objects.equals(candidate, vote.candidate) + && Objects.equals(timeCast, vote.timeCast); + } + + @Override + public int hashCode() { + return Objects.hash(uid, candidate, timeCast); + } @Override public String toString() {