sqldb: rename ExecutePagedQuery to ExecuteBatchQuery

We rename this helper along the config types & helper types for it
because the word "page" is used more often in the context of paging
through results using an offset and limit whereas this helper is
specifically used to split up the slice in queries of the form
"WHERE x in []slice". We do this rename so that there is mimimal
confusion in contexts where we use batching along with actual paging.

The config struct is also renamed to QueryConfig in preparation for it
holding more config options.
This commit is contained in:
Elle Mouton committed 2025-07-31 15:32:53 +02:00
1 parent b5c290d90f
commit a6248872cb
8 files changed
+105 -95

No files matched your search

+2 -2
View File
@@ -27,8 +27,8 @@ func NewTestDBFixture(_ *testing.T) *sqldb.TestPgFixture {
func NewTestDBWithFixture(t testing.TB, _ *sqldb.TestPgFixture) V1Store {
store, err := NewSQLStore(
&SQLStoreConfig{
ChainHash: *chaincfg.MainNetParams.GenesisHash,
PaginationCfg: sqldb.DefaultPagedQueryConfig(),
ChainHash: *chaincfg.MainNetParams.GenesisHash,
QueryCfg: sqldb.DefaultQueryConfig(),
}, newBatchQuerier(t),
)
require.NoError(t, err)