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

Create HTTP Client and Related Resolver for Program Service Endpoints in Gateway - Part 2 #703

Open
9 of 11 tasks
daniel-cy-lu opened this issue Nov 16, 2023 · 8 comments
Open
9 of 11 tasks
Assignees

Comments

@daniel-cy-lu
Copy link
Contributor

daniel-cy-lu commented Nov 16, 2023

  1. Create a function in the httpClient to interact with the ProgramService for the given action.
  2. Update the gql resolver to use the httpClient function from step 1 instead of the GRPC client.

program service clients:

  • listUsers
  • listCancers
  • listPrimarySites
  • listInstitutions
  • listCountries
  • createProgram
  • updateProgram
  • inviteUser
  • joinProgram
  • updateUser
  • removeUser

This ticket has part 1 and part 2

@daniel-cy-lu daniel-cy-lu self-assigned this Nov 16, 2023
@daniel-cy-lu
Copy link
Contributor Author

Clients with the the four unchecked boxes are using program service endpoint with bugs. Once those bugs are cleared, I can do some testing.

@daniel-cy-lu
Copy link
Contributor Author

down to one last updateProgram endpoint which needs testing

@daniel-cy-lu
Copy link
Contributor Author

For one endpoint, https://program-service.dev.argo.cancercollaboratory.org/swagger-ui/index.html#/program-controller/updateProgram (updateProgram), we couldn't get the testing done before the end of the year. There is some update needed in ProgramService and Azher has been working on it before he needs to leave for wisdom tooth extraction. So I am leaving my code in Plateform-API to accept the payload that is required for this endpoint, and once ProgramService is updated, the updateProgram http client should work.

{
  "program": {
    "shortName": "string",
    "description": "string",
    "name": "string",
    "website": "string",
    "commitmentDonors": 0,
    "submittedDonors": 0,
    "genomicDonors": 0,
    "membershipType": "string",
    "institutions": [
      "string"
    ],
    "countries": [
      "string"
    ],
    "cancerTypes": [
      "string"
    ],
    "primarySites": [
      "string"
    ],
    "dataCenter": {
      "id": "string",
      "shortName": "string",
      "name": "string",
      "uiUrl": "string",
      "gatewayUrl": "string"
    }
  }
}

@daniel-cy-lu
Copy link
Contributor Author

Discover a bug in ProgramService endpoint, createProgram, https://program-service.dev.argo.cancercollaboratory.org/swagger-ui/index.html#/program-controller/createProgram. I believe it's caused by the addition of DataCenterId property to the payload of this endpoint.

@demariadaniel
Copy link
Contributor

demariadaniel commented Feb 1, 2024

Working http queries for program, programs, dataCenters and programOptions
Query details can be provided if needed

Screenshot 2024-02-01 at 10.41.06 AM.png

Screenshot 2024-02-01 at 10.40.50 AM.png

Screenshot 2024-02-01 at 10.40.40 AM.png

Screenshot 2024-02-01 at 10.40.31 AM.png

@demariadaniel
Copy link
Contributor

demariadaniel commented Feb 1, 2024

Successful updates for inviteUser, updateUser, removeUser
Query details can be provided if needed

Screenshot 2024-02-01 at 11.49.44 AM.png

Screenshot 2024-02-01 at 11.49.07 AM.png

Screenshot 2024-02-01 at 11.48.54 AM.png

@demariadaniel demariadaniel self-assigned this Feb 1, 2024
@demariadaniel
Copy link
Contributor

demariadaniel commented Feb 1, 2024

Due to known issues w/ Program Service Create Program / Update Program, these resolvers will have to be tested once Program Service is updated

@demariadaniel
Copy link
Contributor

demariadaniel commented Feb 1, 2024

PR: #694

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants