MCPcopy
hub / github.com/dgraph-io/dgraph / refreshToken

Method refreshToken

dgraph/cmd/alpha/run_test.go:1666–1676  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1664}
1665
1666func (t *Token) refreshToken() error {
1667 t.Lock()
1668 defer t.Unlock()
1669 err := hc.LoginUsingToken(0)
1670 if err != nil {
1671 return err
1672 }
1673 t.token.AccessJwt = hc.AccessJwt
1674 t.token.RefreshToken = hc.RefreshToken
1675 return nil
1676}
1677
1678func TestMain(m *testing.M) {
1679 conf := dgraphtest.NewClusterConfig().WithNumAlphas(1).WithNumZeros(1).WithReplicas(1).WithACL(time.Hour)

Callers 2

runGzipWithRetryFunction · 0.80
runWithRetriesForRespFunction · 0.80

Calls 3

LoginUsingTokenMethod · 0.80
LockMethod · 0.45
UnlockMethod · 0.45

Tested by

no test coverage detected