public static void storageSmokeTest(ViewContext context) {
    try {
      SmokeTestEntity entity = new SmokeTestEntity();
      entity.setData("42");
      DataStoreStorage storage = new DataStoreStorage(context);
      storage.store(entity);

      if (entity.getId() == null) throw new ServiceFormattedException("Ambari Views instance data DB doesn't work properly (auto increment id doesn't work)", null);
      int id = Integer.parseInt(entity.getId());
      SmokeTestEntity entity2 = storage.load(SmokeTestEntity.class, id);
      boolean status = entity2.getData().compareTo("42") == 0;
      storage.delete(SmokeTestEntity.class, id);
      if (!status) throw new ServiceFormattedException("Ambari Views instance data DB doesn't work properly", null);
    } catch (WebApplicationException ex) {
      throw ex;
    } catch (Exception ex) {
      throw new ServiceFormattedException(ex.getMessage(), ex);
    }
  }
Constructor
@param context View Context instance
contrib/views/pig/src/main/java/org/apache/ambari/view/pig/persistence/DataStoreStorage.java