Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate some calls to FHIR and GraphQL #86

Merged
merged 24 commits into from Oct 18, 2023

Conversation

bmonjoie
Copy link
Contributor

The new implementation relies on OkHttp and Apollo.
OkHttp was added because the current implementation relies on Apache HTTP client, which is not supported anymore since Android 6 (API 23). A version supports Android 23+, but Apache does not officially maintain it. Also, OkHttp is the current standard and comes with lots of benefits, like, among other things, the logger, automatic support for GZip, and a strong security focus.
Apollo is in its version 2 as version 3+ requires Kotlin Coroutines. Also, the plan is that some new endpoints or extensions could be added to the FHIR API to remove the dependency on GraphQL.

Everything is hidden behind use cases to impact the current code base as little as possible.

Also, the code was migrated to AndroidX because of Apollo's dependencies.
The versions of the AndroidX have been kept back to avoid conflicts and upgrades.

dragos-dobre and others added 17 commits November 28, 2019 10:52
Finish release/v2.0.0
Finish release/v2.0.1
Finish Release/v2.0.1
Release v2.1.0
Github actions Java update
Release/2.2.0
OTC-745 Implemented claim 2-way sync
Revert "OTC-745 Implemented claim 2-way sync"
The new implementation relies on OkHttp and Apollo.
OkHttp was added because the current implementation relies on Apache HTTP
client, which is not supported anymore since Android 6 (API 23).
A version supports Android 23+, but Apache does not officially maintain it.
Also, OkHttp is the current standard and comes with lots of benefits like,
among other things, the logger, automatic support for GZip, and a strong
security focus.
Apollo is in its version 2 as version 3+ requires Kotlin Coroutines.
Also, the plan is that some new endpoints or extensions could be added to the
FHIR API to remove the dependency on GraphQL.

Everything is hidden behind use cases to impact as less as possible the
current code base.

Also, migrate to AndroidX because of Apollo's dependencies. The versions
of the AndroidX have been kept back to avoid conflicts and upgrades.
@bmonjoie bmonjoie self-assigned this Jun 23, 2023
@bmonjoie
Copy link
Contributor Author

This depends on a modification of the backend which would allow
to pass a reference with an OpenIMIS Code rather than a UUID.

There is still an open question about the "REJECTED" status to be solved.

OMT-339
@dragos-dobre
Copy link
Member

The second link you mention is a branch and not a PR.

@toch
Copy link

toch commented Jun 28, 2023

Benjamin told me that the main changes are in directories domain, network, and usecase. He advices to start with network. As I'm working on the backend to support some of the needs, I'll go through this PR too.

Deleting `ToRestApi` and removing Apache HTTP dependencies.
Adding a way to change the "Login/Logout" button automatically on login.

This depends on a new module migrating the controls to GraphQL that has not
yet been merged.

OMT-339
@bmonjoie bmonjoie force-pushed the OMT-339_migrate_to_FHIR_API branch from 737dd73 to d3412c2 Compare June 29, 2023 12:01
Copy link

@toch toch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bmonjoie Here a first review mainly on network, so you don't have to wait I've finished to read everything. I'm reviewing the rest.

I hope to have expressed clearly, smoothly, and politely my questions, suggestions, and concerns. I consider that I don't have all the cards in hand as you do, I hope this will help.

Copy link

@toch toch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

second review, focused on domain and usecase. there is still java.org.openimis.imisclaims to read.

@toch
Copy link

toch commented Jul 4, 2023

I've reviewed your answers. I can't resolve the discussions 🤷 so I've 👍 or answered them to do so.

Based on the method `build_fhir_total_list` in the Python code,
if there is no total, the claim is rejected.
@tdethier tdethier marked this pull request as ready for review September 25, 2023 12:36
@dragos-dobre
Copy link
Member

@bmonjoie We don't integrate code directly to main branch. Our development workflow follows GitFlow. Please create a PR for develop branch. I'm closing this PR.

@bmonjoie bmonjoie reopened this Oct 12, 2023
@bmonjoie bmonjoie changed the base branch from main to develop October 12, 2023 10:22
@bmonjoie
Copy link
Contributor Author

@dragos-dobre I have reopened the PR and changed the destination branch not to lose the history

@dragos-dobre dragos-dobre merged commit ae0015e into develop Oct 18, 2023
2 checks passed
@dragos-dobre dragos-dobre deleted the OMT-339_migrate_to_FHIR_API branch October 18, 2023 09:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants