Skip to content

Commit

Permalink
Upgrade to Adyen Java library v25.1.0 (#231)
Browse files Browse the repository at this point in the history
* Upgrade to Adyen Java library v25.1.0

* Log exception stack

* set payment method for donation
  • Loading branch information
gcatanese authored Sep 13, 2024
1 parent 723951d commit d1fee76
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 10 deletions.
2 changes: 1 addition & 1 deletion authorisation-adjustment-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion checkout-example-advanced/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion checkout-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion giftcard-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion giving-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,10 @@ public ResponseEntity<DonationPaymentResponse> donations(@RequestBody Amount bod

donationRequest.amount(body);
donationRequest.reference(UUID.randomUUID().toString());
donationRequest.setPaymentMethod(new DonationPaymentMethod(new CardDonations()));
// set payment method for donation
CardDonations cardDetails = new CardDonations().type(CardDonations.TypeEnum.SCHEME);
donationRequest.paymentMethod(new DonationPaymentMethod(cardDetails));
// set donaton token
donationRequest.setDonationToken(donationToken);
donationRequest.donationOriginalPspReference(pspReference);
donationRequest.setDonationAccount(this.applicationProperty.getDonationMerchantAccount());
Expand All @@ -81,7 +84,7 @@ public ResponseEntity<DonationPaymentResponse> donations(@RequestBody Amount bod
log.warn(e.getMessage());
return ResponseEntity.notFound().build();
} catch (Exception e) {
log.error(e.getMessage());
log.error(e.getMessage(), e);
return ResponseEntity.status(500).build();
}
}
Expand Down
2 changes: 1 addition & 1 deletion in-person-payments-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion paybylink-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down
2 changes: 1 addition & 1 deletion subscription-example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect'
implementation 'com.adyen:adyen-java-api-library:24.0.0'
implementation 'com.adyen:adyen-java-api-library:25.1.0'

developmentOnly 'org.springframework.boot:spring-boot-devtools'

Expand Down

0 comments on commit d1fee76

Please sign in to comment.