/** {@inheritDoc} */ @Override public void put(K key, V val) throws TransactionException { CacheOperationGate opGate = onEnter(); try { delegate.put(key, val); } finally { onLeave(opGate); } }
switch (type) { case OP_PUT: cache.put(reader.readObjectDetached(), reader.readObjectDetached());
switch (type) { case OP_PUT: cache.put(reader.readObjectDetached(), reader.readObjectDetached());
/** * @param ignite Ignite. * @return Cache. */ protected IgniteCacheProxy<Integer, Integer> fillCache(Ignite ignite) { IgniteCacheProxy<Integer, Integer> cache = (IgniteCacheProxy<Integer, Integer>)ignite.<Integer, Integer>cache(DEFAULT_CACHE_NAME); for (int i = 0; i < KEYS_CNT; i++) { cache.put(i, i); int part = cache.context().affinity().partition(i); Map<Integer, Integer> partEntries = entries.get(part); if (partEntries == null) entries.put(part, partEntries = new HashMap<>()); partEntries.put(i, i); } return cache; }
/** {@inheritDoc} */ @Override public void put(K key, V val) throws TransactionException { CacheOperationGate opGate = onEnter(); try { delegate.put(key, val); } finally { onLeave(opGate); } }