public void persist(ConfigurationBranch config) {
    if (config == null) {
      throw new IllegalArgumentException("config cannot be null.");
    }
    String jsonRemote = remoteBundle.toJSONString();
    String jsonLocal = localBundle.toJSONString();
    Editor editor = config.edit();
    editor.putString("remote", jsonRemote);
    editor.putString("local", jsonLocal);
    editor.putString("syncID", syncID);

    // Synchronous.
    editor.commit();
    Logger.debug(
        LOG_TAG,
        "Persisted SynchronizerConfiguration. syncID: "
            + syncID
            + ", remoteBundle: "
            + remoteBundle
            + ", localBundle: "
            + localBundle);
  }