github.com/blend/go-sdk@v1.20220411.3/autoflush/constants.go (about) 1 /* 2 3 Copyright (c) 2022 - Present. Blend Labs, Inc. All rights reserved 4 Use of this source code is governed by a MIT license that can be found in the LICENSE file. 5 6 */ 7 8 package autoflush 9 10 import "time" 11 12 // Defaults 13 const ( 14 DefaultMaxFlushes = 128 15 DefaultMaxLen = 512 16 DefaultFlushInterval = 500 * time.Millisecond 17 DefaultShutdownGracePeriod = 10 * time.Second 18 ) 19 20 // Metric names 21 const ( 22 MetricFlush string = "autoflush.flush" 23 MetricFlushItemCount string = "autoflush.flush.item_count" 24 MetricFlushEnqueueElapsed string = "autoflush.flush.enqueue.elapsed" 25 MetricFlushHandler string = "autoflush.flush.handler" 26 MetricFlushHandlerElapsed string = "autoflush.flush.handler.elapsed" 27 MetricFlushQueueLength string = "autoflush.flush.queue_length" 28 MetricBufferLength string = "autoflush.buffer.length" 29 MetricAdd string = "autoflush.add" 30 MetricAddElapsed string = "autoflush.add.elapsed" 31 MetricAddMany string = "autoflush.add_many" 32 MetricAddManyItemCount string = "autoflush.add_many.item_count" 33 MetricAddManyElapsed string = "autoflush.add_many.elapsed" 34 )