Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 39 additions & 25 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,31 +37,45 @@ jobs:
echo "Published release ${{ steps.get_release.outputs.tag_name }} as latest"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
backfill:
name: Backfill master to develop branch
runs-on: ubuntu-latest
steps:
- name: Check params
run: |
echo "head.ref = ${{github.event.pull_request.head.ref}}"
echo "base.ref = ${{github.event.pull_request.base.ref}}"

- uses: actions/checkout@v4
with:
ref: master
token: ${{ secrets.ACTIONS_NICHOLAS_PAT }}

- name: Create backfill PR to develop
- name: Create backfill branch
run: git checkout -b backfill/master;

# In order to make a commit, we need to initialize a user.
- name: Initialize mandatory git config
run: |
# Check if a PR already exists
EXISTING_PR=$(gh pr list --base develop --head master --json number --jq '.[0].number' || echo "")

if [ -n "$EXISTING_PR" ]; then
echo "PR #${EXISTING_PR} already exists for master -> develop"
exit 0
fi

# Create the backfill PR
gh pr create \
--base develop \
--head master \
--title "Backfill master into develop" \
--body "This PR backfills changes from master into develop after production deployment.

## Changes
This includes all changes that were merged to master.

## Notes
- Review for any conflicts
- Merge after verifying all changes are appropriate for develop branch"

echo "Created backfill PR from master to develop"
git config user.name "GitHub actions"
git config user.email noreply@github.com

- name: Push backfill branch
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.ACTIONS_NICHOLAS_PAT }}
run: |
git push origin backfill/master

- name: Create backfill pull request to develop branch
uses: thomaseizinger/create-pull-request@1.4.0
with:
github_token: ${{ secrets.ACTIONS_NICHOLAS_PAT }}
head: backfill/master
base: develop
draft: true
title: Backfill ${{ github.event.pull_request.base.ref }} branch to develop branch
body: |
Hi @${{ github.actor }}!

This PR was created in response to a trigger of the release workflow here: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}.
Following a release, this is a backfill from the main branch to the develop branch.
2 changes: 1 addition & 1 deletion acceptance-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<artifactId>acceptance-tests</artifactId>
<groupId>gov.cms.qpp.conversion</groupId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<name>conversion-tests</name>
<packaging>jar</packaging>
<properties>
Expand Down
2 changes: 1 addition & 1 deletion commandline/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-conversion-tool-parent</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion commons/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-conversion-tool-parent</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
4 changes: 2 additions & 2 deletions converter/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-conversion-tool-parent</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down Expand Up @@ -185,7 +185,7 @@
<dependency>
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>commons</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<scope>compile</scope>
</dependency>

Expand Down
2 changes: 1 addition & 1 deletion generate-race-cpcplus/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>generateRaceCpcPlus</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<name>generate-race-cpcplus</name>
<packaging>jar</packaging>

Expand Down
2 changes: 1 addition & 1 deletion generate/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<artifactId>qpp-conversion-tool-parent</artifactId>
<groupId>gov.cms.qpp.conversion</groupId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Expand Down
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-conversion-tool-parent</artifactId>
<packaging>pom</packaging>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<name>QPP Conversion Tool</name>

<properties>
Expand Down Expand Up @@ -469,13 +469,13 @@
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>1.5.13</version>
<version>1.5.25</version>
</dependency>

<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
<version>1.5.13</version>
<version>1.5.25</version>
</dependency>

<dependency>
Expand Down
2 changes: 1 addition & 1 deletion qrda3-update-measures/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-update-measures</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<name>qrda3-update-measures</name>
<packaging>jar</packaging>

Expand Down
8 changes: 4 additions & 4 deletions rest-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<parent>
<groupId>gov.cms.qpp.conversion</groupId>
<artifactId>qpp-conversion-tool-parent</artifactId>
<version>2026.02.17.01-RELEASE</version>
<version>2026.02.27.01-RELEASE</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down Expand Up @@ -226,17 +226,17 @@
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
<version>10.1.45</version>
<version>10.1.52</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-el</artifactId>
<version>10.1.45</version>
<version>10.1.52</version>
</dependency>
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-websocket</artifactId>
<version>10.1.45</version>
<version>10.1.52</version>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,35 +1,31 @@
package gov.cms.qpp.conversion.api.controllers.v1;
package gov.cms.qpp.conversion.api.exceptions;

