cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1332
Views
0
Helpful
10
Replies

Jabber Web SDK with 3 CUCM Servers

irvan
Level 1
Level 1

Hi Devnet Team,

Currently our customer has 3 cucm servers running on production with 1 publisher and 2 subscribers. Our customer using Jabber Web SDK for their Web Application and running on production environment with pointing to cucm publisher using setCUCMPServers("publisher_ip_address") function. If the cucm publisher server(publisher_ip_address) is down, their Web Application can't use all Jabber Web SDK functions and this is so critical for their business since they use for their 24x7 contact center.
For this case our customer can't using SRV because of conflict with another cucm cluster,so how the Jabber Web SDK can handle this issue ? Is it possible to use 3 cucm servers and the Jabber Web SDK can switch automatically and seamlessly to the another active cucm server when the cucm server that is being used by their Web Application is down ?

1 Accepted Solution

Accepted Solutions

dstaudt
Cisco Employee
Cisco Employee

UDS should be present/running and OK to use on any CUCM node - so you can use others for failover.

FYI I updated this sample with (now successful) discovery failover behaviour, if you want to compare notes: https://github.com/ciscodevnet/jabber-web-sample

View solution in original post

10 Replies 10

npetrele
Cisco Employee
Cisco Employee

By "Jabber Web SDK" I assume you mean Jabber Voice/Video, correct?  Not Jabber IM & Presence. 

If so, then what you're load balancing and configuring for fail over are devices the same as if they were hard phones. Read the sections on load balancing and redundancy for the version you're using. For example, here's some documentation on version 10:

https://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cucm/admin/10_0_1/ccmsys/CUCM_BK_SE5FCFB6_00_cucm-system-guide-100/CUCM_BK_SE5FCFB6_00_cucm-system-guide-100_chapter_0111.html

I can't find the same category of documentation for later versions, but I assume you have access to it already, since you have configured the cluster. 

If what you're talking about is the web application (which is not something you can host on a Cisco CUCM server), that's not a CUCM server problem. That's a web hosting problem. 

 

Yes, Jabber Web SDK Voice and Video. i don't know why but the Jabber Web SDK always pointing to one ip address, if the ip address is down the Jabber Web SDK will crash and stopped working.

npetrele
Cisco Employee
Cisco Employee

Also, here's an old reply to a similar question about CUCM 8.6. I believe the principles are still the same, though.

https://community.cisco.com/t5/ip-telephony-and-phones/cucm-8-6-registration-load-balancing/m-p/2119338#M216026

 

Here's a previous thread covering this topic: https://community.cisco.com/t5/audio-and-video-endpoints/jabber-web-sdk-discover-failover/td-p/4561374

I did a bit of testing, and can confirm your observations - i.e. that for authentication/sign-in the SDK only attempts to use the first server provided via setCUCMServers().  I tried a workaround where upon receiving onAuthenticationError() would switch server to the backup:

function onAuthenticationError(error)
{
    currentServer = (currentServer == cucmList.primary) ? cucmList.secondary : cucmList.primary;
    cwic.LoginController.signOut();
    cwic.LoginController.resetUserData();
    cwic.LoginController.setCUCMServers([currentServer]);
    var username = $UsernameField.val();
    var password = $PasswordField.val();
    cwic.LoginController.setCredentials(username, password);
    cwic.LoginController.signIn();
}

The authentication would succeed and devices would be retrieved, but would never receive onSignedIn() and any attempt to register the the softphone resulted in connection error...

So, it appears there are some problems with the SDK in this area - or at minimum the docs incorrectly state (and the code indirectly implies) that backup discovery servers are supported.

As touched on in the thread linked above, perhaps you could test the UDS API responsiveness for primary/backup servers in your code before performing setCUCMServers().  You should be able to just GET something like this, which should return a 401 if UDS is functioning normally: https://sjds-cucm14.cisco.com:8443/cucm-uds/foo/dstaudt/devices?max=1

A few general thoughts:

  • SDK authentication/mode seems to be modeled on the Jabber client's 'Cisco Communications Manager 9 or later' aka 'Phone' mode Screenshot from 2022-07-22 11-15-59.png
  • It seems the Jabber client itself does not support HA/failover for authentication when using non DNS SRV i.e. 'Use the following server', corresponding to the SDK setCUCMServer() Screenshot from 2022-07-22 11-19-12.png
  • As it does not seem that the Jabber client supports the scenario you're trying, it makes a certain amount of sense that the SDK also does not support it (notwithstanding the doc/behaviour issues mentioned above).
  • DNS SRV does seem like the indicated solution for authentication HA (certainly for the client) - curious for more details about why this is not practical in your situation..?

i did the same workaround to the jabber web SDK like you did. you need to make sure the resetUserData() is succeed and clear the previous login data before you are login again.

UDS API is the part of CUCM API right ? so if we request to the API and then the response is OK, we can use that server to login Jabber Web SDK ?

We can't using DNS SRV because of conflict with another cluster CUCM.

dstaudt
Cisco Employee
Cisco Employee

UDS should be present/running and OK to use on any CUCM node - so you can use others for failover.

FYI I updated this sample with (now successful) discovery failover behaviour, if you want to compare notes: https://github.com/ciscodevnet/jabber-web-sample

the UDS API need CORS configured on the CUCM Web. If i add domain to the cors setting, is it any cucm service need to restart ?

i've been checked your code and still testing in our environment. thank you.

dstaudt
Cisco Employee
Cisco Employee

I don't recall having to restart any services when adding CORS domains, but it's been awhile since I tested it...

Note, that should only be necessary if you're going to ping the UDS URL youself via in-browser JavaScript - the Jabber add-on doesn't run in the browser context and shouldn't need CORS.

yes, i tried ping to the UDS URL via browser and always return the CORS Policy. how about the jabber-config.xml url ? is it possible to check the cucm server is active or not from that url ?

dstaudt
Cisco Employee
Cisco Employee

Any HTTP request from in-browser JS will require CORS (and I don't think you can enable CORS for config file download service...)

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: