Skip to content

Commit

Permalink
Merge pull request #24 from aws-samples/unicorngymissues
Browse files Browse the repository at this point in the history
fix: Bug Fixes identifed with new cookiecutters and content
  • Loading branch information
sliedig committed Aug 4, 2023
2 parents b1ce7a1 + 5968db8 commit c205f1b
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 59 deletions.
10 changes: 6 additions & 4 deletions unicorn_contracts/ContractsFunction/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,15 @@
<artifactId>aws-lambda-java-events</artifactId>
<version>3.11.0</version>
</dependency>



<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.13.4.2</version>
<version>2.15.2</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>2.15.2</version>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ private String publishEvent(Contract contract, String EVENT_BUS, String SERVICE_

@Tracing
private void createContract(Contract contract) throws JsonProcessingException {
helper.saveContractDDB(contract);
helper.createContract(contract);
}

public ContractHelper getHelper() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ public String sendEvent(String propertyId, String contractId, ContractStatusEnum
return event_string;
}

public void saveContractDDB(Contract contract) {
public void createContract(Contract contract) {

DynamoDbAsyncTable<Contract> contractTable = enhancedClient.table(this.tableName,
TableSchema.fromBean(Contract.class));
Expand Down
72 changes: 19 additions & 53 deletions unicorn_properties/PropertyFunctions/pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>property</groupId>
<artifactId>PropertyService</artifactId>
Expand All @@ -10,18 +10,6 @@
<maven.compiler.source>17</maven.compiler.source>
<maven.compiler.target>17</maven.compiler.target>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>bom</artifactId>
<version>2.17.211</version>
<type>pom</type>
<scope>import</scope>
</dependency>

</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
Expand All @@ -39,29 +27,39 @@
<artifactId>powertools-metrics</artifactId>
<version>1.12.2</version>
</dependency>
<!-- https://mvnrepository.com/artifact/software.amazon.awssdk/lambda -->

<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-lambda-java-core</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-lambda-java-events</artifactId>
<version>3.11.0</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>bom</artifactId>
<version>2.17.211</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>lambda</artifactId>
<version>2.17.211</version>
</dependency>

<!-- https://mvnrepository.com/artifact/software.amazon.awssdk/dynamodb -->
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>dynamodb</artifactId>
<version>2.17.211</version>
</dependency>

<!-- https://mvnrepository.com/artifact/software.amazon.awssdk/sfn -->
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>sfn</artifactId>
<version>2.17.211</version>
</dependency>


<!-- https://mvnrepository.com/artifact/software.amazon.awssdk/dynamodb -->
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>eventbridge</artifactId>
Expand Down Expand Up @@ -124,7 +122,6 @@
</dependencies>



<build>
<plugins>
<plugin>
Expand Down Expand Up @@ -152,37 +149,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>dev.aspectj</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
<version>1.13.1</version>
<configuration>
<source>17</source>
<target>17</target>
<complianceLevel>17</complianceLevel>
<aspectLibraries>
<aspectLibrary>
<groupId>software.amazon.lambda</groupId>
<artifactId>powertools-tracing</artifactId>
</aspectLibrary>
<aspectLibrary>
<groupId>software.amazon.lambda</groupId>
<artifactId>powertools-logging</artifactId>
</aspectLibrary>
<aspectLibrary>
<groupId>software.amazon.lambda</groupId>
<artifactId>powertools-metrics</artifactId>
</aspectLibrary>
</aspectLibraries>
</configuration>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

0 comments on commit c205f1b

Please sign in to comment.