ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tom Beerbower" <>
Subject Review Request 34813: Views : Can't create instance (intermittent)
Date Fri, 29 May 2015 15:28:38 GMT

This is an automatically generated e-mail. To reply, visit:

Review request for Ambari and John Speidel.

Bugs: AMBARI-11540

Repository: ambari


Intermittent BatchUpdateException during create instance of HIVE view.

Refactored @Transactional method ViewRegistry.installViewInstance() to remove instanceDAO.findByName()
which appears to trigger EntityManagerImpl.flush().

    Internal Exception: java.sql.BatchUpdateException: Batch entry 0 INSERT INTO viewinstanceproperty
(name, VALUE, view_name, view_instance_name) VALUES ('views.tez.instance', NULL, 'HIVE{0.4.0}',
'hiwe2') was aborted.  Call getNextException to see the cause.
    Error Code: 0
    Call: INSERT INTO viewinstanceproperty (name, VALUE, view_name, view_instance_name) VALUES
(?, ?, ?, ?)
	    bind => [4 parameters bound]
		at org.eclipse.persistence.internal.jpa.EntityManagerImpl.flush(
		at org.eclipse.persistence.internal.jpa.QueryImpl.performPreQueryFlush(
		at org.eclipse.persistence.internal.jpa.QueryImpl.executeReadQuery(
		at org.eclipse.persistence.internal.jpa.QueryImpl.getSingleResult(
		at org.eclipse.persistence.internal.jpa.EJBQueryImpl.getSingleResult(
		at org.apache.ambari.server.orm.dao.DaoUtils.selectSingle(
		at org.apache.ambari.server.orm.dao.ViewInstanceDAO.findByName(
		at org.apache.ambari.server.orm.AmbariLocalSessionInterceptor.invoke(
		at org.apache.ambari.server.view.ViewRegistry.installViewInstance(


  ambari-server/src/main/java/org/apache/ambari/server/view/ b3ae2d0 
  ambari-server/src/test/java/org/apache/ambari/server/view/ c66a9ce



Manual testing to create view instances.

Updated unit tests.

mvn clean test

all tests pass


Tom Beerbower

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message