Skip to content
Open
Show file tree
Hide file tree
Changes from 53 commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
2b42b93
dag depth, markers, tests
bitcoin-coder-bob Feb 10, 2026
bed30a7
recursive CTE query for descendant markers, sweep test, prefetchVtxos…
bitcoin-coder-bob Feb 10, 2026
e8fbb86
testGetVtxoChainWithMarkerOptimization, linting
bitcoin-coder-bob Feb 10, 2026
e39e4d2
badger impl, migration file renames, marker_test.go
bitcoin-coder-bob Feb 10, 2026
94adccb
change vtxo table marker column to be JSONB to hold >=1 marker
bitcoin-coder-bob Feb 11, 2026
5c4ebc6
remove serivce.go markerStore nil checks, rearrange sql statements, lint
bitcoin-coder-bob Feb 12, 2026
7f613f1
swept column from vtxo table removed
bitcoin-coder-bob Feb 12, 2026
395e128
bulksweepmarkers, sweep all of a vtxo's markers
bitcoin-coder-bob Feb 12, 2026
cc93afb
bulk add new markers and vtxos
bitcoin-coder-bob Feb 12, 2026
9588705
new vtxos get markers set in AddVtxos
bitcoin-coder-bob Feb 12, 2026
18932e9
populate MarkerIds in getNewVtxosFromRound, createCheckpointSweepTask…
bitcoin-coder-bob Feb 12, 2026
56f6cd1
linted with go1.25.7
bitcoin-coder-bob Feb 12, 2026
c706f56
fix github action for linter version
bitcoin-coder-bob Feb 12, 2026
a88e895
github action linter to use latest golangci/golangci-lint-action@v8
bitcoin-coder-bob Feb 12, 2026
2a737f6
revert lint changes
bitcoin-coder-bob Feb 12, 2026
691480f
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Feb 12, 2026
bfa79c7
migration to ensure each vtxo has at least 1 marker, dust vtxos bulk …
bitcoin-coder-bob Feb 12, 2026
2fa7689
Tests
bitcoin-coder-bob Feb 12, 2026
bb6d7dc
more tests
bitcoin-coder-bob Feb 12, 2026
35c1944
20k depth test
bitcoin-coder-bob Feb 12, 2026
38a7945
more integration tests in service_test.go
bitcoin-coder-bob Feb 12, 2026
7d4d296
add marker for dust
bitcoin-coder-bob Feb 12, 2026
09f331d
safe copy, db tx usage, idx_marker_parent_markers index
bitcoin-coder-bob Feb 13, 2026
1122bd9
depthKnown, markersToMarshal fix
bitcoin-coder-bob Feb 13, 2026
bd5e93c
parentMarkerIds emply slice setting, test fix
bitcoin-coder-bob Feb 13, 2026
0046567
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Feb 16, 2026
307269e
lint fixes
bitcoin-coder-bob Feb 16, 2026
a6f0d8c
test optimizations, test comments
bitcoin-coder-bob Feb 17, 2026
fe8a755
sqlite json_each, badger touchups
bitcoin-coder-bob Feb 17, 2026
55618c4
cursor-based pagination for GetVtxoChain with lazy marker-window loading
bitcoin-coder-bob Feb 17, 2026
4dddd82
add end-to-end pagination tests and fix early termination bug
bitcoin-coder-bob Feb 17, 2026
49ed51c
Merge origin/master into bob/dag-1
bitcoin-coder-bob Feb 18, 2026
dc70231
make proto
bitcoin-coder-bob Feb 18, 2026
ae19758
Fix SweptAt timestamps, GetVtxosByArkTxid queries, and dust marker sweep
bitcoin-coder-bob Feb 23, 2026
d3de56e
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Feb 23, 2026
b7a8089
merge with master
bitcoin-coder-bob Feb 27, 2026
de7518f
merge with master to fix conflict in utils_test.go
bitcoin-coder-bob Feb 27, 2026
9463acb
make lint
bitcoin-coder-bob Mar 2, 2026
6905b83
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Mar 5, 2026
eabad6f
refactor marker logic into domain and carry depth via events
bitcoin-coder-bob Mar 16, 2026
678ca28
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Mar 18, 2026
fa0bf77
GetReadyUpdate return type fix
bitcoin-coder-bob Mar 18, 2026
3231064
log warning on marker window error
bitcoin-coder-bob Mar 19, 2026
86f9190
db migration to use milliseconds for swept_at
bitcoin-coder-bob Mar 19, 2026
ce2ef67
linting
bitcoin-coder-bob Mar 19, 2026
f13064c
optimize GetVtxoChain with marker-based bulk preloading (#973)
bitcoin-coder-bob Mar 20, 2026
2b8afb6
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Mar 20, 2026
f7cfde2
add benchmarks and weird-tree tests for GetVtxoChain
bitcoin-coder-bob Mar 23, 2026
8d8faba
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Apr 2, 2026
373eeec
lint
bitcoin-coder-bob Apr 2, 2026
453417e
use offchainTxCache to handle test reace condition
bitcoin-coder-bob Apr 2, 2026
69879d0
bulk-fetch offchain txs in walkVtxoChain to reduce DB round-trips (#1…
bitcoin-coder-bob Apr 15, 2026
40ff9f8
Merge branch 'master' into bob/dag-1
bitcoin-coder-bob Apr 16, 2026
7bb2a6a
fix badger fragile error matching
bitcoin-coder-bob Apr 16, 2026
a266382
fix marker sweep, SQLite atomicity, token TTL, and retry bounds
bitcoin-coder-bob Apr 16, 2026
b9f58d8
HMAC-sign pagination cursors to prevent auth bypass
bitcoin-coder-bob Apr 16, 2026
6833a6c
fix checkpoint sweep over-reach with per-outpoint tracking
bitcoin-coder-bob Apr 16, 2026
2ff4b78
fix benchmark metrics, SQL safety, and auth/marker edge cases
bitcoin-coder-bob Apr 17, 2026
30cc8c6
fix GetAllChildrenVtxos sibling over-reach and swept_vtxo down migrat…
bitcoin-coder-bob Apr 17, 2026
54924c0
fix hardcoded vout=0 when extracting leaf VTXO outpoints for sweep
bitcoin-coder-bob Apr 17, 2026
2d8c1ba
restore swept on rollback, fix isActive, document dual sweep path
bitcoin-coder-bob Apr 17, 2026
f6f3d65
Merge master into bob/dag-1
bitcoin-coder-bob Apr 27, 2026
e0d0c0e
Fix RepoManager interface stubs and test pointer dereference after ma…
bitcoin-coder-bob Apr 27, 2026
4bf8b90
dispatch batch update handler for non-ended rounds
bitcoin-coder-bob Apr 29, 2026
e8d55da
fix marker over-reach in batch sweep, add chain walk bound
bitcoin-coder-bob Apr 29, 2026
52ff7a2
drop WalletType from vtxo_chain_test, removed from InitArgs in master
bitcoin-coder-bob Apr 29, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions api-spec/openapi/swagger/ark/v1/indexer.openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,13 @@
"type": "string"
}
},
{
"name": "pageToken",
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "page.size",
"in": "query",
Expand Down Expand Up @@ -1052,6 +1059,9 @@
"page": {
"$ref": "#/components/schemas/IndexerPageRequest"
},
"pageToken": {
"type": "string"
},
"token": {
"type": "string",
"description": "Valid auth_token can also be used if the ownership has already been proved.\nA valid token obtained from GetVirtualTxs rpc can be recycled for this request."
Expand All @@ -1072,6 +1082,9 @@
"$ref": "#/components/schemas/IndexerChain"
}
},
"nextPageToken": {
"type": "string"
},
"page": {
"$ref": "#/components/schemas/IndexerPageResponse"
}
Expand Down Expand Up @@ -1461,6 +1474,10 @@
"type": "integer",
"format": "int64"
},
"depth": {
"type": "integer",
"format": "uint32"
},
"expiresAt": {
"type": "integer",
"format": "int64"
Expand Down
4 changes: 4 additions & 0 deletions api-spec/openapi/swagger/ark/v1/service.openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -1534,6 +1534,10 @@
"type": "integer",
"format": "int64"
},
"depth": {
"type": "integer",
"format": "uint32"
},
"expiresAt": {
"type": "integer",
"format": "int64"
Expand Down
4 changes: 4 additions & 0 deletions api-spec/openapi/swagger/ark/v1/types.openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,10 @@
"type": "integer",
"format": "int64"
},
"depth": {
"type": "integer",
"format": "uint32"
},
"expiresAt": {
"type": "integer",
"format": "int64"
Expand Down
3 changes: 3 additions & 0 deletions api-spec/protobuf/ark/v1/indexer.proto
Original file line number Diff line number Diff line change
Expand Up @@ -217,12 +217,14 @@ message GetVtxoChainRequest {
// A valid token obtained from GetVirtualTxs rpc can be recycled for this request.
string token = 4;
}
string page_token = 5;
}
message GetVtxoChainResponse {
repeated IndexerChain chain = 1;
IndexerPageResponse page = 2;
// Auth token can be used for other rpcs related to this vtxo/tx that require proof of ownership.
string auth_token = 3;
string next_page_token = 4;
}

