ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nate Cole" <nc...@hortonworks.com>
Subject Re: Review Request 25417: Views: failed to create view instance
Date Sun, 07 Sep 2014 09:36:47 GMT

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

Ship it!


Ship It!

- Nate Cole


On Sept. 6, 2014, 9:08 p.m., Tom Beerbower wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25417/
> -----------------------------------------------------------
> 
> (Updated Sept. 6, 2014, 9:08 p.m.)
> 
> 
> Review request for Ambari, Nate Cole and Sid Wagle.
> 
> 
> Bugs: AMBARI-7189
>     https://issues.apache.org/jira/browse/AMBARI-7189
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> STR:
> * Deployed a view (in this case, Capacity Scheduler view)
> * Created an instance of the view.
> * Deleted the view instance
> * Removed the view jar file and work directory from /var/lib/ambari-server/resources/views
> * Restart ambari-server.  API shows that the view is no longer registered (expected)
> * Deploy the same view again
> * Try to create another instance.  This fails.
> 
> {noformat}
> 16:25:20,636 ERROR [qtp918820051-27] BaseManagementHandler:66 - Caught a runtime exception
while attempting to create a resource
> javax.persistence.NonUniqueResultException: More than one result was returned from Query.getSingleResult()
>         at org.eclipse.persistence.internal.jpa.QueryImpl.throwNonUniqueResultException(QueryImpl.java:870)
>         at org.eclipse.persistence.internal.jpa.QueryImpl.getSingleResult(QueryImpl.java:450)
>         at org.eclipse.persistence.internal.jpa.EJBQueryImpl.getSingleResult(EJBQueryImpl.java:382)
>         at org.apache.ambari.server.orm.dao.DaoUtils.selectSingle(DaoUtils.java:61)
>         at org.apache.ambari.server.orm.dao.ResourceTypeDAO.findByName(ResourceTypeDAO.java:69)
>         at org.apache.ambari.server.orm.AmbariLocalSessionInterceptor.invoke(AmbariLocalSessionInterceptor.java:53)
>         at org.apache.ambari.server.view.ViewRegistry.installViewInstance(ViewRegistry.java:511)
>         at org.apache.ambari.server.controller.internal.ViewInstanceResourceProvider$1.invoke(ViewInstanceResourceProvider.java:342)
>         at org.apache.ambari.server.controller.internal.ViewInstanceResourceProvider$1.invoke(ViewInstanceResourceProvider.java:332)
>         at org.apache.ambari.server.controller.internal.AbstractResourceProvider.createResources(AbstractResourceProvider.java:270)
>         at org.apache.ambari.server.controller.internal.ViewInstanceResourceProvider.createResources(ViewInstanceResourceProvider.java:121)
>         at org.apache.ambari.server.controller.internal.ClusterControllerImpl.createResources(ClusterControllerImpl.java:274)
>         at org.apache.ambari.server.api.services.persistence.PersistenceManagerImpl.create(PersistenceManagerImpl.java:75)
>         at org.apache.ambari.server.api.handlers.CreateHandler.persist(CreateHandler.java:36)
>         at org.apache.ambari.server.api.handlers.BaseManagementHandler.handleRequest(BaseManagementHandler.java:72)
>         at org.apache.ambari.server.api.services.BaseRequest.process(BaseRequest.java:135)
>         at org.apache.ambari.server.api.services.BaseService.handleRequest(BaseService.java:103)
>         at org.apache.ambari.server.api.services.BaseService.handleRequest(BaseService.java:72)
>         at org.apache.ambari.server.api.services.ViewInstanceService.createService(ViewInstanceService.java:135)
>         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.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
>         at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
>         at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
>         at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:288)
>         at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
> {noformat}
> 
> See the attached ambari-server.log.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/orm/entities/ViewEntity.java aec9ab9

> 
> Diff: https://reviews.apache.org/r/25417/diff/
> 
> 
> Testing
> -------
> 
> Manual testing as described in Jira.
> 
> All existing tests pass ...
> 
> Results :
> 
> Tests run: 1966, Failures: 0, Errors: 0, Skipped: 16
> 
> ...
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 33:31.259s
> [INFO] Finished at: Sat Sep 06 19:55:32 EDT 2014
> [INFO] Final Memory: 45M/489M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Tom Beerbower
> 
>


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