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

Remove HTTP admin endpoints #4754

Merged
merged 9 commits into from
Feb 14, 2020
Merged

Conversation

pawanrawal
Copy link
Contributor

@pawanrawal pawanrawal commented Feb 10, 2020

These endpoints are now served via the GraphQL Admin API and hence we are removing the HTTP endpoints. Another PR for updating the docs will follow.


This change is Reviewable

Docs Preview: Dgraph Preview

@pawanrawal pawanrawal requested review from manishrjain and a team as code owners February 10, 2020 14:06
@MichelDiz
Copy link
Contributor

Just a point, wouldn't it be nice to leave that for compatibility? Some users might not like to be forced to use GraphQL for these operations. Sending curl commands would get bigger and more complex.

e.g:
do this

jq -n '
{ 
  query: "mutation {
  export(input: {
    format: "JSON"
  })
  {
    response {
      Response
    }
  }
}"' | 
curl -X POST -H "Content-Type: application/json" http://localhost:8080/admin -d @- | jq -r

Instead of just

curl 'localhost:8080/admin/export?format=json'

Copy link
Contributor

@martinmr martinmr left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 11 of 11 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @manishrjain)

Copy link
Contributor

@manishrjain manishrjain left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @pawanrawal)


graphql/admin/export.go, line 51 at r1 (raw file):

	format := worker.DefaultExportFormat
	fmt.Printf("input: %+v\n", input)

fmt.printfs?

@pawanrawal pawanrawal merged commit 8fa2fd9 into master Feb 14, 2020
@pawanrawal pawanrawal deleted the pawanrawal/remove-http-admin-endpoints branch February 14, 2020 15:22
pawanrawal added a commit that referenced this pull request Feb 20, 2020
pawanrawal added a commit that referenced this pull request Feb 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants