Fastpath plugin is not sending a Workgroup form to an agent using Spark

Description

When a user starts a chat with a Fastpath workgroup JID and fills an automated form (support request), an agent assigned to that group and logged into Spark's Fastpath plugin should get a popup with Accept, Forward buttons and a progress bar until the automatic request forwarding to a next available agent. Currently Saprk shows blank popup and this happens with old Spark version, so the issue must be in Openfire or Openfire's Fasthpath plugin side.

Openfire logs such error upon getting filled form:
[org.jivesoftware.openfire.component.InternalComponentManager$2.error(InternalCo mponentManager.java:338)
]
com.thoughtworks.xstream.converters.ConversionException: Cannot construct org.xmpp.forms.DataForm as it does not have a no-args constructor


Debugging information ----
message : Cannot construct org.xmpp.forms.DataForm as it does not have a no-args constructor
line number : 1
path : /org.xmpp.forms.DataForm
cause-message : Cannot construct org.xmpp.forms.DataForm as it does not have a no-args constructor
class : org.xmpp.forms.DataForm
cause-exception : com.thoughtworks.xstream.converters.reflection.ObjectAccessException
required-type : org.xmpp.forms.DataForm
-------------------------------
at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:63 )
at com.thoughtworks.xstream.core.AbstractReferenceUnmarshaller.convert(AbstractRef erenceUnmarshaller.java:45)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convertAnother(TreeUnmarshaller. java:46)
at com.thoughtworks.xstream.core.TreeUnmarshaller.start(TreeUnmarshaller.java:117)
at com.thoughtworks.xstream.core.ReferenceByXPathMarshallingStrategy.unmarshal(Ref erenceByXPathMarshallingStrategy.java:29)
at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:826)
at com.thoughtworks.xstream.XStream.unmarshal(XStream.java:813)
at com.thoughtworks.xstream.XStream.fromXML(XStream.java:761)
at com.thoughtworks.xstream.XStream.fromXML(XStream.java:753)
at org.jivesoftware.openfire.fastpath.dataforms.FormManager.getDataForm(FormManage r.java:189)
at org.jivesoftware.openfire.fastpath.dataforms.WorkgroupFormProvider.executeGet(W orkgroupFormProvider.java:41)
at org.jivesoftware.xmpp.workgroup.WorkgroupIQHandler.handleIQGet(WorkgroupIQHandl er.java:511)
at org.jivesoftware.xmpp.workgroup.WorkgroupIQHandler.process(WorkgroupIQHandler.j ava:82)
at org.jivesoftware.xmpp.workgroup.Workgroup.process(Workgroup.java:424)
at org.jivesoftware.xmpp.workgroup.Workgroup.process(Workgroup.java:447)
at org.jivesoftware.xmpp.workgroup.WorkgroupManager.processPacket(WorkgroupManager .java:652)
at org.jivesoftware.openfire.component.InternalComponentManager$RoutableComponents .process(InternalComponentManager.java:593)
at org.jivesoftware.openfire.spi.RoutingTableImpl.routePacket(RoutingTableImpl.jav a:258)
at org.jivesoftware.openfire.IQRouter.handle(IQRouter.java:301)
at org.jivesoftware.openfire.IQRouter.route(IQRouter.java:101)
at org.jivesoftware.openfire.spi.PacketRouterImpl.route(PacketRouterImpl.java:68)
at org.jivesoftware.openfire.net.StanzaHandler.processIQ(StanzaHandler.java:311)
at org.jivesoftware.openfire.net.ClientStanzaHandler.processIQ(ClientStanzaHandler .java:79)
at org.jivesoftware.openfire.net.StanzaHandler.process(StanzaHandler.java:276)
at org.jivesoftware.openfire.net.StanzaHandler.process(StanzaHandler.java:175)
at org.jivesoftware.openfire.nio.ConnectionHandler.messageReceived(ConnectionHandl er.java:133)
at org.apache.mina.common.support.AbstractIoFilterChain$TailFilter.messageReceived (AbstractIoFilterChain.java:570)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.common.IoFilterAdapter.messageReceived(IoFilterAdapter.java:80)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.filter.codec.support.SimpleProtocolDecoderOutput.flush(SimplePr otocolDecoderOutput.java:58)
at org.apache.mina.filter.codec.ProtocolCodecFilter.messageReceived(ProtocolCodecF ilter.java:185)
at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)
at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)
at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)
at org.apache.mina.filter.executor.ExecutorFilter.processEvent(ExecutorFilter.java :239)
at org.apache.mina.filter.executor.ExecutorFilter$ProcessEventsRunnable.run(Execut orFilter.java:283)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at org.apache.mina.util.NamePreservingRunnable.run(NamePreservingRunnable.java:51)
at java.lang.Thread.run(Unknown Source)
Caused by: com.thoughtworks.xstream.converters.reflection.ObjectAccessException: Cannot construct org.xmpp.forms.DataForm as it does not have a no-args constructor
at com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.newIn stance(PureJavaReflectionProvider.java:51)
at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.inst antiateNewInstance(AbstractReflectionConverter.java:223)
at com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.unma rshal(AbstractReflectionConverter.java:117)
at com.thoughtworks.xstream.core.TreeUnmarshaller.convert(TreeUnmarshaller.java:56 )
... 44 more

Spark is loggin this error:
org.jivesoftware.spark.util.log.Log error
SEVERE: Unable to retrieve Workgroup form.
item-not-found(404)
at org.jivesoftware.smackx.workgroup.user.Workgroup.getWorkgroupForm(Workgroup.jav a:850)
at org.jivesoftware.fastpath.workspace.panes.ChatQueue.offerRecieved(ChatQueue.jav a:107)
at org.jivesoftware.fastpath.workspace.Workpane$ChatOfferListener.handleOffer(Work pane.java:567)
at org.jivesoftware.fastpath.workspace.Workpane$ChatOfferListener.access$600(Workp ane.java:547)
at org.jivesoftware.fastpath.workspace.Workpane$ChatOfferListener$1.run(Workpane.j ava:554)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)

Environment

None

Activity

Show:
wroot
June 16, 2013, 7:01 PM
Edited

User reports that replacing xstream.jar solved this, so the problem is with that library https://discourse.igniterealtime.org/t/fastpath-nullpointerexception/54075

Leon Roy
November 24, 2014, 3:02 PM

Hope no one minds me taking ownership of this. My company wants me to look at this so will verify the above mentioned fix checks out and create a pull request for it.

Daryl Herzmann
January 7, 2019, 2:47 AM
Moved to GH

Assignee

Unassigned

Reporter

wroot

Expected Effort

None

Ignite Forum URL

None

Components

Affects versions

Priority

Major