Results 1 to 4 of 4
  1. #1
    Member
    Join Date
    Jun 2010
    Location
    Madurai
    Posts
    5

    SetDomain and SetLSHost() problem

    I have used the following code to connect the LightStreamer.

    Code:
    $wnd.page = new $wnd.PushPage();
    $wnd.page.context.setDomain("www.MyCompany.com");		
    $wnd.page.onEngineCreation = function(engine) {
    $wnd.lsEngine = engine;
    						
    	engine.connection.setLSHost("push.MyCompany.com");			
         engine.connection.setLSPort("9090");			
         engine.connection.setAdapterName("BrowserToLSToTWS");					
         engine.connection.setUserName(username);
         engine.connection.setPassword(password);
    It works fine while my host file have the following entry

    127.0.0.1 www.MyCompany.com
    127.0.0.1 push.MyCompany.com

    Now I try to launch the same application on my client Machine with the following code

    Code:
    $wnd.page = new $wnd.PushPage();
    $wnd.page.context.setDomain("ClientCompanyName.co.ke");		
    $wnd.page.onEngineCreation = function(engine) {
    $wnd.lsEngine = engine;
    						
    	engine.connection.setLSHost("push.Servername.ClientCompanyName.co.ke");			
         engine.connection.setLSPort("9090");			
         engine.connection.setAdapterName("BrowserToLSToTWS");					
         engine.connection.setUserName(username);
         engine.connection.setPassword(password);
    where my client web server name and host name as follows

    WebServerName : ClientCompanyName.co.ke
    HostName : push.Servername.ClientCompanyName.co.ke

    Now I try to browse the application. I canít connect with the LS. But once I put the Host file entries like ..

    <ClientIP> ClientCompanyName.co.ke
    <ClientIP> push.Servername.ClientCompanyName.co.ke

    Then it connect with LS.

    Where I am wrong and where do I need to code for this case?
    Kindly help me to solve this prob.

  2. #2
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    Hi,
    you're probably in a situation similar to the following one:
    In special cases, the consistency rules may be browser dependent. For instance, if the Web Server hostname has the short form mycompany.com and Lightstreamer Server hostname has the form push.mycompany.com, the "mycompany.com" domain has been found not to be accepted by Internet Explorer prior to version 8 (hence, no domain setting is available in this case, as "com" is too broad to be accepted). The limitation affects all cases in which the domain name is the same as the hostname.
    so you should change the hostname of the web server to something like www.ClientCompanyName.co.ke

    more details here: http://www.lightstreamer.com/docs/cl...html#setDomain

    Let me know if this solution doesn't work.

  3. #3
    Member
    Join Date
    Jun 2010
    Location
    Madurai
    Posts
    5
    Thank you very much for Quick Reply.

    so you should change the hostname of the web server to something like www.ClientCompanyName.co.ke
    Is that meant to put the host file entry like?

    <ClientIP> www.ClientCompanyName.co.ke
    <ClientIP> push.Servername.www.ClientCompanyName.co.ke

    Or change the machine name as "www.ClientCompanyName.co.ke"

  4. #4
    Power Member
    Join Date
    Jul 2006
    Location
    Cesano Maderno, Italy
    Posts
    784
    on your production machines you should change the host name of the web server to "www.ClientCompanyName.co.ke" while keeping the host name of the Lightstreamer server to "push.ClientCompanyName.co.ke"

 

 

Similar Threads

  1. setDomain with IP address issue.
    By Sathyaayyanar in forum Client APIs
    Replies: 1
    Last Post: August 21st, 2010, 04:29 PM
  2. SetDomain setLSHost related issue
    By Sathyaayyanar in forum Client APIs
    Replies: 1
    Last Post: July 30th, 2010, 02:32 PM
  3. SetDomain Inconsistent with setLSHost
    By Sathyaayyanar in forum Adapter APIs
    Replies: 3
    Last Post: July 20th, 2010, 06:04 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT +1. The time now is 02:34 PM.