Class ConnectedContractCacheOperation

java.lang.Object
es.kukenan.smartfi.microservice.contracts.cache.ConnectedContractCacheOperation

@Component @RefreshScope public class ConnectedContractCacheOperation extends Object
Operation over contract cache.
  • Field Details

    • connectedContractUuidSession

      @Value("${cache.connected-contract-uuid-session-map}") private String connectedContractUuidSession
      map contract-uuid-session cache established.
    • connectedContractTimeToLive

      @Value("${cache.connected-contract-time-to-live}") private Long connectedContractTimeToLive
      ttl contract time-to-live established.
    • hazelcastInstance

      @Autowired private com.hazelcast.core.HazelcastInstance hazelcastInstance
      HazelcastInstance hazelcastInstance.
  • Constructor Details

    • ConnectedContractCacheOperation

      public ConnectedContractCacheOperation()
  • Method Details

    • cacheOperationsContract

      public void cacheOperationsContract(List<SessionCacheOperationEnum> operations, String uuid, Object obj)
      Contract cache operations.
      Parameters:
      operations - to be executed
      uuid - key of the registry
      obj - to be saved
    • insertContractCache

      public ContractCache insertContractCache(ContractCache contractCache)
      getting all Cache object.
      Parameters:
      contractCache - value of the registry
      Returns:
      ContractCacheDto
    • getAllInformationByUuid

      public ContractCache getAllInformationByUuid(String uuid)
      getting all Cache object.
      Parameters:
      uuid - key of the registry
      Returns:
      uuidCache object
    • existsConnectedContractInCache

      public boolean existsConnectedContractInCache(String sessionId)
      exists connected contract object.
      Parameters:
      sessionId - session identifier
      Returns:
      boolean
    • refreshContractCache

      public ContractCache refreshContractCache(String sessionId)
      refresh contract Cache object.
      Parameters:
      sessionId - session identifier
      Returns:
      ContractCacheDto
    • clear

      public void clear()
      clear contract Cache object.