Versions in this module Expand all Collapse all v1 v1.11.1 Jun 10, 2024 Changes in this version + const CaptiveCoreConfigPathName + const CaptiveCoreConfigUseDB + const CaptiveCoreHTTPPortFlagName + const DatabaseURLFlagName + const DisableTxSubFlagName + const EnableCaptiveCoreIngestionFlagName + const EnableIngestionFilteringFlagName + const HcnetCoreBinaryPathName + const HcnetCoreDBURLFlagName + const HcnetCoreURLFlagName + const HcnetPubnet + const HcnetTestnet + const HistoryArchiveCachingFlagName + const HistoryArchiveURLsFlagName + const IngestFlagName + const NetworkFlagName + const NetworkPassphraseFlagName + const SkipTxmeta + var ApiServerCommands = []string + var AuroraCmd = "aurora" + var DatabaseBoundCommands = append(ApiServerCommands, DbCmd, IngestCmd) + var DbCmd = "db" + var DbFillGapsCmd = "fill-gaps" + var DbReingestCmd = "reingest" + var IngestBuildStateCmd = "build-state" + var IngestCmd = "ingest" + var IngestInitGenesisStateCmd = "init-genesis-state" + var IngestStressTestCmd = "stress-test" + var IngestTriggerStateRebuild = "trigger-state-rebuild" + var IngestVerifyRangeCmd = "verify-range" + var IngestionCommands = append(ApiServerCommands, IngestInitGenesisStateCmd, IngestBuildStateCmd, ...) + var PubnetConf = networkConfig + var PubnetDefaultConfig []byte + var RecordMetricsCmd = "record-metrics" + var ServeCmd = "serve" + var TestnetConf = networkConfig + var TestnetDefaultConfig []byte + func ApplyFlags(config *Config, flags support.ConfigOptions, options ApplyOptions) error type App + func NewAppFromFlags(config *Config, flags support.ConfigOptions) (*App, error) + func (a *App) Config() Config + func (a *App) GetCoreState() corestate.State + func (a *App) Paths() paths.Finder + func (a *App) Shutdown() + func (a *App) UpdateAuroraLedgerState(ctx context.Context) + func (a *App) UpdateCoreLedgerState(ctx context.Context) + func (a *App) UpdateFeeStatsState(ctx context.Context) + func (a *App) UpdateHcnetCoreInfo(ctx context.Context) error + type ApplyOptions struct + AlwaysIngest bool + RequireCaptiveCoreFullConfig bool type Config + AdminPort uint + ApplyMigrations bool + BehindAWSLoadBalancer bool + BehindCloudflare bool + CaptiveCoreBinaryPath string + CaptiveCoreConfigPath string + CaptiveCoreConfigUseDB bool + CaptiveCoreReuseStoragePath bool + CaptiveCoreStoragePath string + CaptiveCoreToml *ledgerbackend.CaptiveCoreToml + CaptiveCoreTomlParams ledgerbackend.CaptiveCoreTomlParams + CheckpointFrequency uint32 + ClientQueryTimeout time.Duration + DisablePathFinding bool + DisablePoolPathFinding bool + DisableTxSub bool + HcnetCoreURL string + HistoryArchiveCaching bool + HistoryRetentionReapCount uint + IngestDisableStateVerification bool + IngestEnableExtendedLogLedgerStats bool + IngestStateVerificationCheckpointFrequency uint + IngestStateVerificationTimeout time.Duration + MaxAssetsPerPathRequest int + MaxConcurrentRequests uint + MaxHTTPRequestSize uint + MaxPathFindingRequests uint + Network string + RoDatabaseURL string + RoundingSlippageFilter int + SkipTxmeta bool + func Flags() (*Config, support.ConfigOptions) v0 v0.11.0 Dec 23, 2019 Changes in this version + const LRUCacheSize + type Action struct + App *App + Log *log.Entry + func (action *Action) CoreQ() *core.Q + func (action *Action) EnsureHistoryFreshness() + func (action *Action) FullURL() *url.URL + func (action *Action) HistoryQ() *history.Q + func (action *Action) Prepare(w http.ResponseWriter, r *http.Request) + func (action *Action) ValidateCursorAsDefault() + func (action *Action) ValidateCursorWithinHistory() + type App struct + func AppFromContext(ctx context.Context) *App + func NewApp(config Config) *App + func (a *App) AuroraSession(ctx context.Context) *db.Session + func (a *App) Close() + func (a *App) CloseDB() + func (a *App) CoreQ() *core.Q + func (a *App) CoreSession(ctx context.Context) *db.Session + func (a *App) DeleteUnretainedHistory() error + func (a *App) GetRateLimiter() *throttled.HTTPRateLimiter + func (a *App) HistoryQ() *history.Q + func (a *App) IsHistoryStale() bool + func (a *App) Serve() + func (a *App) Tick() + func (a *App) UpdateHcNetCoreInfo() + func (a *App) UpdateLedgerState() + func (a *App) UpdateMetrics() + func (a *App) UpdateOperationFeeStatsState() + type AssetsAction struct + AssetCode string + AssetIssuer string + Page hal.Page + PagingParams db2.PageQuery + Records []assets.AssetStatsR + func (action *AssetsAction) JSON() error + func (action AssetsAction) Handle(w http.ResponseWriter, r *http.Request) + type Config struct + AuroraDBMaxIdleConnections int + AuroraDBMaxOpenConnections int + ConnectionTimeout time.Duration + CoreDBMaxIdleConnections int + CoreDBMaxOpenConnections int + CursorName string + DatabaseURL string + EnableAssetStats bool + EnableExperimentalIngestion bool + FriendbotURL *url.URL + HcNetCoreDatabaseURL string + HcNetCoreURL string + HistoryArchiveURLs []string + HistoryRetentionCount uint + Ingest bool + IngestFailedTransactions bool + IngestStateReaderTempSet string + LogFile string + LogLevel logrus.Level + LogglyTag string + LogglyToken string + MaxDBConnections int + MaxPathLength uint + NetworkPassphrase string + Port uint + RateLimitRedisKey string + RateQuota *throttled.RateQuota + RedisURL string + SSEUpdateFrequency time.Duration + SentryDSN string + SkipCursorUpdate bool + StaleThreshold uint + TLSCert string + TLSKey string + type DataShowAction struct + Address string + Data core.AccountData + Key string + func (action *DataShowAction) JSON() error + func (action *DataShowAction) Raw() error + func (action *DataShowAction) SSE(stream *sse.Stream) error + func (action DataShowAction) Handle(w http.ResponseWriter, r *http.Request) + type EffectIndexAction struct + AccountFilter string + LedgerFilter int32 + Ledgers *history.LedgerCache + OperationFilter int64 + Page hal.Page + PagingParams db2.PageQuery + Records []history.Effect + TransactionFilter string + func (action *EffectIndexAction) JSON() error + func (action *EffectIndexAction) SSE(stream *sse.Stream) error + func (action *EffectIndexAction) ValidateCursor() + func (action EffectIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type FixedPathIndexAction struct + Page hal.BasePage + Records []paths.Path + func (action *FixedPathIndexAction) JSON() error + func (action FixedPathIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type LedgerIndexAction struct + Page hal.Page + PagingParams db2.PageQuery + Records []history.Ledger + func (action *LedgerIndexAction) JSON() error + func (action *LedgerIndexAction) SSE(stream *sse.Stream) error + func (action LedgerIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type LedgerShowAction struct + Record history.Ledger + Sequence int32 + func (action *LedgerShowAction) JSON() error + func (action LedgerShowAction) Handle(w http.ResponseWriter, r *http.Request) + type MetricsAction struct + Snapshot map[string]interface{} + func (action *MetricsAction) JSON() error + func (action *MetricsAction) LoadSnapshot() + func (action MetricsAction) Handle(w http.ResponseWriter, r *http.Request) + type NotFoundAction struct + func (action *NotFoundAction) JSON() error + func (action NotFoundAction) Handle(w http.ResponseWriter, r *http.Request) + type NotImplementedAction struct + func (action *NotImplementedAction) JSON() error + func (action NotImplementedAction) Handle(w http.ResponseWriter, r *http.Request) + type OffersByAccountAction struct + Address string + Ledgers *history.LedgerCache + Page hal.Page + PageQuery db2.PageQuery + Records []core.Offer + func (action *OffersByAccountAction) JSON() error + func (action *OffersByAccountAction) SSE(stream *sse.Stream) error + func (action OffersByAccountAction) Handle(w http.ResponseWriter, r *http.Request) + type OperationFeeStatsAction struct + FeeMin int64 + FeeMode int64 + FeeP10 int64 + FeeP20 int64 + FeeP30 int64 + FeeP40 int64 + FeeP50 int64 + FeeP60 int64 + FeeP70 int64 + FeeP80 int64 + FeeP90 int64 + FeeP95 int64 + FeeP99 int64 + LastBaseFee int64 + LastLedger int64 + LedgerCapacityUsage string + func (action *OperationFeeStatsAction) JSON() error + func (action OperationFeeStatsAction) Handle(w http.ResponseWriter, r *http.Request) + type OperationIndexAction struct + AccountFilter string + IncludeFailed bool + IncludeTransactions bool + LedgerFilter int32 + Ledgers *history.LedgerCache + OnlyPayments bool + OperationRecords []history.Operation + Page hal.Page + PagingParams db2.PageQuery + TransactionFilter string + TransactionRecords []history.Transaction + func (action *OperationIndexAction) JSON() error + func (action *OperationIndexAction) SSE(stream *sse.Stream) error + func (action OperationIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type OperationShowAction struct + ID int64 + IncludeTransactions bool + Ledger history.Ledger + OperationRecord history.Operation + Resource interface{} + TransactionRecord *history.Transaction + func (action *OperationShowAction) JSON() error + func (action OperationShowAction) Handle(w http.ResponseWriter, r *http.Request) + type OrderBookShowAction struct + Buying xdr.Asset + Limit uint64 + Record core.OrderBookSummary + Resource aurora.OrderBookSummary + Selling xdr.Asset + func (action *OrderBookShowAction) JSON() error + func (action *OrderBookShowAction) LoadEvent() (sse.Event, error) + func (action *OrderBookShowAction) LoadQuery() + func (action *OrderBookShowAction) LoadRecord() + func (action *OrderBookShowAction) LoadResource() + func (action OrderBookShowAction) Handle(w http.ResponseWriter, r *http.Request) + type PathIndexAction struct + Page hal.BasePage + Query paths.Query + Records []paths.Path + func (action *PathIndexAction) JSON() error + func (action PathIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type RateLimitExceededAction struct + func (action RateLimitExceededAction) Handle(w http.ResponseWriter, r *http.Request) + func (action RateLimitExceededAction) ServeHTTP(w http.ResponseWriter, r *http.Request) + type RootAction struct + func (action *RootAction) JSON() error + func (action RootAction) Handle(w http.ResponseWriter, r *http.Request) + type TradeAggregateIndexAction struct + BaseAssetFilter xdr.Asset + CounterAssetFilter xdr.Asset + EndTimeFilter time.Millis + OffsetFilter int64 + Page hal.Page + PagingParams db2.PageQuery + Records []history.TradeAggregation + ResolutionFilter int64 + StartTimeFilter time.Millis + func (action *TradeAggregateIndexAction) JSON() error + func (action TradeAggregateIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type TradeIndexAction struct + AccountFilter string + BaseAssetFilter xdr.Asset + CounterAssetFilter xdr.Asset + HasBaseAssetFilter bool + HasCounterAssetFilter bool + OfferFilter int64 + Page hal.Page + PagingParams db2.PageQuery + Records []history.Trade + func (action *TradeIndexAction) JSON() error + func (action *TradeIndexAction) SSE(stream *sse.Stream) error + func (action TradeIndexAction) Handle(w http.ResponseWriter, r *http.Request) + type TransactionCreateAction struct + Resource aurora.TransactionSuccess + Result txsub.Result + TX string + func (action *TransactionCreateAction) JSON() error + func (action TransactionCreateAction) Handle(w http.ResponseWriter, r *http.Request) + type VaryByRemoteIP struct + func (v VaryByRemoteIP) Key(r *http.Request) string