« Back to APIs

policy-violation while using XMPP over BOSH

Combination View Flat View Tree View
Threads [ Previous | Next ]
policy-violation while using XMPP over BOSH
jabber xmpp bosh persistance page refresh policy-violation policy error
Answer
7/12/12 10:26 PM
I'm experimenting with the ability to persist a jabber connection between browser page refreshes, and often seeing the following error when the cisco client tries to reconnect where it left off on a page load:
<stream:error
xmlns:stream="http://etherx.jabber.org/streams"><policy-violation
xmlns="urn:ietf:params:xml:ns:xmpp-streams"/></stream:error>
 
I can produce the error every few page clicks when using your SDK's examples/persistTest1.html example. It seems like i get the error consistenly unless i wait at least 5 seconds between page changes.
 
When introduce inbound messages to the picture, the error occurs immidately upon navigating to a new page, regardless of how long i wait before navigating.
 
Any thoughts?
 
I'm trying to get an idea for using cisco jabber on a multi-page site. If anyone has had success with this, i'd love to know. I'm curious the best approach to handle messages that are missed because users are inbetween page loads.
 
 

I'm experimenting with the ability to persist a jabber connection between browser page refreshes, and often seeing the following error when the cisco client tries to reconnect where it left off on a page load:
<stream:error
xmlns:stream="http://etherx.jabber.org/streams"><policy-violation
xmlns="urn:ietf:params:xml:ns:xmpp-streams"/></stream:error>
 
I can produce the error every few page clicks when using your SDK's examples/persistTest1.html example. It seems like i get the error consistenly unless i wait at least 5 seconds between page changes.


I've got the same error here, I suspect this is the expected behavior from server since it's preventing the high service loading when client keep requesting the login state. Will look into more details to confirm

When introduce inbound messages to the picture, the error occurs immidately upon navigating to a new page, regardless of how long i wait before navigating.


Could you please share the code and error here?

Yes it definitely seems like a rate throttling issue. I'd love more info.

As for supplying code for:
When introduce inbound messages to the picture, the error occurs immidately upon navigating to a new page, regardless of how long i wait before navigating.


It's the same policy-violation error, it just occurs as soon as the page loads. Again i'm using the SDK's examples/persistTest1.html example, but i'm having another logged in user sending messages. Here's the setup:

User A is using the persistTest1.html to login and simulate page reloading.

User B is logged in (to a standalone page with the chat client running) and sending User A instant messages every 5 seconds.

User A experiences the policy-violation error as soon as he does a page refresh. Without User B sending messages, the error doesn't occur as quickly.

I'm trying to see whether a user can successfully conduct a chat session while navigating between pages.

Any further thoughts on this? I'm trying to evaluate whether Cisco is a realistic option for doing jabber across browser page loads.

Thanks.

Hi Aaron,

If your application has to support multi-page and/or page reloads, have you considered using the Cisco SDK in a browser extension ? Firefox and Chrome allow extensions (also known as add-ons) to run in the background and be displayed in one or more pages. We have an internal prototype of an SDK-based phone extension, the registration and call state are maintained in the background, you could do the same with the IM connection and conversations.
I have never tried in Internet Explorer, I think it should be doable as well.

Thomas

Thanks Thomas. It's an interesting idea, but right now i'm more interested in knowing what the SDK can offer in a standalone browser page. Since the SDK ships with an example for persisting a jabber session between page loads, I assumed it was something Cisco felt was possible. If this is not the case, it's good to know since we're in an evaluation phase.

Is there a Cisco tech out there that cares to comment? I'd love to know whether my policy error is due to a Cisco limitation, or something that can be avoided knowing the system better.

Aaron

Hi Aaron,
Sorry for not responding here, I will try to reproduce the feature between the page loads. For the server rate throttling behavior, I would need to check with CUP team to see what they say about it.

Howard