@@ -22,16 +22,11 @@ package connection
2222
2323import (
2424 "context"
25- "time"
2625)
2726
2827type ContextKey string
2928
3029const (
31- keyUseQueueTimeout ContextKey = "arangodb-use-queue-timeout"
32- keyMaxQueueTime ContextKey = "arangodb-max-queue-time-seconds"
33- keyDriverFlags ContextKey = "arangodb-driver-flags"
34-
3530 keyAsyncRequest ContextKey = "arangodb-async-request"
3631 keyAsyncID ContextKey = "arangodb-async-id"
3732)
@@ -45,25 +40,6 @@ func contextOrBackground(ctx context.Context) context.Context {
4540 return context .Background ()
4641}
4742
48- // WithArangoQueueTimeout is used to enable Queue timeout on the server side.
49- // If WithArangoQueueTime is used, then its value takes precedence in other case value of ctx.Deadline will be taken
50- // Deprecated: use ArangoDBConfiguration.ArangoQueueTimeoutEnabled
51- func WithArangoQueueTimeout (parent context.Context , useQueueTimeout bool ) context.Context {
52- return context .WithValue (contextOrBackground (parent ), keyUseQueueTimeout , useQueueTimeout )
53- }
54-
55- // WithArangoQueueTime defines max queue timeout on the server side.
56- // Deprecated: use ArangoDBConfiguration.ArangoQueueTimeoutSec
57- func WithArangoQueueTime (parent context.Context , duration time.Duration ) context.Context {
58- return context .WithValue (contextOrBackground (parent ), keyMaxQueueTime , duration )
59- }
60-
61- // WithDriverFlags is used to configure additional flags for the `x-arango-driver` header.
62- // Deprecated: use ArangoDBConfiguration.DriverFlags
63- func WithDriverFlags (parent context.Context , value []string ) context.Context {
64- return context .WithValue (contextOrBackground (parent ), keyDriverFlags , value )
65- }
66-
6743// WithAsync is used to configure a context to make an async operation - requires Connection with Async wrapper!
6844func WithAsync (parent context.Context ) context.Context {
6945 return context .WithValue (contextOrBackground (parent ), keyAsyncRequest , true )
0 commit comments