tidb-dashboard icon indicating copy to clipboard operation
tidb-dashboard copied to clipboard

"api.statement.export_no_data" when exporting SQL statements

Open AstroProfundis opened this issue 3 years ago • 0 comments

Bug Report

Please answer these questions before submitting your issue. Thanks!

What did you do? Try to export SQL statements data in dashboard on a TiDB Cloud maintained TiDB cluster.

What did you expect to see? Data exported and downloaded.

What did you see instead? An error with code api.statement.export_no_data in the response body. 图片

The full error stack is as follows:

error.api.statement.export_no_data
at
github.com/pingcap/tidb-dashboard/pkg/apiserver/statement.(*Service).downloadTokenHandler()
/nfs/cache/mod/github.com/pingcap/[email protected]/pkg/apiserver/statement/service.go:274
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/pingcap/tidb-dashboard/pkg/apiserver/utils.MWConnectTiDB.func1()
/nfs/cache/mod/github.com/pingcap/[email protected]/pkg/apiserver/utils/tidb_conn.go:66
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/breeswish/gin-jwt/v2.(*GinJWTMiddleware).middlewareImpl()
/nfs/cache/mod/github.com/breeswish/gin-jwt/[email protected]/auth_jwt.go:403
at
github.com/breeswish/gin-jwt/v2.(*GinJWTMiddleware).MiddlewareFunc.func1()
/nfs/cache/mod/github.com/breeswish/gin-jwt/[email protected]/auth_jwt.go:365
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/pingcap/tidb-dashboard/util/rest.ErrorHandlerFn.func1()
/nfs/cache/mod/github.com/pingcap/[email protected]/util/rest/error.go:68
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/gin-contrib/gzip.Gzip.func2()
/nfs/cache/mod/github.com/gin-contrib/[email protected]/gzip.go:47
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/gin-gonic/gin.CustomRecoveryWithWriter.func1()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/recovery.go:99
at
github.com/gin-gonic/gin.(*Context).Next()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/context.go:165
at
github.com/gin-gonic/gin.(*Engine).handleHTTPRequest()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/gin.go:489
at
github.com/gin-gonic/gin.(*Engine).ServeHTTP()
/nfs/cache/mod/github.com/gin-gonic/[email protected]/gin.go:445
at
github.com/pingcap/tidb-dashboard/pkg/apiserver.(*Service).handler()
/nfs/cache/mod/github.com/pingcap/[email protected]/pkg/apiserver/apiserver.go:234
at
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2069
at
github.com/pingcap/tidb-dashboard/pkg/utils.(*ServiceStatus).NewStatusAwareHandler.func1()
/nfs/cache/mod/github.com/pingcap/[email protected]/pkg/utils/service_status.go:67
at
net/http.HandlerFunc.ServeHTTP()
/usr/local/go/src/net/http/server.go:2069
at
net/http.(*ServeMux).ServeHTTP()
/usr/local/go/src/net/http/server.go:2448
at
go.etcd.io/etcd/embed.(*accessController).ServeHTTP()
/nfs/cache/mod/go.etcd.io/[email protected]/embed/serve.go:359
at
net/http.serverHandler.ServeHTTP()
/usr/local/go/src/net/http/server.go:2887
at
net/http.(*conn).serve()
/usr/local/go/src/net/http/server.go:1952
at
runtime.goexit()
/usr/local/go/src/runtime/asm_amd64.s:1371

What version of TiDB Dashboard are you using (./tidb-dashboard --version)?

v5.4.1 on TiDB Cloud

AstroProfundis avatar Jun 01 '22 08:06 AstroProfundis