Changes in this pull request introduce support for java21 and neo4j 5.19.0.
Deployment changes:
Some changes to the circleci configuration, jitpack, and github actions workflow were needed.
Jitpack by default runs builds with an older version of java but this can be addressed with the
addition of a jitpack.yml. Circleci config also needed an update to allow circlular references
during the app runtime. This is okay for now but perhaps can be addressed in the future.
App configuration:
The SMILE app configuration is mostly the same. There is now an added bean in the app
configuration that explicitly sets the session factory for the neo4j driver.
Model layer:
The model layer changes include updates to the annotations classes used.
Persistence layer:
Appart from updating relevant annotations used for the persistence layer, some queries were
cleaned up, removed, and/or improved to consolidate additional calls that were populating
child edges and nodes. Example, we were using 2 calls to (1) fetch SampleMetadata nodes and (2)
fetch the related SampleStatus nodes for the SampleMetadata nodes. This is now accomplished with
one single query.
Service layer:
For the most part the service layer has remained the same. Some cleanup and refactoring were done
to remove unused methods and/or methods that were made redundant due to the improved/consolidated
queries modified in the persistence layer.
Test layer:
This layer required the most work as in addition to updating java and the testcontainers
for supporting a newer neo4j instance, we also migrated the test framework to junit-jupiter.
One of the major changes in the test classes is the use of https://github.com/SpringBootTest annotations instead
of using the @DataNeo4jTest annotation. There's also additional @TestConfiguration settings that
needed to be introduced to support the updated test framework and components.
Please follow these checklists to help prevent any unexpected issues from being introduced by the changes in this pull request. If an item does not apply then indicate so by surrounding the line item with ~~ to strikethrough the text. See basic writing and formatting syntax for more information.
I. Web service and data model checklist
Please follow these checks if any changes were made to any classes in the web, service, or persistence layers.
Code checks:
[x] Endpoints were tested to ensure their integrity.
[ ] Screenshots have been provided to demonstrate changes made to the response body JSON schema and/or swagger page. n/a
[ ] Unit tests were updated in relation to updates to the mocked test data. n/a
II. Neo4j models and database schema checklist:
[x] Neo4j persistence models were changed.
[x] The graph database produces the expected changes to models, relationships, and/or property names. [provide screenshot of updated elements in graph db below]
III. Message handlers checklist:
[ ] Changes in this PR affect the workflow of incoming messages. n/a
[x] Messages are following the expected workflow when published to the topic(s) changed or introduced in this pull request.
[ ] Unit tests were added to ensure messages are handled as expected. n/a
If no unit tests were updated or added, then please explain why: [insert details here]
Please describe how the workflow and messaging was tested/simulated:
Describe your testing environment:
NATS [local, local docker, dev server, production]
Neo4j [local, local docker, dev server, production]
SMILE Server [local, local docker, dev server, production]
Other: [insert details on how messages were published or simulated for testing]
IV. Configuration and/or permissions checklist: n/a
- [ ] New topics were introduced.
- [ ] The topics and appropriate permissions were updated in [smile-configuration](https://github.mskcc.org/cmo/smile-configuration).
- [ ] If applicable, a new account was set up and the account credentials and keys are checked into [smile-configuration](https://github.mskcc.org/cmo/smile-configuration).
- [ ] Account credentials and keys were shared with the appropriate parties.
Screenshots
General checklist:
[ ] All requested changes and comments have been resolved.
[ ] The commit log is comprehensible. It follows 7 rules of great commit messages. For most PRs a single commit should suffice, in some cases multiple topical commits can be useful. During review it is ok to see tiny commits (e.g. Fix reviewer comments), but right before the code gets merged to master or rc branch, any such commits should be squashed since they are useless to the other developers. Definitely avoid merge commits, use rebase instead.
Migration to Java21 and Neo4j 5.19.0
Details:
Changes in this pull request introduce support for java21 and neo4j 5.19.0.
Deployment changes:
Some changes to the circleci configuration, jitpack, and github actions workflow were needed. Jitpack by default runs builds with an older version of java but this can be addressed with the addition of a
jitpack.yml
. Circleci config also needed an update to allow circlular references during the app runtime. This is okay for now but perhaps can be addressed in the future.App configuration:
The SMILE app configuration is mostly the same. There is now an added bean in the app configuration that explicitly sets the session factory for the neo4j driver.
Model layer:
The model layer changes include updates to the annotations classes used.
Persistence layer:
Appart from updating relevant annotations used for the persistence layer, some queries were cleaned up, removed, and/or improved to consolidate additional calls that were populating child edges and nodes. Example, we were using 2 calls to (1) fetch SampleMetadata nodes and (2) fetch the related SampleStatus nodes for the SampleMetadata nodes. This is now accomplished with one single query.
Service layer:
For the most part the service layer has remained the same. Some cleanup and refactoring were done to remove unused methods and/or methods that were made redundant due to the improved/consolidated queries modified in the persistence layer.
Test layer:
This layer required the most work as in addition to updating java and the testcontainers for supporting a newer neo4j instance, we also migrated the test framework to junit-jupiter.
One of the major changes in the test classes is the use of https://github.com/SpringBootTest annotations instead of using the @DataNeo4jTest annotation. There's also additional @TestConfiguration settings that needed to be introduced to support the updated test framework and components.
Web layer:
Some relatively minor changes introduced here to migrate away from swagger by springfox to swagger by open api. Reference documentation: https://springdoc.org/#migrating-from-springfox
Signed-off-by: Angelica Ochoa 15623749+ao508@users.noreply.github.com
Update docker file for java21 (https://github.com/mskcc/smile-server/pull/1317)
Signed-off-by: Angelica Ochoa 15623749+ao508@users.noreply.github.com
Fix for correcting CMO patient IDs (https://github.com/mskcc/smile-server/pull/1319)
Fix for optional matching on sample status
Signed-off-by: Angelica Ochoa 15623749+ao508@users.noreply.github.com
Fix end date formatter (https://github.com/mskcc/smile-server/pull/1320)
Signed-off-by: Angelica Ochoa 15623749+ao508@users.noreply.github.com
Crossing T's and dotting I's
Please follow these checklists to help prevent any unexpected issues from being introduced by the changes in this pull request. If an item does not apply then indicate so by surrounding the line item with
~~
to strikethrough the text. See basic writing and formatting syntax for more information.I. Web service and data model checklist
Please follow these checks if any changes were made to any classes in the web, service, or persistence layers.
Code checks:
Screenshots have been provided to demonstrate changes made to the response body JSON schema and/or swagger page.n/aUnit tests were updated in relation to updates to the mocked test data.n/aII. Neo4j models and database schema checklist:
III. Message handlers checklist:
Changes in this PR affect the workflow of incoming messages.n/aUnit tests were added to ensure messages are handled as expected.n/aIf no unit tests were updated or added, then please explain why: [insert details here]
Please describe how the workflow and messaging was tested/simulated:
Describe your testing environment:
Other: [insert details on how messages were published or simulated for testing]
IV. Configuration and/or permissions checklist: n/a
Screenshots
General checklist: