Skip to content

[AR-1691] The CLI does not need to know the frontend URL#1990

Merged
glasser merged 1 commit intomasterfrom
glasser/no-frontend-knowledge
Jun 11, 2020
Merged

[AR-1691] The CLI does not need to know the frontend URL#1990
glasser merged 1 commit intomasterfrom
glasser/no-frontend-knowledge

Conversation

@glasser
Copy link
Copy Markdown
Member

@glasser glasser commented Jun 10, 2020

Currently the CLI has configuration (via engine.frontend in a config file or
the --frontend flag to a few commands) to control what Engine frontend the user
is using. This is primarily set by Apollo employees using staging servers. This
is in addition to setting engine.endpoint to control which GraphQL server it
talks to.

This is used for two things:

  • passing arguments to a couple ServiceMutation fields
  • printing links in services:list

As of recently, this no longer is needed:

  • those ServiceMutation fields now ignore the frontend argument and just use
    the correct frontend for the server processing them
  • we expose a Query.frontendUrlRoot field that services:list can use

So this change completely removes recognition of this config field as well as
the flag. (Note that it is not an error to have unrecognized fields in your
config file, though it is to pass an unknown flag.) While this is technically
backwards-incompatible, we don't expect that this undocumented feature is used
much other than by Apollo employees.

TODO:

  • Update CHANGELOG.md* with your change (include reference to issue & this PR)
  • Make sure all of the significant new logic is covered by tests
  • Rebase your changes on master so that they can be merged easily
  • Make sure all tests and linter rules pass

*Make sure changelog entries note which project(s) has been affected. See older entries for examples on what this looks like.

@glasser glasser requested a review from jbaxleyiii June 10, 2020 01:27
Currently the CLI has configuration (via `engine.frontend` in a config file or
the --frontend flag to a few commands) to control what Engine frontend the user
is using. This is primarily set by Apollo employees using staging servers. This
is in addition to setting `engine.endpoint` to control which GraphQL server it
talks to.

This is used for two things:
- passing arguments to a couple ServiceMutation fields
- printing links in `services:list`

As of recently, this no longer is needed:
- those ServiceMutation fields now ignore the `frontend` argument and just use
  the correct frontend for the server processing them
- we expose a Query.frontendUrlRoot field that `services:list` can use

So this change completely removes recognition of this config field as well as
the flag. (Note that it is not an error to have unrecognized fields in your
config file, though it is to pass an unknown flag.) While this is technically
backwards-incompatible, we don't expect that this undocumented feature is used
much other than by Apollo employees.
@glasser glasser force-pushed the glasser/no-frontend-knowledge branch from 5ea4dac to 03f3349 Compare June 10, 2020 20:11
@glasser glasser merged commit 5130373 into master Jun 11, 2020
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

Successfully merging this pull request may close these issues.

2 participants