Proto commits in stephenh/mirror

These 24 commits are when the Protocol Buffers files have changed:

Commit:0064f79
Author:Stephen Haberman

Use semi-colons.

The documentation is generated from this commit.

Commit:5c9b977
Author:Stephen Haberman

Split prevoius --debug into --debug-all/--debug-prefixes options. The old option was confusing because running just `--debug` is a fairly common idiom but, in the case of mirror, it wouldn't do anything because it was seen as no prefixes being passed. Now it should be more explicit which to use, and when to pass paths. Also added a section to the readme about the help sections.

Commit:64ac8a7
Author:Stephen Haberman
Committer:Stephen Haberman

Move time check to it's own RPC call. I was getting a lot of "~500ms out of sync". My guess is that the serde of ~30,000 Updates to the wire meant the time between the System.currentTimeMillis to request actually sent was fairly large.

Commit:0f33bfa
Author:Stephen Haberman
Committer:Stephen Haberman

Add a version check between the server/client.

Commit:a86e671
Author:Stephen Haberman

Check for >500ms drift between the client and server. If the clocks are too much out of sync, weirdness will result, where one-side thinks it's side is newer when it's really not. In theory should also add some safeguards to prevent mirror from ever truncating files, when these sort of bugs/boundary cases happen. (Which for me is basically never, but it's still a bad thing when it does happen.) Also should add a unit test for this. Fixes #4.

Commit:b78583b
Author:Stephen Haberman

Give a nice error message if the remote path does not exist. This avoids a very unintuitive experience where the server is trying to create paths that look valid, e.g. /Users/you/.../, but on the server, e.g. Linux, the path should be /home/you/.../. Also add a note in the readme and clarifications on relative vs. absolute paths in the help docs.

Commit:1307c58
Author:Stephen Haberman
Committer:Stephen Haberman

Have server close previous sessions for the same client/path id. Hopefully this will fix stale sessions getting held on to in the server after multiple client reconnects.

Commit:ed2c017
Author:Stephen Haberman
Committer:Stephen Haberman

Track whether files are executable. Currently just using a "boolean executable" flag on the Update object; in theory passing the entire mode int would have more fidelity, as then could mark things as group/other executable on the other side. But, dunno, keeping it simple for now.

Commit:88e382d
Author:Stephen Haberman

Add config option to debug misbehaving prefixes.

Commit:adc8a97
Author:Stephen Haberman

Add --include/--exclude flags for adding extra patterns. Also added a -li flag for getting the old defaults that I personally use. This can probably go away once a config file is supported instead (i.e. I'm being lazy and don't want to type out a lot of command line arguments each time).

Commit:386cbd6
Author:Stephen Haberman

Initial start of connection detection. Needs tests.

Commit:3233e9c
Author:Stephen Haberman

Allow the MirrorServer to juggle multiple sessions.

Commit:7aee684
Author:Stephen Haberman
Committer:Stephen Haberman

Large, ugly refactoring that fully uses the UpdateTreeDiff approach.

Commit:ea4f20f
Author:Stephen Haberman

UpdateTree/TreeDiff fairly completes, handles changing file/dir/symlink types.

Commit:8e4b8fa
Author:Stephen Haberman

Sync directories as well. I was going to skip this, but turns out Eclipse will give a compile error if it has a directory configured as a source folder, and that directory is missing.

Commit:8bbbb4b
Author:Stephen Haberman

Add seed flag for updates we don't need to log.

Commit:0cff02c
Author:Stephen Haberman

Rename Mirror.Connect -> Mirror.StreamUpdates.

Commit:cae06f5
Author:Stephen Haberman

Basic support for symlinks.

Commit:10b7400
Author:Stephen Haberman

Extract out MirrorSession and put initial sync into place.

Commit:edfc5f1
Author:Stephen Haberman

Remove unused Empty type.

Commit:894810b
Author:Stephen Haberman
Committer:Stephen Haberman

Basic two-way sync is working.

Commit:175b339
Author:Stephen Haberman

Use one BlockingQueue for both remote and local changes. This makes the "wait for something interesting to happen" logic in the SyncLogic much easier, as we can block on just the one BlockingQueue instead of polling multiple queues for work.

Commit:3cefbe0
Author:Stephen Haberman

Some basic sync logic with naive data structures.

Commit:ba453ea
Author:Stephen Haberman

Working toy server/client.