DARPA-ASKEM / sciml-service

Simulation Service provides an interface and job runner for ASKEM models.
MIT License
3 stars 1 forks source link

terarium dataservice migration changes #158

Closed kbirk closed 4 months ago

kbirk commented 5 months ago

Hello

As you may be aware terarium has inherited the tds datraservice endpoints. Some changes have been made while integrating it with the existing backend.

Here is a small untested branch to assist in transitioning to the new endpoints. The changes are as follows:

1) Request urls and query params are now kabob-case rather than snake_case. 2) JSON keys are serialized / deserialized from camelCase rather than snake_case by default. Support for a "X-Enable-Snake-Case" header has been integrated which when provided will serialize / deserialize JSON keys as snake_case. 3) All id fields are now uuid4 types and will be generated server side. Types have an optional human friendly name field as well. 4) Our backend uses OAuth2 and many endpoints require a user object for ReBAC. For simplicity we have created a shared service-user that will be injected if the correct basic auth credential is added to each request. I've introduced TDS_USER and TDS_PASSWORD env vars that will be injected in a basic auth header in each request. Please contact our team and we will provide the credential for our staging env. Please do not commit the credential to the repo unencrypted.

Please let me know if there are any issues with this branch or you have any concerns. I apologize for any glaring issues with the work here, I am not familiar with Julia :)

Cheers

codecov-commenter commented 5 months ago

Codecov Report

Attention: 10 lines in your changes are missing coverage. Please review.

Comparison is base (357c7e8) 84.40% compared to head (bc97604) 84.44%. Report is 1 commits behind head on main.

Files Patch % Lines
src/SimulationService.jl 68.75% 10 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #158 +/- ## ========================================== + Coverage 84.40% 84.44% +0.04% ========================================== Files 4 4 Lines 654 675 +21 ========================================== + Hits 552 570 +18 - Misses 102 105 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.