generated from pagopa/pagopa-functions-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #97 from pagopa/PRDP-261-update-retry-function
[PRDP-261] Updated RetryReviewedPoisonMessages function
- Loading branch information
Showing
12 changed files
with
348 additions
and
99 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
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
18 changes: 17 additions & 1 deletion
18
src/main/java/it/gov/pagopa/receipt/pdf/generator/client/ReceiptCosmosClient.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 |
---|---|---|
@@ -1,9 +1,25 @@ | ||
package it.gov.pagopa.receipt.pdf.generator.client; | ||
|
||
import com.azure.cosmos.models.CosmosItemResponse; | ||
import it.gov.pagopa.receipt.pdf.generator.entity.receipt.Receipt; | ||
import it.gov.pagopa.receipt.pdf.generator.exception.ReceiptNotFoundException; | ||
|
||
public interface ReceiptCosmosClient { | ||
|
||
Receipt getReceiptDocument(String receiptId) throws ReceiptNotFoundException; | ||
/** | ||
* Retrieve receipt document from CosmosDB database | ||
* | ||
* @param eventId Biz-event id | ||
* @return receipt document | ||
* @throws ReceiptNotFoundException in case no receipt has been found with the given idEvent | ||
*/ | ||
Receipt getReceiptDocument(String eventId) throws ReceiptNotFoundException; | ||
|
||
/** | ||
* Save Receipts on CosmosDB database | ||
* | ||
* @param receipt Receipts to save | ||
* @return receipt documents | ||
*/ | ||
CosmosItemResponse<Receipt> saveReceipt(Receipt receipt); | ||
} |
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
13 changes: 13 additions & 0 deletions
13
src/main/java/it/gov/pagopa/receipt/pdf/generator/exception/UnableToSaveException.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,13 @@ | ||
package it.gov.pagopa.receipt.pdf.generator.exception; | ||
|
||
public class UnableToSaveException extends Exception { | ||
|
||
/** | ||
* Constructs new exception with provided message and cause | ||
* | ||
* @param message Detail message | ||
*/ | ||
public UnableToSaveException(String message) { | ||
super(message); | ||
} | ||
} |
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
Oops, something went wrong.