Bug 1058318 - Unable to create 2 alert defs in a row - gwt serialization error
Summary: Unable to create 2 alert defs in a row - gwt serialization error
Status: ON_QA
Alias: None
Product: RHQ Project
Classification: Other
Component: Core UI
Version: 4.10
Hardware: Unspecified
OS: Unspecified
high vote
Target Milestone: ---
: RHQ 4.13
Assignee: Jirka Kremser
QA Contact: Mike Foley
: 1099621 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2014-01-27 14:27 UTC by Lukas Krejci
Modified: 2014-07-16 17:58 UTC (History)
5 users (show)

Clone Of:
Last Closed:

Attachments (Terms of Use)

Description Lukas Krejci 2014-01-27 14:27:31 UTC
Description of problem:
When trying to define 2 alert definitions on a single resource, the second and further attempts fail with a message:
Attempt to deserialize an object of type class org.rhq.core.domain.alert.AlertCondition when an object of type class org.rhq.core.domain.alert.AlertDefinition is expected

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

How reproducible:

Steps to Reproduce:
1. Go to one of the storage node resources
2. Define an alert def (in my case name "test", condition "resource config change"), hit save.
3. Once the alert def is created, try to create second one with the same params.

Actual results:
Error as described

Expected results:
No errors

Additional info:

Comment 1 Jirka Kremser 2014-02-13 14:29:30 UTC
This bug is caused by an issue in GWT 2.5.0 (http://code.google.com/p/google-web-toolkit/issues/detail?id=7628).

It is fixed in 2.6.0-rc3 and higher.

Comment 2 John Mazzitelli 2014-05-21 14:52:26 UTC
for the record, this also manifests itself in other ways. for example:

1) execute an operation on a resource (say view the process list on a platform). It works.

2) Go create an alert definition on the resource.

3) Now go execute the operation again.

You get the error reported in this BZ

Comment 3 Jay Shaughnessy 2014-05-21 15:07:16 UTC
*** Bug 1099621 has been marked as a duplicate of this bug. ***

Comment 4 Jay Shaughnessy 2014-05-21 15:08:35 UTC
It seems to happen anytime we send a Resource to the server with the new alertDef attached.

Comment 5 Jirka Kremser 2014-07-16 16:20:55 UTC
this guy fixes the issue in GWT https://gwt.googlesource.com/gwt/+/4631b356ede41148b726f6014803a249dbc8df4b

Now I need to figure out how to use own ServerSerializationStreamReader with his change.

Comment 6 Jirka Kremser 2014-07-16 17:56:30 UTC
branch:  master
link:    https://github.com/rhq-project/rhq/commit/522860a34
time:    2014-07-16 19:53:12 +0200
commit:  522860a34ba71f3164cea32d03daf1fa1ea93f32
author:  Jirka Kremser - jkremser@redhat.com
message: [BZ 1058318] - Unable to create 2 alert defs in a row - gwt
         serialization error - Simplifying the objects that are sent
         over the wire not to cause troubles with the GWT2.5.0
         serialization bug.

Fixed for creating/updating alerts, invoking operation or group and resource. Also for alert templates. It might be possible that I miss some scenario, because it is hard to find in code when it will be failing. Upgrading GWT to 2.6 would be safer.

Comment 7 Jirka Kremser 2014-07-16 17:58:04 UTC
Just a note:
it is not possible to use own implementation of AbstractSerializationStreamReader without compiling the GWT source code.

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