Conversation
dev/src/user.clj
Outdated
| :fluree/connection {:method :remote | ||
| :servers "http://localhost:58090"} | ||
| :fluree/consensus {:consensus-type :none}}) | ||
| (defn load-config |
There was a problem hiding this comment.
Some of this functionality will be added in the config branch when it's ready. I'm working on validation now, but I hope to be able to open a pr today.
There was a problem hiding this comment.
Ok, happy to adjust. Just working on REPL setup with the recent changes, and making sure multi-server raft is still working well, which is the more complex REPL setup.
There was a problem hiding this comment.
I opened #78 to store config in JSON. It might be easier to base this work off of that branch. It's also easier to do merges of configs because we don't have to worry about dissocing irrelevant keys (if you want to replace standalone with raft, for example). though that code isn't there yet, it will be easy to add when we need it.
| (def server-3 "/ip4/127.0.0.1/tcp/62073") | ||
| (def servers-str (str/join "," [server-1 server-2 server-3])) | ||
|
|
||
| (def raft-single-server |
There was a problem hiding this comment.
I think this stuff could be stored in resource files on the classpath, just like we do the main config. We could add a development resource path under dev/resources and call those files dev-server-1.edn (and hopefully very soon ".json"), etc and build out functions to merge or override configs in the fluree.server.system (and, hopefully very soon, the fluree.server.config) namespace. That would make it more robust and also more like what we'll do in production.
This adds some simple REPL startup back to the user namespace, and fixes the http-api calls namespace used for issuing/debugging http calls to the server from the REPL.
I wanted to make sure how this is done makes sense to everyone.
The query-server config has to get re-tested with the changes, and I plan to add a config to startup a query-server only. I don't think anyone has tried that in a while and it doesn't appear the config as it stands is current for that purpose.
I also plan to have a 3-server raft config out of the box startup function similar to what we used to have.