Nicholas Kariniemi
4da9e8a617
Support more than one grub list
...
- Connecting to / redirects to /<random string>
- Connecting to /:list-name connects users to the list
:list-name. Changes are synced only with this list.
- A cookie saves the last list visited, so future / visits go to last list
2015-12-17 00:40:51 +02:00
Nicholas Kariniemi
81f4a47d84
Catch all errors in clicking in e2e test
2015-12-11 16:35:50 +02:00
Nicholas Kariniemi
7513ed471e
Add end-to-end test for production (with manual verification)
2015-12-11 00:08:04 +02:00
Nicholas Kariniemi
4d0d92b188
Remove websocket logging
2015-12-10 23:38:15 +02:00
Nicholas Kariniemi
df09addaa4
Remove unused dependencies
2015-12-10 23:37:29 +02:00
Nicholas Kariniemi
928baf1439
Separate server and command line options
2015-12-10 23:31:19 +02:00
Nicholas Kariniemi
b31489b2b8
Working n-way client sync with Datomic
...
- Based on latest CSP specification
- Also added end-to-end test for eventual consistency
2015-12-10 23:31:19 +02:00
Nicholas Kariniemi
798f1a5891
Working sync for single client (no changes from others)
2015-11-20 02:14:07 -05:00
Nicholas Kariniemi
a8d8ae56c5
Rework sync - client reworked, wip
2015-11-19 23:33:30 -05:00
Nicholas Kariniemi
838e6497d4
Correct fetching of database values
...
The existing way did not work for local database for some reason. The
existing approach tried to fetch all attributes for a given
entity. We now specifically fetch the attributes we want for an
entity, which is better anyway.
2015-11-17 23:01:18 -05:00
Nicholas Kariniemi
cec0060984
db - wip
2015-08-10 06:45:09 +03:00
Nicholas Kariniemi
d71f9260e8
Rework sync - also actually remove removed items
2015-07-17 00:36:12 +03:00
Nicholas Kariniemi
755d06f32b
Rework sync - wip
...
- Fetch full sync state from database, save upsert changes to database
2015-07-17 00:25:24 +03:00
Nicholas Kariniemi
8b11c119f2
Separate server and client syncing
...
- They vary in important ways anyway so it's more clear this way
2015-07-15 10:39:29 +03:00
Nicholas Kariniemi
455cf54bc9
Add another short delay to make async sync test pass
2015-07-05 22:09:42 +03:00
Nicholas Kariniemi
1260c4418c
Report sync differences in failed tests more explicitly
2015-07-05 22:02:57 +03:00
Nicholas Kariniemi
3c96ea5fbf
Add back midje and remove unused test
2015-07-05 21:59:17 +03:00
Nicholas Kariniemi
6ca589e3e6
Update Om to fix production build issues
2015-07-05 10:30:21 +03:00
Nicholas Kariniemi
9e6d900596
Hard-code database schema in database namespace
...
- Loading it separately doesn't make sense for e.g. production builds.
2015-07-04 23:01:19 +03:00
Nicholas Kariniemi
90e512d59d
Minor cleanup of db code
2015-07-04 22:33:36 +03:00
Nicholas Kariniemi
efbc29b0ad
Use (possibly persistent) database URI from env var
2015-07-04 22:23:16 +03:00
Nicholas Kariniemi
c1e0dfbf0b
Switch to Datomic for storage (not persistent)
...
- Still not taking advantage of Datomic features but using it as a
simple dump for Clojure data structures.
2015-07-04 22:22:47 +03:00
Nicholas Kariniemi
fdd9baf23b
Use new reader conditionals and remove cljx deps
2015-07-02 20:25:28 +03:00
Nicholas Kariniemi
cc3dbdca62
Remove dead code (mostly unused requires)
2015-06-16 20:03:32 +03:00
Nicholas Kariniemi
f7b79a5e2a
Fix bug where grubs/recipes could not be deleted
...
- Fixed by using keywords as map keys client-side. Monger "keywordizes"
keys by default and it's easier to change client side than to remove
that behavior.
2015-06-16 19:57:41 +03:00
Nicholas Kariniemi
021ec1b531
Use /ws path for websocket connections
...
- Less confusion around upgrading HTTP connections to WebSocket
2015-05-01 08:56:37 +03:00
Nicholas Kariniemi
1eb7136d27
Use relative paths for websocket connection
2015-05-01 08:46:02 +03:00
Nicholas Kariniemi
10148897c8
Use relative paths for static files
2015-04-30 23:38:15 +03:00
Nicholas Kariniemi
ab67f02172
Use ws or wss based on location protocol
2015-04-30 23:31:32 +03:00
Nicholas Kariniemi
90d7ee91ca
Minor cleanup in server core
2015-03-14 13:06:58 +02:00
Nicholas Kariniemi
830451372a
Build releases via lein uberjar
...
- Run scripts/build.sh to build JAR from scratch.
- Added better fix for lein cljx/reloaded workflow conflict
2014-11-29 16:22:15 +02:00
Nicholas Kariniemi
414dceec8b
Sort recipes by name
2014-11-24 16:26:34 +02:00
Nicholas Kariniemi
9e662c49b2
Default to 8 rows in directions text areas
...
Better: resize based on number of rows it takes
2014-10-26 09:30:11 +02:00
Nicholas Kariniemi
0e2f13d63d
Add directions to recipes
2014-10-26 08:57:08 +02:00
Nicholas Kariniemi
f8af086c19
Update unit/integration tests for sync
...
Cheat slightly on the synchronization test by manually passing in the
new server state. The problem is that new server states are detected
outside of the sync algorithm.
2014-10-25 22:21:55 +03:00
Nicholas Kariniemi
412bf29f57
Close up client channels properly on disconnect
2014-10-25 22:15:43 +03:00
Nicholas Kariniemi
5ee40a6471
Use version numbers instead of timestamps
...
Also:
- Don't acknowledge changes sent from the server to the client.
- Only send one message at a time to the server.
All of these changes bring this more in line with the differential sync paper.
2014-10-25 19:31:14 +03:00
Nicholas Kariniemi
79e64596ae
Add back sync integration tests
2014-10-21 23:26:27 +03:00
Nicholas Kariniemi
8fe22b9a52
Use timestamp tags instead of hashes
...
- Hashing was slow and we weren't using the hash properties much anyway
2014-10-21 23:25:42 +03:00
Nicholas Kariniemi
19ca650078
Fix tests - sync integration tests commented out
2014-10-19 11:49:02 +03:00
Nicholas Kariniemi
9591e9fd93
Rename state <--> sync namespaces
2014-10-19 10:53:14 +03:00
Nicholas Kariniemi
e14b3d2a29
Optimization: don't set grub/recipe state if state is unchanged
2014-10-15 22:51:53 +03:00
Nicholas Kariniemi
78d5617356
Keep state history with state in one atom
2014-10-15 22:14:32 +03:00
Nicholas Kariniemi
e5309fcd69
Correct use of swap!
2014-10-15 21:26:28 +03:00
Nicholas Kariniemi
0bf8344c62
Reset state on full sync
2014-10-15 21:22:53 +03:00
Nicholas Kariniemi
96dd93309d
Merge branch 'master' of github.com:nicholaskariniemi/grub
2014-10-15 21:06:11 +03:00
Nicholas Kariniemi
8dbb410667
Bounce favicon requests
2014-10-15 21:05:07 +03:00
Nicholas Kariniemi
fd249cefca
Use swap! in diff handling to update state
...
- Ensures state updates always use the current state as a basis.
2014-10-15 14:46:12 +03:00
Nicholas Kariniemi
dd5bf7a53a
Clean up state loop
2014-10-15 11:07:55 +03:00
Nicholas Kariniemi
f496fb51e5
Pull state history into state handler loop
...
- This is incidental complexity and other code doesn't need to know
about it
2014-10-14 22:49:04 +03:00