<commit_before>/**
 * Copyright (c) 2015 DataTorrent, Inc.
 * All rights reserved.
 */
package com.datatorrent.contrib.dimensions;

import java.io.Serializable;

import java.util.Map;
import java.util.Set;


import javax.validation.constraints.NotNull;

import com.google.common.annotations.VisibleForTesting;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;

import com.datatorrent.lib.appdata.schemas.*;
import com.datatorrent.lib.dimensions.AbstractDimensionsComputationFlexibleSingleSchema;
import com.datatorrent.lib.dimensions.DimensionsDescriptor;
import com.datatorrent.lib.dimensions.DimensionsEvent.Aggregate;

import com.datatorrent.api.Context.OperatorContext;

/**
 * This is a dimensions store which stores data corresponding to one {@link DimensionalSchema} into an HDHT bucket.
 * This operator requires an upstream dimensions computation operator, to produce {@link Aggregate}s with the same
 * link {@link DimensionalSchema} and schemaID.
 *
 * @displayName Simple App Data Dimensions Store
 * @category DT View Integration
 * @tags app data, dimensions, store
 */
public class AppDataSingleSchemaDimensionStoreHDHT extends AbstractAppDataDimensionStoreHDHT implements Serializable
{
  private static final long serialVersionUID = 201505130939L;
  /**
   * This is the id of the default bucket that data is stored into.
   */
  public static final long DEFAULT_BUCKET_ID = 0;
  /**
   * This is the JSON which defines this operator's {@link DimensionalConfigurationSchema}.
   */
  @NotNull
  private String configurationSchemaJSON;
  /**
   * This is the JSON which defines the schema stub for this operator's {@link DimensionalSchema}.
   */
  private String dimensionalSchemaStubJSON;
  /**
   * This operator's {@link DimensionalConfigurationSchema}.
   */
  @VisibleForTesting
  protected transient DimensionalConfigurationSchema configurationSchema;
  /**
   * This operator's {@link DimensionalSchema}.
   */
  protected transient DimensionalSchema dimensionalSchema;
  /**
   * The {@link schemaID} of for data stored by this operator.
   */
  private int schemaID = AbstractDimensionsComputationFlexibleSingleSchema.DEFAULT_SCHEMA_ID;<commit_msg>SPOI-5789 Making the AppDataSingleSchemaDimensionStoreHDHT not checkpointable within an application window.<commit_after>/**
 * Copyright (c) 2015 DataTorrent, Inc.
 * All rights reserved.
 */
package com.datatorrent.contrib.dimensions;

import java.io.Serializable;

import java.util.Map;
import java.util.Set;


import javax.validation.constraints.NotNull;

import com.google.common.annotations.VisibleForTesting;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;

import com.datatorrent.lib.appdata.schemas.*;
import com.datatorrent.lib.dimensions.AbstractDimensionsComputationFlexibleSingleSchema;
import com.datatorrent.lib.dimensions.DimensionsDescriptor;
import com.datatorrent.lib.dimensions.DimensionsEvent.Aggregate;

import com.datatorrent.api.Context.OperatorContext;
import com.datatorrent.api.annotation.OperatorAnnotation;

/**
 * This is a dimensions store which stores data corresponding to one {@link DimensionalSchema} into an HDHT bucket.
 * This operator requires an upstream dimensions computation operator, to produce {@link Aggregate}s with the same
 * link {@link DimensionalSchema} and schemaID.
 *
 * @displayName Simple App Data Dimensions Store
 * @category DT View Integration
 * @tags app data, dimensions, store
 */
@OperatorAnnotation(checkpointableWithinAppWindow = false)
public class AppDataSingleSchemaDimensionStoreHDHT extends AbstractAppDataDimensionStoreHDHT implements Serializable
{
  private static final long serialVersionUID = 201505130939L;
  /**
   * This is the id of the default bucket that data is stored into.
   */
  public static final long DEFAULT_BUCKET_ID = 0;
  /**
   * This is the JSON which defines this operator's {@link DimensionalConfigurationSchema}.
   */
  @NotNull
  private String configurationSchemaJSON;
  /**
   * This is the JSON which defines the schema stub for this operator's {@link DimensionalSchema}.
   */
  private String dimensionalSchemaStubJSON;
  /**
   * This operator's {@link DimensionalConfigurationSchema}.
   */
  @VisibleForTesting
  protected transient DimensionalConfigurationSchema configurationSchema;
  /**
   * This operator's {@link DimensionalSchema}.
   */
  protected transient DimensionalSchema dimensionalSchema;
  /**
   * The {@link schemaID} of for data stored by this operator.
   */
  private int schemaID = AbstractDimensionsComputationFlexibleSingleSchema.DEFAULT_SCHEMA_ID;
{'fraction_non_alphanumeric': 0.0799566630552546, 'fraction_numerical': 0.008234019501625136, 'mean_word_length': 5.033986928104575, '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': '685263', 'n_tokens_mistral': 1256, 'n_tokens_neox': 1211, 'n_words': 374}