Bug 1011489 - /api/vms Rest API 500 ERROR After upgrade to 3.3
Summary: /api/vms Rest API 500 ERROR After upgrade to 3.3
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: ovirt-engine-api
Version: 3.3
Hardware: All
OS: Linux
unspecified
urgent
Target Milestone: ---
: 3.3.1
Assignee: Michael Pasternak
QA Contact:
URL:
Whiteboard: infra
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-24 12:19 UTC by Yamakasi
Modified: 2014-01-13 00:39 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-25 12:02:19 UTC
oVirt Team: ---


Attachments (Terms of Use)
Debug logs (159.53 KB, application/zip)
2013-11-14 17:10 UTC, Joop van de Wege
no flags Details

Description Yamakasi 2013-09-24 12:19:51 UTC
Description of problem:

After upgrading to 3.3 the REST API doesn't show the VM's anymore from (one) DC.

Version-Release number of selected component (if applicable):

3.3

How reproducible:

go to http://ovirtengine/api/vms

Steps to Reproduce:
1. See above
2.
3.

Actual results:

HTTP Status 500 -

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.jboss.resteasy.spi.UnhandledException: java.lang.NullPointerException
	org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:340)
	org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:214)
	org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:190)
	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:540)
	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:502)
	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:119)
	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)
	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)
	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:847)

root cause

java.lang.NullPointerException
	org.ovirt.engine.api.common.util.LinkHelper.getCollection(LinkHelper.java:523)
	org.ovirt.engine.api.common.util.LinkHelper.getUriBuilder(LinkHelper.java:569)
	org.ovirt.engine.api.restapi.resource.AbstractBackendResource.linkSubCollections(AbstractBackendResource.java:287)
	org.ovirt.engine.api.restapi.resource.AbstractBackendResource.addLinks(AbstractBackendResource.java:228)
	org.ovirt.engine.api.restapi.resource.AbstractBackendResource.addLinks(AbstractBackendResource.java:218)
	org.ovirt.engine.api.restapi.resource.BackendVmsResource.mapCollection(BackendVmsResource.java:407)
	org.ovirt.engine.api.restapi.resource.BackendVmsResource.list(BackendVmsResource.java:71)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	java.lang.reflect.Method.invoke(Method.java:606)
	org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:155)
	org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:257)
	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:222)
	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:211)
	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:525)
	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:502)
	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:119)
	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)
	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)
	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:847)

note The full stack trace of the root cause is available in the JBoss Web/7.0.13.Final logs.
JBoss Web/7.0.13.Final


Expected results:

List of the VM's


Additional info:

I have two DC's where one is capable of displaying but not usable on creating a host in Foreman, for the other DC it's the other way around. No list but capable to create a VM.

Comment 1 Michael Pasternak 2013-09-24 12:37:24 UTC
Yamakasi,

what build you're using, can i have the entire log?

Comment 2 Yamakasi 2013-09-24 12:55:02 UTC
Hi,

This comes right from a webbrowser when I visit the url for the VM's.

Other API requests work OK, hosts, disks, etc.

At the moment I don't have any other log.

How can I help you out ?

Thanks!

Comment 3 Michael Pasternak 2013-09-24 13:00:44 UTC
(In reply to Yamakasi from comment #2)
> Hi,
> 
> This comes right from a webbrowser when I visit the url for the VM's.
> 
> Other API requests work OK, hosts, disks, etc.
> 
> At the moment I don't have any other log.
> 
> How can I help you out ?

to try and reproduce your issue, at least i need to know what build you're using.

> 
> Thanks!

Comment 4 Yamakasi 2013-09-24 14:25:16 UTC
Version 3.3.0-4.el6

Comment 5 Yamakasi 2013-09-26 05:58:24 UTC
Hi Micheal,

I need to appologize for my last too short reply, I was in a hurry and wanted to let you know.

Do you already have some news ?

Regards,

Matt

Comment 6 Yamakasi 2013-10-01 08:13:35 UTC
Is there any news on this ? It's actually a big issue that this error exists!

Comment 7 Samuli Heinonen 2013-10-18 11:07:11 UTC
Hello,

Is this same bug as described on this ML thread http://www.mail-archive.com/users@ovirt.org/msg09574.html and afaik fixed with this http://gerrit.ovirt.org/#/c/18061/? What's the status of this fix?

-samuli

Comment 8 Itamar Heim 2013-10-21 04:58:41 UTC
doron - this seem to have not been backported to 3.3.0.1 for some reason.

it is fixed for 3.3.1 beta via 
http://gerrit.ovirt.org/#/c/19217/

(Samuli - don't upgrade to 3.3.1 beta until it is re-spinned for some upgrade issue)

Comment 9 Sandro Bonazzola 2013-11-06 15:59:59 UTC
Shouldn't this be in modified state then?

Comment 10 Joop van de Wege 2013-11-14 13:41:33 UTC
Just install 3.3.1 on FC19 but still can't connect from Foreman (1.3.1) to oVirt.

Comment 11 Joop van de Wege 2013-11-14 13:44:44 UTC
Sorry forget to add that doing https://engine/api/vms will give me the error from the first post.

Comment 12 Michael Pasternak 2013-11-14 14:31:28 UTC
(In reply to Joop van de Wege from comment #11)
> Sorry forget to add that doing https://engine/api/vms will give me the error
> from the first post.

Sorry,

But i just can't reproduce this on my environment, to tackle this, i need the
following;

1. enable full debug, see details at [1]
2. engine.log, server.log (you can find them at /var/log/ovirt-engine)

[1] http://www.ovirt.org/OVirt_Engine_Development_Environment#Advanced_Usage

Comment 13 Joop van de Wege 2013-11-14 17:09:05 UTC
(In reply to Michael Pasternak from comment #12)
> (In reply to Joop van de Wege from comment #11)
> > Sorry forget to add that doing https://engine/api/vms will give me the error
> > from the first post.
> 
> Sorry,
> 
> But i just can't reproduce this on my environment, to tackle this, i need the
> following;
> 
> 1. enable full debug, see details at [1]
> 2. engine.log, server.log (you can find them at /var/log/ovirt-engine)
> 
> [1] http://www.ovirt.org/OVirt_Engine_Development_Environment#Advanced_Usage
Attached the logs requested. The request for /api/vms is around the following timestamp of all 3 logs --> 2013-11-14 16:39:51,657

If needed I can do more testing.

Comment 14 Joop van de Wege 2013-11-14 17:10:38 UTC
Created attachment 824051 [details]
Debug logs

Comment 15 Sandro Bonazzola 2013-11-15 10:59:43 UTC
Should we reopen this? If so, is this to be considered blocker for 3.3.1?

Comment 16 Michael Pasternak 2013-11-17 06:46:59 UTC
(In reply to Sandro Bonazzola from comment #15)
> Should we reopen this? If so, is this to be considered blocker for 3.3.1?

i believe this is a local issue of this specific environment, if [1] would
have an issue, it was reported by others a while ago,

i'll check anyway.


[1] GET /api/vms

Comment 17 Joop van de Wege 2013-11-17 09:23:20 UTC
updated to 3.3.1-2.fc19 (from the beta repo) and now foreman can get a list of VMs and GET /api/vms works too :-)


Joop

Comment 18 Sandro Bonazzola 2013-11-25 12:02:19 UTC
oVirt 3.3.1 has been released


Note You need to log in before you can comment on or make changes to this bug.