<commit_before>package water.api;

import water.UKV;
import water.Value;
import water.Futures;

import com.google.gson.JsonObject;

public class Remove extends Request {
  @Override public RequestServer.API_VERSION[] supportedVersions() { return SUPPORTS_V1_V2; }

  protected final H2OExistingKey _key = new H2OExistingKey(KEY);

  @Override
  protected Response serve() {
    Value v = _key.value();

    try {
      UKV.remove(v._key);       // Standard blocking remove
    } catch( Exception e ) {
      return Response.error(e.getMessage());
    }

    JsonObject response = new JsonObject();
    response.addProperty(KEY, _key.toString());
    return Response.redirect(response, StoreView.class, null);
  }
}
<commit_msg>One more Lockable remove<commit_after>package water.api;

import water.Futures;
import water.Lockable;
import water.UKV;
import water.Value;

import com.google.gson.JsonObject;

public class Remove extends Request {
  @Override public RequestServer.API_VERSION[] supportedVersions() { return SUPPORTS_V1_V2; }

  protected final H2OExistingKey _key = new H2OExistingKey(KEY);

  @Override
  protected Response serve() {
    Value v = _key.value();

    try {
      if( v.isLockable() ) Lockable.delete(v._key);
      else UKV.remove(v._key);  // Standard blocking remove
    } catch( Exception e ) {
      return Response.error(e.getMessage());
    }

    JsonObject response = new JsonObject();
    response.addProperty(KEY, _key.toString());
    return Response.redirect(response, StoreView.class, null);
  }
}

{'fraction_non_alphanumeric': 0.11038961038961038, 'fraction_numerical': 0.005194805194805195, 'mean_word_length': 3.8459119496855347, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '912107', 'n_tokens_mistral': 479, 'n_tokens_neox': 472, 'n_words': 117}