import gov.cms.qpp.conversion.api.exceptions.InvalidFileTypeException;
import gov.cms.qpp.conversion.api.exceptions.InvalidPurposeException;
import gov.cms.qpp.conversion.api.exceptions.NoFileInDatabaseException;
import com.amazonaws.AmazonServiceException;
import gov.cms.qpp.conversion.api.services.AuditService;
import gov.cms.qpp.conversion.model.error.AllErrors;
import gov.cms.qpp.conversion.model.error.QppValidationException;
import gov.cms.qpp.conversion.model.error.TransformException;

import com.amazonaws.AmazonServiceException;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpStatus;
import org.springframework.http.MediaType;
import org.springframework.http.HttpStatusCode;
import org.springframework.http.ResponseEntity;
import org.springframework.web.context.request.WebRequest;
import org.springframework.web.bind.annotation.ControllerAdvice;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.multipart.MultipartException;
import org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandler;

import gov.cms.qpp.conversion.api.exceptions.BadZipException;
import org.springframework.web.servlet.resource.NoResourceFoundException;

/**
* Modify the controller to send back different responses for exceptions
*/
@ControllerAdvice
public class ExceptionHandlerControllerV1 extends ResponseEntityExceptionHandler {
private static final Logger API_LOG = LoggerFactory.getLogger(ExceptionHandlerControllerV1.class);
public class GlobalExceptionHandler extends ResponseEntityExceptionHandler {
private static final Logger API_LOG = LoggerFactory.getLogger(GlobalExceptionHandler.class);

private AuditService auditService;

Expand All @@ -38,7 +34,7 @@ public class ExceptionHandlerControllerV1 extends ResponseEntityExceptionHandler
*
* @param auditService {@link AuditService} facilitates persistence of conversion results
*/
public ExceptionHandlerControllerV1(final AuditService auditService) {
public GlobalExceptionHandler(final AuditService auditService) {
this.auditService = auditService;
}

Expand All @@ -52,7 +48,9 @@ public ExceptionHandlerControllerV1(final AuditService auditService) {
@ExceptionHandler(TransformException.class)
@ResponseBody
ResponseEntity<AllErrors> handleTransformException(TransformException exception) {
API_LOG.error("Transform exception occurred", exception);
API_LOG.info("Transform failed validation (422): {}", exception.getMessage());
API_LOG.debug("TransformException details", exception);

auditService.failConversion(exception.getConversionReport());
return cope(exception);
}
Expand All @@ -67,11 +65,32 @@ ResponseEntity<AllErrors> handleTransformException(TransformException exception)
@ExceptionHandler(QppValidationException.class)
@ResponseBody
ResponseEntity<AllErrors> handleQppValidationException(QppValidationException exception) {
API_LOG.error("Validation exception occurred", exception);
API_LOG.info("Submission validation failed (422): {}", exception.getMessage());
API_LOG.debug("QppValidationException details", exception);

auditService.failValidation(exception.getConversionReport());
return cope(exception);
}

/**
* Handles {@link NoResourceFoundException} for requests to non-existent paths/resources.
* Returns a clean 404 and logs at DEBUG/TRACE to avoid ERROR-level noise.
*/
@Override
protected ResponseEntity<Object> handleNoResourceFoundException(
NoResourceFoundException ex,
HttpHeaders headers,
HttpStatusCode status,
WebRequest request) {

API_LOG.debug("No resource found ({}): {}", status.value(), ex.getMessage());
API_LOG.trace("NoResourceFoundException details", ex);

return ResponseEntity.status(status)
.contentType(MediaType.TEXT_PLAIN)
.body("Not found");
}

/**
* "Catch" the {@link NoFileInDatabaseException}.
* Return the {@link AllErrors} with an HTTP status 404.
Expand Down
Loading
Loading