openappjs / core

8 stars 0 forks source link

question: immutable keys? #1

Open dominictarr opened 10 years ago

dominictarr commented 10 years ago

reading through your bullet points, i was very happy to see you plan immutable data. will you use the hash of the object as keys? that is a very simple way to ensure data is not only immutable but also validatable.

ahdinosaur commented 10 years ago

using the hash of the object as immutable keys sounds like a great strategy. :+1:

as it may be relevant, i'll try and provide some missing context as to how i see OpenApp.js working to fulfill it's charter:

so with this in mind, secure-scuttlebutt and related modules fit really well to meet the "data subsystem" features of the stack. as you already are, feel free to direct the flow of the "data subsystem" as you wish with awesome modules. :) i'll add "validatable data" as a feature requirement of OpenApp.js.

for contextual completeness, the other possible "subsystems" of the stack that i'm aware of so far: the "view subsystem" of mercury and the "controller subsystem" of graft.

back to the issue at hand, i'm interested to see how immutable keys will work in practice. for example, what do we do when we want to use semantic keys with meaning? is the answer to have another object with its own immutable key that maps the semantic keys to the immutable keys? in general, i think the best way to answer questions of uncertainty is to experiment with applications that increase our understanding of these ideas in practice, so i'll try to experiment with writing something that uses secure-scuttlebutt and mercury, especially as i may now have more exploration and experimentation time.

dominictarr commented 10 years ago

Ah good. yeah - it will be something like that. Actually I have an idea for this that I plan to implement soon. I have some ideas about how something like this would work over here: https://github.com/dominictarr/cyphernet

Although cyphernet left a lot of details unspecified and I later decided that the approach I am now using in secure-scuttlebutt although untimately less flexible was also more simple and so more viable to begin with.

dominictarr commented 10 years ago

there is quite a bit of discussion in the issues about how various aspects would work.