2015-03-05 19:02:25 +01:00
|
|
|
module Network.GRPC.Core.Constants where
|
2015-03-03 09:30:11 +01:00
|
|
|
|
|
|
|
#include "grpc/grpc.h"
|
2016-04-21 01:02:53 +02:00
|
|
|
#include "grpc/impl/codegen/propagation_bits.h"
|
2015-03-03 09:30:11 +01:00
|
|
|
|
2015-03-03 14:42:09 +01:00
|
|
|
argEnableCensus :: Int
|
2015-03-03 09:30:11 +01:00
|
|
|
argEnableCensus = #const GRPC_ARG_ENABLE_CENSUS
|
2015-03-03 14:42:09 +01:00
|
|
|
|
|
|
|
argMaxConcurrentStreams :: Int
|
2015-03-03 09:30:11 +01:00
|
|
|
argMaxConcurrentStreams = #const GRPC_ARG_MAX_CONCURRENT_STREAMS
|
2015-03-03 14:42:09 +01:00
|
|
|
|
|
|
|
argMaxMessageLength :: Int
|
2015-03-03 09:30:11 +01:00
|
|
|
argMaxMessageLength = #const GRPC_ARG_MAX_MESSAGE_LENGTH
|
|
|
|
|
|
|
|
writeBufferHint :: Int
|
|
|
|
writeBufferHint = #const GRPC_WRITE_BUFFER_HINT
|
|
|
|
|
|
|
|
writeNoCompress :: Int
|
|
|
|
writeNoCompress = #const GRPC_WRITE_NO_COMPRESS
|
2016-04-21 01:02:53 +02:00
|
|
|
|
|
|
|
newtype PropagationMask = PropagationMask {unPropagationMask :: Int}
|
|
|
|
deriving (Show, Eq, Ord)
|
|
|
|
|
|
|
|
propagateDeadline :: Int
|
|
|
|
propagateDeadline = #const GRPC_PROPAGATE_DEADLINE
|
|
|
|
|
|
|
|
propagateCensusStatsContext :: Int
|
|
|
|
propagateCensusStatsContext = #const GRPC_PROPAGATE_CENSUS_STATS_CONTEXT
|
|
|
|
|
|
|
|
propagateCensusTracingContext :: Int
|
|
|
|
propagateCensusTracingContext = #const GRPC_PROPAGATE_CENSUS_TRACING_CONTEXT
|
|
|
|
|
|
|
|
propagateCancellation :: Int
|
|
|
|
propagateCancellation = #const GRPC_PROPAGATE_CANCELLATION
|