Skip to content

Commit

Permalink
Amazon Pay API SDK (Java) 2.3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
Shangamesh T committed Jun 22, 2021
1 parent 6878655 commit ad07cb6
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#### Version 2.3.3 - June 2021
* Added API Retry mechanism for error codes 502 & 504
* Upgraded Bouncy Castle to avoid using Vulnerable version

#### Version 2.3.2 - May 2021
* Enabled support for environment specific keys (i.e Public key & Private key). The changes are fully backwards-compatible, where merchants can also use non environment specific keys

Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ To use the SDK in a Maven project, add a <dependency> reference in your pom.xml
<dependency>
<groupId>software.amazon.pay</groupId>
<artifactId>amazon-pay-api-sdk-java</artifactId>
<version>2.3.2</version>
<version>2.3.3</version>
</dependency>
</dependencies>
```

To use the SDK in a Gradle project, add the following line to your build.gradle file::

```
implementation 'software.amazon.pay:amazon-pay-api-sdk-java:2.3.2'
implementation 'software.amazon.pay:amazon-pay-api-sdk-java:2.3.3'
```

For legacy projects, you can just grab the binary [jar file](https://github.com/amzn/amazon-pay-api-sdk-java/releases) from the GitHub Releases page.
Expand All @@ -47,7 +47,7 @@ In Linux or macOS this can be done using openssl commands:

```
openssl genrsa -out private.txt 2048
openssl rsa -in private.txt -pubout > public.txt
openssl rsa -in private.txt -pubout > public.pub
```

The first command above generates a private key and the second line uses the private key to generate a public key.
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<groupId>software.amazon.pay</groupId>
<artifactId>amazon-pay-api-sdk-java</artifactId>
<packaging>jar</packaging>
<version>2.3.2</version>
<version>2.3.3</version>
<dependencies>
<!-- https://mvnrepository.com/artifact/net.sf.json-lib/json-lib -->
<dependency>
Expand All @@ -18,7 +18,7 @@
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<version>1.65</version>
<version>1.67</version>
</dependency>
<!-- https://mvnrepository.com/artifact/commons-beanutils/commons-beanutils -->
<dependency>
Expand Down
4 changes: 3 additions & 1 deletion src/com/amazon/pay/api/ServiceConstants.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class ServiceConstants {
public static final Map<Region, String> endpointMappings;
public static final Map<String, Integer> serviceErrors;

public static final String APPLICATION_LIBRARY_VERSION = "2.3.2";
public static final String APPLICATION_LIBRARY_VERSION = "2.3.3";
public static final String GITHUB_SDK_NAME = "amazon-pay-api-sdk-java";
public static final String AMAZON_PAY_API_VERSION = "v2";

Expand Down Expand Up @@ -72,6 +72,8 @@ public class ServiceConstants {
serviceErrorsMap.put("Internal Server Error", HttpURLConnection.HTTP_INTERNAL_ERROR);
serviceErrorsMap.put("Service Unavailable", HttpURLConnection.HTTP_UNAVAILABLE);
serviceErrorsMap.put("Too Many Requests", 429);
serviceErrorsMap.put("HTTP Bad Gateway", HttpURLConnection.HTTP_BAD_GATEWAY);
serviceErrorsMap.put("HTTP Gateway Timeout", HttpURLConnection.HTTP_GATEWAY_TIMEOUT);
serviceErrors = Collections.unmodifiableMap(serviceErrorsMap);
}
public static final String X_AMZ_PAY_REQUEST_ID = "X-Amz-Pay-Request-Id";
Expand Down

0 comments on commit ad07cb6

Please sign in to comment.