message GetVirtualTxsRequest {
Expand Down Expand Up @@ -302,6 +304,7 @@ message IndexerVtxo {
string settled_by = 12;
string ark_txid = 13;
repeated IndexerAsset assets = 14;
uint32 depth = 15;
}

message IndexerAsset {
Expand Down
1 change: 1 addition & 0 deletions api-spec/protobuf/ark/v1/types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ message Vtxo {
string settled_by = 12;
string ark_txid = 13;
repeated Asset assets = 14;
uint32 depth = 15;
}

message Asset {
Expand Down
40 changes: 34 additions & 6 deletions api-spec/protobuf/gen/ark/v1/indexer.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 11 additions & 2 deletions api-spec/protobuf/gen/ark/v1/types.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docker-compose.regtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ services:
container_name: nbxplorer
ports:
- 32838:32838
image: nicolasdorier/nbxplorer:2.5.30
image: nicolasdorier/nbxplorer:2.5.30-1
environment:
- NBXPLORER_NETWORK=regtest
- NBXPLORER_CHAINS=btc
Expand Down
6 changes: 6 additions & 0 deletions internal/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -742,8 +742,14 @@ func (c *Config) IndexerService() (application.IndexerService, error) {
return nil, fmt.Errorf("failed to get server signing pubkey: %w", err)
}

var offchainTxCache ports.OffChainTxStore
if c.liveStore != nil {
offchainTxCache = c.liveStore.OffchainTxs()
}

return application.NewIndexerService(
c.repo, c.wallet, privkey, signerPubkey, c.IndexerExposure, c.IndexerAuthTokenExpiry,
offchainTxCache,
)
}

Expand Down
Loading
Loading