   end
 
   def handle_info({:DOWN, _ref, :process, pid, _},
-                  __MODULE__.State[interval: i, children: c] = state) do
-    [{^pid, child_interval}] = :ets.lookup(c, pid)
+                  __MODULE__.State[clock: clock, children: c] = state) do
+    [{^pid, child_clock}] = :ets.lookup(c, pid)
     :ets.delete(c, pid)
-    :ets.delete(c, child_interval)
-    new_interval = ITC.join(i, child_interval)
-    state = state.interval(new_interval)
+    :ets.delete(c, child_clock)
+    new_clock = ITC.join(clock, child_clock)
+    state = state.clock(new_clock)
     {:noreply, state}
   end  
 
   @spec execute(pid, Genomu.key, Genomu.command, Keyword.t) :: term
   defcall execute(key, cmd, options), state: State[] = state do
-    interval = next_interval(state.interval, cmd)
+    clock = next_clock(state.clock, cmd)
     cell = {key, state.lookup(key)}
-    revision = ITC.encode_binary(interval)
+    revision = ITC.encode_binary(clock)
     coord_options = [cell: cell, command: cmd, revision: revision] |> 
                     Keyword.merge(options)
     result = Genomu.Coordinator.run(coord_options)
-    state = memoize(key, cmd, interval, state)
+    state = memoize(key, cmd, clock, state)
     {:reply, result, state}
   end
 
   @spec commit(pid | atom) :: :ok | {:error, reason :: term}
-  defcall commit, state: State[parent: parent, interval: i] = state do
-    update(parent, self, i)
-    {:reply, :ok, state}
+  defcall commit, state: State[parent: parent, clock: clock, log: log] = state do
+    clock = sync(parent, clock)
+    update(parent, self, clock)
+    {:reply, :ok, state.clock(clock)}
   end
 
   @spec stop(pid | atom) :: :ok

  end

  @spec start_link(root :: atom | boolean, parent :: nil | pid | atom, interval :: ITC.t) :: {:ok, pid} | {:error, reason :: term}
  def start_link(false, parent, interval) do
    :gen_server.start_link(__MODULE__, {false, parent, interval}, [])
  end
  def start_link(true, parent, interval) do
    :gen_server.start_link(__MODULE__, {true, parent, interval}, [])
  end
  def start_link(name, parent, interval) do
    :gen_server.start_link({:local, name}, __MODULE__, {true, parent, interval}, [])
  end

  defrecord State, root: false, parent: nil,
                   interval: nil,
                   snapshot: nil, children: nil do

    record_type root: boolean, parent: nil | pid | atom,
                interval: nil | ITC.t,
                snapshot: nil | :ets.tid, children: nil | :ets.tid

    def blank(opts) do
      snapshot = :ets.new(__MODULE__.Snapshot, [:ordered_set])

  @spec fork(pid | atom, root :: atom | boolean) :: ITC.t
  def fork(server), do: fork(server, false)

  defcall fork(root), state: State[clock: clock, children: c] = state do
    {new_clock, channel_clock} = ITC.fork(clock)
    {:ok, channel} = :supervisor.start_child(Genomu.Sup.Channels, [root, self, channel_clock])
    Process.monitor(channel)
    :ets.insert(c, [{channel, channel_clock},
                    {channel_clock, channel}])
    state = state.clock(new_clock)
    {:reply, {:ok, channel}, state}
  end

  @spec sync(pid | atom, ITC.t) :: ITC.t
  defcall sync(clock0), state: State[clock: clock] = state do
    new_clock = ITC.join(clock, clock0)
    {clock1, clock2} = ITC.fork(new_clock)
    {:reply, clock2, state.clock(clock1)}
  end

  defcast update(channel, new_clock), state: State[children: c] = state do
    case :ets.lookup(c, channel) do
      [{^channel, clock}] ->
        :ets.insert(c, [{channel, new_clock}, {new_clock, channel}])
        :ets.delete(c, clock)
      [] -> 
        :ok # TODO: log a warning?
    end
