Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions parametermanager/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,6 @@
<artifactId>protobuf-java-util</artifactId>
</dependency>

<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.30</version>
<scope>provided</scope>
</dependency>

<!-- test dependencies -->
<dependency>
<groupId>junit</groupId>
Expand Down Expand Up @@ -107,13 +100,6 @@
<configuration>
<source>11</source> <!-- depending on your project -->
<target>11</target> <!-- depending on your project -->
<annotationProcessorPaths>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.30</version>
</path>
</annotationProcessorPaths>
</configuration>
</plugin>
</plugins>
Expand Down
10 changes: 3 additions & 7 deletions run/idp-sql/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ limitations under the License.
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>spring-cloud-gcp-dependencies</artifactId>
<version>3.7.7</version>
<version>3.9.18</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -108,12 +108,8 @@ limitations under the License.
</exclusions>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>
<dependency>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId>
<groupId>com.squareup.okhttp3</groupId>
<artifactId>okhttp</artifactId>
</dependency>
Comment thread
XrossFox marked this conversation as resolved.
Resolved
<dependency>
<groupId>com.google.gms</groupId>
Expand Down
60 changes: 53 additions & 7 deletions run/idp-sql/src/main/java/com/example/cloudrun/Vote.java
Original file line number Diff line number Diff line change
Expand Up @@ -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() {
Expand Down
Loading