Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement persistent database #792

Open
thSoft opened this issue Mar 14, 2017 · 6 comments
Open

Implement persistent database #792

thSoft opened this issue Mar 14, 2017 · 6 comments

Comments

@thSoft
Copy link

thSoft commented Mar 14, 2017

It would be great if there was a persistent database that keeps its state between sessions.

@alexispurslane
Copy link

I'm new here, but I wonder if that's what @session is? It's docs are...sparse: http://docs.witheve.com/handbook/session/.

@cmontella
Copy link
Contributor

@ChristopherDumas

@session (like all Eve databases right now) is ephemeral, and will clear on a refresh of the browser or a restart of the Eve server.

In the runtime-refactor branch, we've departed with the idea of multiple databases, and instead we have a single database with namespacing conventions, so you can't put records and facts in different places and lose track of them. One of the most common bugs I encounter when writing programs is forgetting to reference the database in which the record I'm searching for resides.\

@thSoft

Thank you for the suggestion! As I alluded to in the response above, the runtime is undergoing a refactor, and we will be adding this feature to the runtime-refactor branch, which will eventually be merged into master. I'll keep this issue open to track the issue, and close it when it's ready.

@thSoft
Copy link
Author

thSoft commented Mar 16, 2017

@cmontella Great, I totally agree (see e.g. #537 :)).

@alexispurslane
Copy link

@cmontella That runtime refactor sounds sad, at least to me. It's your language, and I haven't done much in Eve yet so I don't know how much it hurts, but having multiple databases was one of the things I really liked about Eve's database paradigm. I'll just have to wait and see what the new setup looks like, I guess.

@cmontella
Copy link
Contributor

@ChristopherDumas

Multiple databases did seem like a good idea, which is why we went that way in the first place. But in practice, it just lead to more confusion than it was worth.

The problem solved by multiple databases was that of scoping/namespacing. It also allowed a degree of organization. We'd like to still preserve these properties of the language. But it introduced a problem of having to think about the location of records, in addition to their shape.

So let me ask you this: what specifically draws you to the idea of multiple databases? What do you think it will help you accomplish or make easier? I'm definitely interested in hearing your thoughts.

@alexispurslane
Copy link

I'd like to answer all those questions, but this is getting off-topic for this issue, so I'm creating a new issue for this. See: #800

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants