Package org.springframework.dao

Examples of org.springframework.dao.InvalidDataAccessResourceUsageException


            final Relationship relationship = createRelationshipFromEntity();
            setPersistentState(relationship);
            if (log.isDebugEnabled()) log.debug("User-defined constructor called on class " + entity.getClass() + "; created Relationship [" + getPersistentState() + "]; Updating metamodel");
            template.postEntityCreation(relationship, type);
        } catch (NotInTransactionException e) {
            throw new InvalidDataAccessResourceUsageException("Not in a Neo4j transaction.", e);
        }
    }
View Full Code Here


            } else {
                setPersistentState(node);
                entity.setPersistentState(node);
            }
        } catch (NotInTransactionException e) {
            throw new InvalidDataAccessResourceUsageException("Not in a Neo4j transaction.", e);
        }
    }
View Full Code Here

   */
  @Override
  public RedisSentinelConnection getSentinelConnection() {

    if (!hasRedisSentinelConfigured()) {
      throw new InvalidDataAccessResourceUsageException("No sentinels configured.");
    }

    RedisNode node = selectActiveSentinel();
    RedisSentinelConnection connection = connectionCache.get(node);
    if (connection == null || !connection.isOpen()) {
View Full Code Here

   */
  public static DataAccessException convertJredisAccessException(ClientRuntimeException ex) {
    if (ex instanceof NotConnectedException) {
      return new RedisConnectionFailureException(ex.getMessage(), ex);
    }
    return new InvalidDataAccessResourceUsageException(ex.getMessage(), ex);
  }
View Full Code Here

   */
  @Override
  public RedisSentinelConnection getSentinelConnection() {

    if (!isRedisSentinelAware()) {
      throw new InvalidDataAccessResourceUsageException("No Sentinels configured");
    }
   
    return new JedisSentinelConnection(getActiveSentinel());
  }
View Full Code Here

      if (jedis.ping().equalsIgnoreCase("pong")) {
        return jedis;
      }
    }

    throw new InvalidDataAccessResourceUsageException("no sentinel found");
  }
View Full Code Here

TOP

Related Classes of org.springframework.dao.InvalidDataAccessResourceUsageException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.