Documentation
¶
Overview ¶
Package types contains various types, consts and vars for bidcollect
Index ¶
Constants ¶
View Source
const ( SourceTypeGetHeader = 0 SourceTypeDataAPI = 1 SourceTypeUltrasoundStream = 2 UltrasoundStreamDefaultURL = "ws://relay-builders-eu.ultrasound.money/ws/v1/top_bid" InitialBackoffSec = 5 MaxBackoffSec = 120 // bucketMinutes is the number of minutes to write into each CSV file (i.e. new file created for every X minutes bucket) BucketMinutes = 60 // channel size for bid collector inputs BidCollectorInputChannelSize = 1000 RedisChannel = "bidcollect/bids" )
Variables ¶
View Source
var CommonBidCSVFields = []string{
"source_type",
"received_at_ms",
"timestamp_ms",
"slot",
"slot_t_ms",
"value",
"block_hash",
"parent_hash",
"builder_pubkey",
"block_number",
"block_fee_recipient",
"relay",
"proposer_pubkey",
"proposer_fee_recipient",
"optimistic_submission",
}
Functions ¶
This section is empty.
Types ¶
type CommonBid ¶
type CommonBid struct {
// Collector-internal fields
SourceType int `json:"source_type"`
ReceivedAtMs int64 `json:"received_at"`
// Common fields
Slot uint64 `json:"slot"`
BlockNumber uint64 `json:"block_number"`
BlockHash string `json:"block_hash"`
ParentHash string `json:"parent_hash"`
BuilderPubkey string `json:"builder_pubkey"`
Value string `json:"value"`
// Ultrasound top-bid stream - https://github.com/ultrasoundmoney/docs/blob/main/top-bid-websocket.md
BlockFeeRecipient string `json:"block_fee_recipient"`
// Data API
// - Ultrasound: https://relay-analytics.ultrasound.money/relay/v1/data/bidtraces/builder_blocks_received?slot=9194844
// - Flashbots: https://boost-relay.flashbots.net/relay/v1/data/bidtraces/builder_blocks_received?slot=8969837
Relay string `json:"relay"`
TimestampMs int64 `json:"timestamp_ms"`
ProposerPubkey string `json:"proposer_pubkey"`
ProposerFeeRecipient string `json:"proposer_fee_recipient"`
OptimisticSubmission bool `json:"optimistic_submission"`
}
func (*CommonBid) ToCSVFields ¶
func (*CommonBid) ValueAsBigInt ¶
Click to show internal directories.
Click to hide internal directories.