mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-27 04:56:38 +00:00
Compare commits
2 Commits
1.16.2-s.2
...
1.16.2-s.2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6d7a19b0a0 | ||
|
|
6b3a6fa380 |
@@ -146,7 +146,7 @@ export async function flushSiteBandwidthToDb(): Promise<void> {
|
||||
// support UPDATE … FROM (VALUES …), letting us update the whole chunk
|
||||
// in a single query instead of N individual round-trips.
|
||||
const valuesList = chunk.map(([publicKey, { bytesIn, bytesOut }]) =>
|
||||
sql`(${publicKey}, ${bytesIn}, ${bytesOut})`
|
||||
sql`(${publicKey}::text, ${bytesIn}::real, ${bytesOut}::real)`
|
||||
);
|
||||
const valuesClause = sql.join(valuesList, sql`, `);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user