mjp0 / datagram-node

📡 Datagram is an open-source data platform that you can use to build secured & shareable p2p databases with anyone.

Home Page:https://datagramjs.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Implement index

mjp0 opened this issue · comments

commented

At the moment if you want to get the list of data you have in your datagram, you need to download everything in the datagram, and then get the data names. This works when you are running local datagrams but fails when you just want to see inside a remote datagram.

This can be solved by creating an index array to each datagram at key _index. Every time new data is stored, its key is appended into _index. Then list method can be refactored to fetch only _index key.


Deliverables

  • Implement indexer
  • Refactor list method