 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Index ¶
Constants ¶
This section is empty.
Variables ¶
      View Source
      
  
    var ( DefaultChainId = map[string]string{ "ethereum": "1", "ethereum-goerli": "5", "ethereum-sepolia": "11155111", "polygon": "137", "polygon-mumbai": "80001", "optimism": "10", "optimism-goerli": "420", "arbitrum": "421613", "arbitrum-one": "42161", "arbitrum-nova": "42170", "arbitrum-goerli": "421613", } DefaultStartBlocks = map[string]int64{ "ethereum": 17066994, "ethereum-goerli": 8812127, "ethereum-sepolia": 3296058, "polygon": 41402415, "polygon-mumbai": 34239265, "optimism": 93335977, "optimism-goerli": 10442160, "arbitrum": 79305493, "arbitrum-nova": 8945015, "arbitrum-goerli": 17068300, } )
      View Source
      
  
    var ( FlagVersion = &cli.BoolFlag{ Name: "version", Usage: "Version", } FlagListen = &cli.StringFlag{ Name: "listen", Usage: "listen", Value: "127.0.0.1:2052", } FlagGrpcListen = &cli.StringFlag{ Name: "grpc.listen", Usage: "grpc.listen", Value: "127.0.0.1:2053", } FlagChain = &cli.StringFlag{ Name: "chain", Usage: "Chain", Value: "", } FlagChainId = &cli.StringFlag{ Name: "chain.id", Usage: string(_mustMarshal(DefaultChainId)), Value: "", } FlagEntryPoint = &cli.StringFlag{ Name: "entrypoint", Usage: "Entrypoint contract", Value: "0x5ff137d4b0fdcd49dca30c7cf57e578a026d2789", } FlagBackendUrl = &cli.StringFlag{ Name: "backend", Usage: "Backend chain rpc provider url", Value: "", } FlagCompress = &cli.BoolFlag{ Name: "compress", Usage: "compress", Value: false, } FlagDbPrefix = &cli.StringFlag{ Name: "db.prefix", Usage: "Backing database prefix, default: same value with --chain", Value: "", } FlagDbEngin = &cli.StringFlag{ Name: "db.engin", Usage: "Backing database implementation to use ('memory' or 'redis' or 'pebble')", Value: "memory", } FlagDbDataSource = &cli.StringFlag{ Name: "db.ds", Usage: "mysql://user:passwd@hostname:port/databasename, redis://passwd@host:port", Value: "", } FlagEthLogsStartBlock = &cli.Int64Flag{ Name: "block.start", Usage: string(_mustMarshal(DefaultStartBlocks)), Value: 0, } FlagEthLogsBlockRange = &cli.Int64Flag{ Name: "block.range", Usage: "eth_getLogs block range", Value: 1000, } )
      View Source
      
  
    var (
	DbKeyStartBlock = dbKeyPrefix + "start-block"
)
    
      View Source
      
  
var (
	LogDescriptor = "0x49628fd1471006c1482da88028e9ce4dbb080b815c9b0344d39e5a8e6ec1419f"
)
    Functions ¶
func DbKeyUserOp ¶
Types ¶
type Backend ¶
type Backend struct {
	// contains filtered or unexported fields
}
    func NewBackend ¶
func (*Backend) CallAndSave ¶
func (*Backend) LatestBlockNumber ¶
func (*Backend) SetNextStartBlock ¶
func (*Backend) StartBlock ¶
type Config ¶
type Config struct {
	Chain          string
	ChainId        string
	RpcListen      string
	GrpcListen     string
	EntryPoint     string
	BackendUrls    []string
	DbEngin        string
	DbDataSource   string
	StartBlock     int64
	BlockRangeSize int64
	Compress       bool
}
    func ParseConfig ¶
func ParseConfig(ctx *cli.Context) *Config
type GrpcServer ¶
type GrpcServer struct {
	proto.UnimplementedRelayServer
	// contains filtered or unexported fields
}
    func NewGrpcServer ¶
func NewGrpcServer(cfg *Config, db database.KVStore) *GrpcServer
func (*GrpcServer) Compressed ¶ added in v1.0.3
func (s *GrpcServer) Compressed() bool
func (*GrpcServer) Db ¶
func (s *GrpcServer) Db() database.KVStore
func (*GrpcServer) EntryPoint ¶
func (s *GrpcServer) EntryPoint() string
func (*GrpcServer) Run ¶
func (s *GrpcServer) Run() error
type Server ¶
type Server struct {
	// contains filtered or unexported fields
}
    func (*Server) Compressed ¶ added in v1.0.3
func (*Server) EntryPoint ¶
 Click to show internal directories. 
   Click to hide internal directories.