The problem is that the Go HTTP client has a bug that panics with stack overflow due to recursions.
This issue is described in net/http: ReadRequest can stack overflow due to recursion with very large headers · Issue #45710 · golang/go · GitHub and CVE is net/http in Go before 1.15.12 and 1.16.x before 1.16.4... · CVE-2021-31525 · GitHub Advisory Database · GitHub
The problem here is that Dgraph is using Go 1.12!!! Therefore this BUG is included. see dgraph/go.mod at main · dgraph-io/dgraph · GitHub
This is a blocker to anyone who wants to reach Dgraph programmatically using the net/http Go library.