-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
107 changed files
with
3,091 additions
and
970 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
springBoot = 2.6.6 | ||
dependencyManagement = 1.0.11.RELEASE | ||
projectVersion = 4.11.0 | ||
projectVersion = 4.12.0 | ||
paypalHyperwalletDockerRepository = hyperwallet-mirakl-connector | ||
org.gradle.jvmargs = -XX:PermSize=1024M -XX:MaxPermSize=1024M |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
infrastructure/src/main/java/com/paypal/infrastructure/batchjob/AbstractExtractBatchJob.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.paypal.infrastructure.batchjob; | ||
|
||
/** | ||
* Abstract class for all jobs of type Extract | ||
*/ | ||
public abstract class AbstractExtractBatchJob<C extends BatchJobContext, T extends BatchJobItem<?>> | ||
extends AbstractBatchJob<C, T> { | ||
|
||
@Override | ||
public BatchJobType getType() { | ||
return BatchJobType.EXTRACT; | ||
} | ||
|
||
} |
14 changes: 14 additions & 0 deletions
14
infrastructure/src/main/java/com/paypal/infrastructure/batchjob/AbstractRetryBatchJob.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.paypal.infrastructure.batchjob; | ||
|
||
/** | ||
* Abstract class for all jobs of type Retry | ||
*/ | ||
public abstract class AbstractRetryBatchJob<C extends BatchJobContext, T extends BatchJobItem<?>> | ||
extends AbstractBatchJob<C, T> { | ||
|
||
@Override | ||
public BatchJobType getType() { | ||
return BatchJobType.RETRY; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
infrastructure/src/main/java/com/paypal/infrastructure/batchjob/BatchJobItemEnricher.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package com.paypal.infrastructure.batchjob; | ||
|
||
/** | ||
* BatchJobs will use classes implementing this interface for enriching items before | ||
* processing them. | ||
* | ||
* @param <C> the job context type. | ||
* @param <T> the item type. | ||
*/ | ||
public interface BatchJobItemEnricher<C extends BatchJobContext, T extends BatchJobItem<?>> { | ||
|
||
/** | ||
* Enrichs the information of an item. | ||
* @param ctx the batch job context. | ||
* @param jobItem the item to be processed. | ||
* @return the enriched item. | ||
*/ | ||
T enrichItem(C ctx, T jobItem); | ||
|
||
} |
20 changes: 20 additions & 0 deletions
20
...ucture/src/main/java/com/paypal/infrastructure/batchjob/BatchJobItemValidationResult.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package com.paypal.infrastructure.batchjob; | ||
|
||
import lombok.Builder; | ||
import lombok.Value; | ||
|
||
import java.util.Optional; | ||
|
||
/** | ||
* This class holds the result of a batch job item validation. | ||
*/ | ||
@Value | ||
@Builder | ||
public class BatchJobItemValidationResult { | ||
|
||
private BatchJobItemValidationStatus status; | ||
|
||
@Builder.Default | ||
private Optional<String> reason = Optional.empty(); | ||
|
||
} |
Oops, something went wrong.