Package org.springframework.dao

Examples of org.springframework.dao.DataAccessResourceFailureException


              return provider;
            }
          });
    }
    catch (MetaDataAccessException ex) {
      throw new DataAccessResourceFailureException("Error retrieving database metadata", ex);
    }
  }
View Full Code Here


                type = Constants.DB_VT_ORACLE;
           
            databaseType = type;
            return type;
        } catch (SQLException e) {
            throw new DataAccessResourceFailureException("Cannot get Vendor Type", e);
        } finally {
            releaseConnection(connection);
        }
    }
View Full Code Here

        }
            }

            return dbd;
        } catch (SQLException e) {
            throw new DataAccessResourceFailureException("Error getting Database description", e);
        } catch (RuntimeException e1){
            throw new DataAccessResourceFailureException("Error getting Database description", e1);
        } finally {
            releaseConnection(connection);
        }
    }
View Full Code Here

        Connection connection = this.getConnection();
        try {
            set = new DBDataSet(TableName, connection.getMetaData());
            return set;
        } catch (SQLException e) {
            throw new DataAccessResourceFailureException("Error getting database Table description on table: " + TableName, e);
        }
        finally {
            releaseConnection(connection);
        }
    }
View Full Code Here

        try {
            String result = connection.getMetaData().getDatabaseProductName();
            databaseName = result;
            return result;
        } catch (SQLException e) {
            throw new DataAccessResourceFailureException("Error getting database product name", e);
        }
        finally  {
            releaseConnection(connection);
        }
    }
View Full Code Here

      throws DataAccessResourceFailureException {
    try {
      return doGetTransactionalEntityManager(emf, properties);
    }
    catch (PersistenceException ex) {
      throw new DataAccessResourceFailureException("Could not obtain JPA EntityManager", ex);
    }
  }
View Full Code Here

    else {
      try {
        return getSessionFactory().getCurrentSession();
      }
      catch (HibernateException ex) {
        throw new DataAccessResourceFailureException("Could not obtain current Hibernate Session", ex);
      }
    }
  }
View Full Code Here

    try {
      return doGetSession(sessionFactory, null, null, allowCreate);
    }
    catch (HibernateException ex) {
      throw new DataAccessResourceFailureException("Could not open Hibernate Session", ex);
    }
  }
View Full Code Here

    try {
      return doGetSession(sessionFactory, entityInterceptor, jdbcExceptionTranslator, true);
    }
    catch (HibernateException ex) {
      throw new DataAccessResourceFailureException("Could not open Hibernate Session", ex);
    }
  }
View Full Code Here

        // No transaction active -> simply return default thread-bound Session, if any
        // (possibly from OpenSessionInViewFilter/Interceptor).
        return sessionHolder.getValidatedSession();
      }
      catch (Throwable ex) {
        throw new DataAccessResourceFailureException("Could not check JTA transaction", ex);
      }
    }
    else {
      // No JTA TransactionManager -> simply return default thread-bound Session, if any
      // (possibly from OpenSessionInViewFilter/Interceptor).
View Full Code Here

TOP

Related Classes of org.springframework.dao.DataAccessResourceFailureException

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.