The biggest Solana news today wasn’t Grayscale or Western Union
It was @heliuslabs making 493 billion transactions searchable by account at Web2 speed
IBRL, from writes to reads 🏎️
earlier today @heliuslabs launched a new RPC method, getTransactionsForAddress (gTFA)
let's talk about how it works under the hood
solana transactions typically reference 6-10 accounts (up to ~256)
when you query "get me the history of account X", you are asking the RPC to scan transactions and find the ones that include X in their list of accounts
this is essentially trying to find a needle in a haystack
you can't simply add a standard index on the "accounts" array at scale – databases struggle with indexing variable length arrays
the solution: we built our own index, with one entry per unique (transaction, account) pair
this is no small feat – there are ~493 billion transactions (and growing)
our index currently holds over 2.3 trillion (!) rows
despite the size, the P50 lookup time is ~8ms under production load
and we have many other indices to power lookups by slot, time, status, etc
all running on purpose-built bare metal hosts with petabytes of top-of-the line NVMEs, replicated across multiple regions
tldr – we suffered so you don't have to
enjoy
29.27 ألف
256
المحتوى الوارد في هذه الصفحة مُقدَّم من أطراف ثالثة. وما لم يُذكَر خلاف ذلك، فإن OKX ليست مُؤلِّفة المقالة (المقالات) المذكورة ولا تُطالِب بأي حقوق نشر وتأليف للمواد. المحتوى مٌقدَّم لأغراض إعلامية ولا يُمثِّل آراء OKX، وليس الغرض منه أن يكون تأييدًا من أي نوع، ولا يجب اعتباره مشورة استثمارية أو التماسًا لشراء الأصول الرقمية أو بيعها. إلى الحد الذي يُستخدَم فيه الذكاء الاصطناعي التوليدي لتقديم مُلخصَّات أو معلومات أخرى، قد يكون هذا المحتوى الناتج عن الذكاء الاصطناعي غير دقيق أو غير مُتسِق. من فضلك اقرأ المقالة ذات الصِلة بهذا الشأن لمزيدٍ من التفاصيل والمعلومات. OKX ليست مسؤولة عن المحتوى الوارد في مواقع الأطراف الثالثة. والاحتفاظ بالأصول الرقمية، بما في ذلك العملات المستقرة ورموز NFT، فيه درجة عالية من المخاطر وهو عُرضة للتقلُّب الشديد. وعليك التفكير جيِّدًا فيما إذا كان تداوُل الأصول الرقمية أو الاحتفاظ بها مناسبًا لك في ظل ظروفك المالية.


