class_docstr: A **State Backend** defines how the state of a streaming application is stored locally within
  the cluster. Different state backends store their state in different fashions, and use different
  data structures to hold the state of running applications.
  
  For example, the :class:`HashMapStateBackend` keeps working state in the memory of the
  TaskManager. The backend is lightweight and without additional dependencies.
  
  The :class:`EmbeddedRocksDBStateBackend` keeps working state in the memory of the TaskManager
  and stores state checkpoints in a filesystem(typically a replicated highly-available filesystem,
  like `HDFS <https://hadoop.apache.org/>`_, `Ceph <https://ceph.com/>`_,
  `S3 <https://aws.amazon.com/documentation/s3/>`_, `GCS <https://cloud.google.com/storage/>`_,
  etc).
  
  The :class:`EmbeddedRocksDBStateBackend` stores working state in an embedded
  `RocksDB <http://rocksdb.org/>`_, instance and is able to scale working state to many
  terrabytes in size, only limited by available disk space across all task managers.
  
  **Raw Bytes Storage and Backends**
  
  The :class:`StateBackend` creates services for *raw bytes storage* and for *keyed state*
  and *operator state*.
  
  The `org.apache.flink.runtime.state.AbstractKeyedStateBackend and
  `org.apache.flink.runtime.state.OperatorStateBackend` created by this state backend define how
  to hold the working state for keys and operators. They also define how to checkpoint that
  state, frequently using the raw bytes storage (via the
  `org.apache.flink.runtime.state.CheckpointStreamFactory`). However, it is also possible that
  for example a keyed state backend simply implements the bridge to a key/value store, and that
  it does not need to store anything in the raw byte storage upon a checkpoint.
  
  **Serializability**
  
  State Backends need to be serializable(`java.io.Serializable`), because they distributed
  across parallel processes (for distributed execution) together with the streaming application
  code.
  
  Because of that, :class:`StateBackend` implementations are meant to be like *factories* that
  create the proper states stores that provide access to the persistent storage and hold the
  keyed- and operator state data structures. That way, the State Backend can be very lightweight
  (contain only configurations) which makes it easier to be serializable.
  
  **Thread Safety**
  
  State backend implementations have to be thread-safe. Multiple threads may be creating
  streams and keyed-/operator state backends concurrently.
class_docstr_tok: ["A","*","*","State","Backend","*","*","defines","how","the","state","of","a","streaming","application","is","stored","locally","within","the","cluster",".","Different","state","backends","store","their","state","in","different","fashions",",","and","use","different","data","structures","to","hold","the","state","of","running","applications",".","For","example",",","the",":","class",":","`","HashMapStateBackend","`","keeps","working","state","in","the","memory","of","the","TaskManager",".","The","backend","is","lightweight","and","without","additional","dependencies",".","The",":","class",":","`","EmbeddedRocksDBStateBackend","`","keeps","working","state","in","the","memory","of","the","TaskManager","and","stores","state","checkpoints","in","a","filesystem","(","typically","a","replicated","highly-available","filesystem",",","like","`","HDFS","<","https",":","\/\/hadoop.apache.org\/",">","`","_",",","`","Ceph","<","https",":","\/\/ceph.com\/",">","`","_",",","`","S3","<","https",":","\/\/aws.amazon.com\/documentation\/s3\/",">","`","_",",","`","GCS","<","https",":","\/\/cloud.google.com\/storage\/",">","`","_",",","etc",")",".","The",":","class",":","`","EmbeddedRocksDBStateBackend","`","stores","working","state","in","an","embedded","`","RocksDB","<","http",":","\/\/rocksdb.org\/",">","`","_",",","instance","and","is","able","to","scale","working","state","to","many","terrabytes","in","size",",","only","limited","by","available","disk","space","across","all","task","managers",".","*","*","Raw","Bytes","Storage","and","Backends","*","*","The",":","class",":","`","StateBackend","`","creates","services","for","*","raw","bytes","storage","*","and","for","*","keyed","state","*","and","*","operator","state","*",".","The","`","org.apache.flink.runtime.state.AbstractKeyedStateBackend","and","`","org.apache.flink.runtime.state.OperatorStateBackend","`","created","by","this","state","backend","define","how","to","hold","the","working","state","for","keys","and","operators",".","They","also","define","how","to","checkpoint","that","state",",","frequently","using","the","raw","bytes","storage","(","via","the","`","org.apache.flink.runtime.state.CheckpointStreamFactory","`",")",".","However",",","it","is","also","possible","that","for","example","a","keyed","state","backend","simply","implements","the","bridge","to","a","key\/value","store",",","and","that","it","does","not","need","to","store","anything","in","the","raw","byte","storage","upon","a","checkpoint",".","*","*","Serializability","*","*","State","Backends","need","to","be","serializable","(","`","java.io.Serializable","`",")",",","because","they","distributed","across","parallel","processes","(","for","distributed","execution",")","together","with","the","streaming","application","code",".","Because","of","that",",",":","class",":","`","StateBackend","`","implementations","are","meant","to","be","like","*","factories","*","that","create","the","proper","states","stores","that","provide","access","to","the","persistent","storage","and","hold","the","keyed-","and","operator","state","data","structures",".","That","way",",","the","State","Backend","can","be","very","lightweight","(","contain","only","configurations",")","which","makes","it","easier","to","be","serializable",".","*","*","Thread","Safety","*","*","State","backend","implementations","have","to","be","thread-safe",".","Multiple","threads","may","be","creating","streams","and","keyed-\/operator","state","backends","concurrently","."]
code: def __init__(self, j_state_backend):
      self._j_state_backend = j_state_backend
  
imports: from abc import ABCMeta
  from enum import Enum
  from py4j.java_gateway import get_java_class
  from typing import List, Optional
  from pyflink.java_gateway import get_gateway
  from pyflink.util.java_utils import load_java_class
label_desc: Use image node_id 1 to create a new StateBackend object from inherited base classes: object with example: obj = StateBackend(j_state_backend)