Class MemcachedReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>

java.lang.Object
io.datarouter.storage.node.BaseNode<PK,​D,​F>
io.datarouter.storage.node.type.physical.base.BasePhysicalNode<PK,​D,​F>
io.datarouter.client.memcached.node.MemcachedReaderNode<PK,​D,​F>
All Implemented Interfaces:
io.datarouter.storage.node.Node<PK,​D,​F>, io.datarouter.storage.node.op.NodeOps<PK,​D>, io.datarouter.storage.node.op.raw.read.MapStorageReader<PK,​D>, io.datarouter.storage.node.op.raw.read.TallyStorageReader<PK,​D>, io.datarouter.storage.node.type.physical.PhysicalNode<PK,​D,​F>, java.lang.Comparable<io.datarouter.storage.node.Node<PK,​D,​F>>
Direct Known Subclasses:
MemcachedNode

public class MemcachedReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>
extends io.datarouter.storage.node.type.physical.base.BasePhysicalNode<PK,​D,​F>
implements io.datarouter.storage.node.op.raw.read.MapStorageReader<PK,​D>, io.datarouter.storage.node.op.raw.read.TallyStorageReader<PK,​D>
  • Nested Class Summary

    Nested classes/interfaces inherited from interface io.datarouter.storage.node.op.raw.read.MapStorageReader

    io.datarouter.storage.node.op.raw.read.MapStorageReader.MapStorageReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>, io.datarouter.storage.node.op.raw.read.MapStorageReader.PhysicalMapStorageReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>

    Nested classes/interfaces inherited from interface io.datarouter.storage.node.op.raw.read.TallyStorageReader

    io.datarouter.storage.node.op.raw.read.TallyStorageReader.PhysicalTallyStorageReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>, io.datarouter.storage.node.op.raw.read.TallyStorageReader.TallyStorageReaderNode<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>,​F extends io.datarouter.model.serialize.fielder.DatabeanFielder<PK,​D>>
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected io.datarouter.storage.client.ClientId clientId  
    protected java.lang.Integer databeanVersion  
    protected static java.lang.Boolean DEFAULT_IGNORE_EXCEPTION  
    protected MemcachedClientManager memcachedClientManager  

    Fields inherited from interface io.datarouter.storage.node.op.raw.read.MapStorageReader

    OP_exists, OP_get, OP_getKeys, OP_getMulti

    Fields inherited from interface io.datarouter.storage.node.op.raw.read.TallyStorageReader

    OP_findTallyCount, OP_getMultiTallyCount
  • Constructor Summary

    Constructors 
    Constructor Description
    MemcachedReaderNode​(io.datarouter.storage.node.NodeParams<PK,​D,​F> params, io.datarouter.storage.client.ClientType<?,​?> clientType, MemcachedClientManager memcachedClientManager, io.datarouter.storage.client.ClientId clientId)  
  • Method Summary

    Modifier and Type Method Description
    protected java.lang.String buildMemcachedKey​(io.datarouter.model.key.primary.PrimaryKey<?> pk)  
    protected java.util.List<java.lang.String> buildMemcachedKeys​(java.util.Collection<? extends io.datarouter.model.key.primary.PrimaryKey<?>> pks)  
    boolean exists​(PK key, io.datarouter.storage.config.Config config)  
    protected java.util.Map<java.lang.String,​java.lang.Object> fetchBytesByStringKey​(java.util.Collection<? extends io.datarouter.model.key.primary.PrimaryKey<?>> keys, io.datarouter.storage.config.Config config)  
    java.util.Optional<java.lang.Long> findTallyCount​(java.lang.String key, io.datarouter.storage.config.Config config)  
    D get​(PK key, io.datarouter.storage.config.Config config)  
    java.util.List<PK> getKeys​(java.util.Collection<PK> keys, io.datarouter.storage.config.Config params)  
    java.util.List<D> getMulti​(java.util.Collection<PK> keys, io.datarouter.storage.config.Config config)  
    java.util.Map<java.lang.String,​java.lang.Long> getMultiTallyCount​(java.util.Collection<java.lang.String> keys, io.datarouter.storage.config.Config config)  
    protected io.datarouter.instrumentation.trace.TraceSpanFinisher startTraceSpan​(java.lang.String opName)  

    Methods inherited from class io.datarouter.storage.node.type.physical.base.BasePhysicalNode

    getChildNodes, getClientId, getClientIds, getClientType, getFieldInfo, getName, getPhysicalNodes, getPhysicalNodesForClient, toString, usesClient

    Methods inherited from class io.datarouter.storage.node.BaseNode

    compareTo

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface java.lang.Comparable

    compareTo

    Methods inherited from interface io.datarouter.storage.node.op.raw.read.MapStorageReader

    exists, find, find, get, getKeys, getMulti, scanMulti, scanMulti, scanMultiKeys, scanMultiKeys

    Methods inherited from interface io.datarouter.storage.node.op.raw.read.TallyStorageReader

    findTallyCount, getMultiTallyCount
  • Field Details

  • Constructor Details

    • MemcachedReaderNode

      public MemcachedReaderNode​(io.datarouter.storage.node.NodeParams<PK,​D,​F> params, io.datarouter.storage.client.ClientType<?,​?> clientType, MemcachedClientManager memcachedClientManager, io.datarouter.storage.client.ClientId clientId)
  • Method Details

    • exists

      public boolean exists​(PK key, io.datarouter.storage.config.Config config)
      Specified by:
      exists in interface io.datarouter.storage.node.op.raw.read.MapStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • get

      public D get​(PK key, io.datarouter.storage.config.Config config)
      Specified by:
      get in interface io.datarouter.storage.node.op.raw.read.MapStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • getKeys

      public java.util.List<PK> getKeys​(java.util.Collection<PK> keys, io.datarouter.storage.config.Config params)
      Specified by:
      getKeys in interface io.datarouter.storage.node.op.raw.read.MapStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • getMulti

      public java.util.List<D> getMulti​(java.util.Collection<PK> keys, io.datarouter.storage.config.Config config)
      Specified by:
      getMulti in interface io.datarouter.storage.node.op.raw.read.MapStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • fetchBytesByStringKey

      protected java.util.Map<java.lang.String,​java.lang.Object> fetchBytesByStringKey​(java.util.Collection<? extends io.datarouter.model.key.primary.PrimaryKey<?>> keys, io.datarouter.storage.config.Config config)
    • findTallyCount

      public java.util.Optional<java.lang.Long> findTallyCount​(java.lang.String key, io.datarouter.storage.config.Config config)
      Specified by:
      findTallyCount in interface io.datarouter.storage.node.op.raw.read.TallyStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • getMultiTallyCount

      public java.util.Map<java.lang.String,​java.lang.Long> getMultiTallyCount​(java.util.Collection<java.lang.String> keys, io.datarouter.storage.config.Config config)
      Specified by:
      getMultiTallyCount in interface io.datarouter.storage.node.op.raw.read.TallyStorageReader<PK extends io.datarouter.model.key.primary.PrimaryKey<PK>,​D extends io.datarouter.model.databean.Databean<PK,​D>>
    • buildMemcachedKey

      protected java.lang.String buildMemcachedKey​(io.datarouter.model.key.primary.PrimaryKey<?> pk)
    • buildMemcachedKeys

      protected java.util.List<java.lang.String> buildMemcachedKeys​(java.util.Collection<? extends io.datarouter.model.key.primary.PrimaryKey<?>> pks)
    • startTraceSpan

      protected io.datarouter.instrumentation.trace.TraceSpanFinisher startTraceSpan​(java.lang.String opName)