anchor.diff:  
   %% @doc Generates a constraint for chef_type
   %% @end
  --spec search_type_constraint(Type :: binary()) -> TypeConstraint :: [byte(),...].
  +-spec search_type_constraint(Type :: atom()) -> TypeConstraint :: [byte(),...].
   search_type_constraint(Type) ->
  -    "X_CHEF_type_CHEF_X:" ++ binary_to_list(Type).
  +    "X_CHEF_type_CHEF_X:" ++ atom_to_list(Type).
   
   
   % /solr/select?
  
positive.code:     end.
  
  %% @doc Sends a "commit" message directly to Solr
  -spec solr_commit() -> ok | {error, term()}.
  solr_commit() ->
      solr_update("<?xml version='1.0' encoding='UTF-8'?><commit/>").
  
negative.code:     ok = solr_commit(),
      ok.
  
  %% @doc Delete all search index entries for a given
  %% organization and type.  Types are generally binaries or strings elsewhere in this
  %% module. We should think about converting the other APIs in this file to use atoms
  %% instead.
  %% Note: This omits solr_commit because of the high cost of that call in production.
  %% Some users will want to call the commit directly.
  %% @end
  -spec delete_search_db_by_type(OrgId :: binary(), Type :: atom()) -> ok.
  delete_search_db_by_type(OrgId, Type)
    when Type == client orelse Type == data_bag_item orelse
         Type == environment orelse Type == node orelse
         Type == role ->
      DeleteQuery = "<?xml version='1.0' encoding='UTF-8'?><delete><query>" ++
          search_db_from_orgid(OrgId) ++ " AND " ++
          search_type_constraint(Type) ++
          "</query></delete>",
      solr_update(DeleteQuery).
  
  
  %% Internal functions
  
  