brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthew Champion (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (BROOKLYN-89) Catalog item not found when creating an application through GUI
Date Mon, 17 Nov 2014 12:39:34 GMT

    [ https://issues.apache.org/jira/browse/BROOKLYN-89?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14214604#comment-14214604
] 

Matthew Champion commented on BROOKLYN-89:
------------------------------------------

I think this also relates to the catalog versioning changes. The typeName passed into the
BasicBrooklynCatalog.loadClassByType is brooklyn.clocker.example.SimpleDockerCloud:0.0.0_SNAPSHOT
which is compared to the catalog items Java type. The version qualifier causes this to fail
every catalog itme. The test BrooklynRestResourceUtilsTest.testCreateAppFromImplClass manages
to invoke the method BasicBrooklynCatalog.loadClassByType without the version qualifier by
explicitly setting the type. When the ApplicationResource.createPoly creates the ApplicationSpec
by deserialising a byte array it has the version qualifier. This is what happens when I try
to create applications through the GUI. BasicBrooklynCatalog.loadClassByType needs to be able
to handled qualified an unqualified types.

> Catalog item not found when creating an application through GUI
> ---------------------------------------------------------------
>
>                 Key: BROOKLYN-89
>                 URL: https://issues.apache.org/jira/browse/BROOKLYN-89
>             Project: Brooklyn
>          Issue Type: Bug
>    Affects Versions: 0.7.0-SNAPSHOT
>            Reporter: Matthew Champion
>            Assignee: Andrew Kennedy
>
> Catalog lookup is failing. An exception "java.util.NoSuchElementException: Unable to
find catalog item for type brooklyn.clocker.example.SimpleDockerCloud:0.0.0_SNAPSHOT" is thrown.
The problem appears to be that the type is provided as the symbolic-type:version and is expected
to be the symbolic type alone.
> This can be seen using Clocker as an example.
> Full stacktrace:
> 2014-11-17 10:51:06,027 WARN  b.r.u.DefaultExceptionMapper [brooklyn-jetty-server-8082-qtp1627276268-51]:
REST call generated exception type class java.util.NoSuchElementException unrecognized in
class brooklyn.rest.util.DefaultExcepti
> onMapper (subsequent occurrences will be logged debug only): java.util.NoSuchElementException:
Unable to find catalog item for type brooklyn.clocker.example.SimpleDockerCloud:0.0.0_SNAPSHOT
> java.util.NoSuchElementException: Unable to find catalog item for type brooklyn.clocker.example.SimpleDockerCloud:0.0.0_SNAPSHOT
>         at brooklyn.catalog.internal.BasicBrooklynCatalog.loadClassByType(BasicBrooklynCatalog.java:406)
~[brooklyn-core-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at brooklyn.rest.util.BrooklynRestResourceUtils.create(BrooklynRestResourceUtils.java:226)
~[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at brooklyn.rest.resources.ApplicationResource.createFromAppSpec(ApplicationResource.java:243)
~[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at brooklyn.rest.resources.ApplicationResource.createPoly(ApplicationResource.java:310)
~[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_67]
>         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
~[na:1.7.0_67]
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~[na:1.7.0_67]
>         at java.lang.reflect.Method.invoke(Method.java:606) ~[na:1.7.0_67]
>         at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.uri.rules.ResourceObjectRule.accept(ResourceObjectRule.java:100)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
~[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542)
[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473)
[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419)
[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409)
[jersey-server-1.18.1.jar:1.18.1]
>         at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409)
[jersey-servlet-1.18.1.jar:1.18.1]
>         at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:540)
[jersey-servlet-1.18.1.jar:1.18.1]
>         at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:909)
[jersey-servlet-1.18.1.jar:1.18.1]
>         at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:857)
[jersey-servlet-1.18.1.jar:1.18.1]
>         at com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:811)
[jersey-servlet-1.18.1.jar:1.18.1]
>         at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1338)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at brooklyn.rest.filter.HaMasterCheckFilter.doFilter(HaMasterCheckFilter.java:64)
[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1338)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at brooklyn.rest.filter.LoggingFilter.doFilter(LoggingFilter.java:88) [brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1338)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at brooklyn.rest.filter.BrooklynPropertiesSecurityFilter.doFilter(BrooklynPropertiesSecurityFilter.java:122)
[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1338)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at brooklyn.rest.filter.RequestTaggingFilter.doFilter(RequestTaggingFilter.java:48)
[brooklyn-rest-server-0.7.0-SNAPSHOT.jar:0.7.0-SNAPSHOT]
>         at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1338)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:484)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:524)
[jetty-security-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1065)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:413)
[jetty-servlet-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:192)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:999)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:250)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:111)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.Server.handle(Server.java:350) [jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:454)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:900)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:954)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:851) [jetty-http-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235) [jetty-http-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:77)
[jetty-server-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:620)
[jetty-io-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:46)
[jetty-io-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:603)
[jetty-util-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:538)
[jetty-util-8.1.4.v20120524.jar:8.1.4.v20120524]
>         at java.lang.Thread.run(Thread.java:745) [na:1.7.0_67]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message