The name registry is essential in allowing protected public access to unforgeable names. For testnet, we are planning on supporting UUID registration and pubkey registration.
Registration examples
For UUID registration, an example registration might look like the following:
...
Here the user can predict the uri that will be returned: `rho:pubkey:ed25519:<blake2b256hash of pubKey>`
, However, we still return it for 2 reasons: 1. The user might want to rely on it being registered. 2. For api consistency.
Lookup examples
UUID based lookup example
...
Code Block |
---|
new r(`rho:registry`), threeXret, print in { [r, "lookup"]!(`rho:pubkey:ed25519:<pubkey hash computed above>`, *threeXret) | for (threeX <- threeXret) { threeX!(7, print) } } |
Registry design
Lookup Commutativity
I expect that registry lookups will be very common, and so it would be great for block commutativity if we special cased writes to the registry lookup, as two lookups commute with each other as long as the registry hasn't been modified.
Registry Scaling
It should be clear that we can't store the registry as a single giant rholang map. Instead we will store it as a trie using tagged maps as fanout nodes, With UUID's and pubkey hashes, we should get rather speedy divergence. I think map entries per byte is a good initial guess.
...