ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mahadev Konar" <maha...@apache.org>
Subject Re: Review Request 35742: Views : resource type may not be persisted on view deployment.
Date Tue, 23 Jun 2015 13:54:02 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/35742/#review88970
-----------------------------------------------------------

Ship it!


Ship It!

- Mahadev Konar


On June 22, 2015, 9:13 p.m., Tom Beerbower wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/35742/
> -----------------------------------------------------------
> 
> (Updated June 22, 2015, 9:13 p.m.)
> 
> 
> Review request for Ambari, Nate Cole and Robert Levas.
> 
> 
> Bugs: AMBARI-12079
>     https://issues.apache.org/jira/browse/AMBARI-12079
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> View resource type may not be persisted on view deployment.  In that case, view instance
creation will fail with the following...
> 
> 
>     Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.5.2.v20140319-9ad6abd):
org.eclipse.persistence.exceptions.DatabaseException
>     Internal Exception: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException:
Column 'resource_type_id' cannot be null
>     Error Code: 1048
>     Call: INSERT INTO adminresource (resource_id, resource_type_id) VALUES (?, ?)
>         bind => [2 parameters bound]
>         at org.eclipse.persistence.exceptions.DatabaseException.sqlException(DatabaseException.java:331)
>         at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeDirectNoSelect(DatabaseAccessor.java:900)
>         at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.executeNoSelect(DatabaseAccessor.java:962)
>         at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:631)
>         at org.eclipse.persistence.internal.databaseaccess.ParameterizedSQLBatchWritingMechanism.executeBatch(ParameterizedSQLBatchWritingMechanism.java:149)
>         at org.eclipse.persistence.internal.databaseaccess.ParameterizedSQLBatchWritingMechanism.executeBatchedStatements(ParameterizedSQLBatchWritingMechanism.java:134)
>         at org.eclipse.persistence.internal.databaseaccess.DatabaseAccessor.writesCompleted(DatabaseAccessor.java:1836)
>         at org.eclipse.persistence.internal.sessions.AbstractSession.writesCompleted(AbstractSession.java:4244)
>         at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.writesCompleted(UnitOfWorkImpl.java:5594)
>         at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.acquireWriteLocks(UnitOfWorkImpl.java:1646)
>         at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitTransactionAfterWriteChanges(UnitOfWorkImpl.java:1614)
>         at org.eclipse.persistence.internal.sessions.RepeatableWriteUnitOfWork.commitRootUnitOfWork(RepeatableWriteUnitOfWork.java:284)
>         at org.eclipse.persistence.internal.sessions.UnitOfWorkImpl.commitAndResume(UnitOfWorkImpl.java:1169)
>         at org.eclipse.persistence.internal.jpa.transaction.EntityTransactionImpl.commit(EntityTransactionImpl.java:132)
>         at org.apache.ambari.server.orm.AmbariJpaLocalTxnInterceptor.invoke(AmbariJpaLocalTxnInterceptor.java:91)
>         at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
>         at com.google.inject.internal.InterceptorStackCallback.intercept(InterceptorStackCallback.java:52)
>         at org.apache.ambari.server.orm.dao.ResourceDAO$$EnhancerByGuice$$d30f4b3d.create(<generated>)
>         at org.apache.ambari.server.view.ViewRegistry.createViewInstanceResource(ViewRegistry.java:1378)
>         at org.apache.ambari.server.view.ViewRegistry.mergeViewInstance(ViewRegistry.java:1369)
>         at org.apache.ambari.server.view.ViewRegistry.installViewInstance(ViewRegistry.java:525)
>         at org.apache.ambari.server.view.ViewRegistry.onAmbariEvent(ViewRegistry.java:885)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>         at java.lang.reflect.Method.invoke(Method.java:606)
>         at com.google.common.eventbus.EventHandler.handleEvent(EventHandler.java:74)
>         at com.google.common.eventbus.EventBus.dispatch(EventBus.java:314)
>         at com.google.common.eventbus.AsyncEventBus.access$001(AsyncEventBus.java:34)
>         at com.google.common.eventbus.AsyncEventBus$1.run(AsyncEventBus.java:100)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:745)
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java 29b9000

>   ambari-server/src/test/java/org/apache/ambari/server/view/ViewRegistryTest.java 4d2c8e2

> 
> Diff: https://reviews.apache.org/r/35742/diff/
> 
> 
> Testing
> -------
> 
> Manual test.
> 
> Updated unit tests.
> 
> mvn clean test
> 
> all pass
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 46:16 min
> [INFO] Finished at: 2015-06-22T16:51:51-04:00
> [INFO] Final Memory: 56M/1539M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Tom Beerbower
> 
>


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