Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events

LCDS 2.6 -> 3.1, now getting Server.Processing.NotSubscribed error

Avatar

Former Community Member

Ever since migrating our application (AIR Client, serverTomcat 6) from LCDS 2.6 to 3.1, I keep getting this error:


                          Fault Code: Channel.Polling.Error;    FaultString: error
Root Cause:        Fault Code: Server.Processing.NotSubscribed;    FaultString: The client has no active subscriptions over endpoint 'my-amf-polling'.

It happens at seemingly random times while the AIR client is connected to the server (both server and client running on the same machine).
If it fails, I get the error for a couple of operations (sometimes 10, 15, 20 seconds apart), but after a while things start working again.

It always happens when I perform large fill operations in order to cache data for future offline operation.


Does anyone have any ideas what changed from LCDS 2.6 to 3.1 that may cause this?

Any hints, ideas, advice, thoughts, .. are greatly appreciated!


Thanks,
Gerda

5 Replies

Avatar

Level 1

Hello,

Did you find a solution for your problem ?

I have the same problem and I realy don't know what to do.

Avatar

Employee

You should ensure that you have a channel connect handler function that will re-execute the fill when the server is reconnected.  Otherwise if a client is not connected for a while (or the server is restarted) the subscriptions it has to the fill will be gone and you may get a message like the one you are seeing.

Tom

Avatar

Level 2

Tom, Can you please provide more information on "channel connect handler function".

Avatar

Employee

You should establish an event handler on the DataService channel object that will get called on the CONNECT event.

Something likethe following:

channel.addEventListener(ChannelEvent.CONNECT, channelConnectHandler);

And have a function defined that re-executes fills if needed:

public function channelConnectHandler(event:ChannelEvent):void 
{
  myDataService.fill(...);
}

I am sorry I can't find a good example to point you to.  Our documentation needs one!

Tom