Ignore:
Timestamp:
Jun 5, 2006 9:21:06 PM (15 years ago)
Author:
mmc
Message:

Fixed nanovis to take a series of server names as a comma-separated
list, and to try them one after another to make a connection. That
way, if one server is down, you can still reach the rest of the farm.

Added a customized bug handler that looks a little less frightening
than the standard Tcl dialog. Someday, this should log all errors
to a web service, but for now, it just encourages the user to do so.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gui/scripts/field3dresult.tcl

    r460 r462  
    4040
    4141    # resources file tells us the nanovis server
    42     public common _nanovisHost ""
    43     public common _nanovisPort ""
    44     public proc setNanovisServer {name} {
    45         if {[regexp {^([a-zA-Z0-9\.]+):([0-9]+)$} $name match host port]} {
    46             set _nanovisHost $host
    47             set _nanovisPort $port
     42    public common _nanovisHosts ""
     43    public proc setNanovisServer {namelist} {
     44        if {[regexp {^[a-zA-Z0-9\.]+:[0-9]+(,[a-zA-Z0-9\.]+:[0-9]+)*$} $namelist match]} {
     45            set _nanovisHosts $namelist
    4846        } else {
    49             error "bad nanovis server address \"$name\": should be host:port"
     47            error "bad nanovis server address \"$namelist\": should be host:port,host:port,..."
    5048        }
    5149    }
     
    7270    array set flags $args
    7371
    74     if {"" != $_nanovisHost && "" != $_nanovisPort && $flags(-mode) != "vtk"} {
     72    if {"" != $_nanovisHosts && $flags(-mode) != "vtk"} {
    7573        itk_component add renderer {
    76             Rappture::NanovisViewer $itk_interior.ren \
    77                 $_nanovisHost $_nanovisPort
     74            Rappture::NanovisViewer $itk_interior.ren $_nanovisHosts
    7875        }
    7976        pack $itk_component(renderer) -expand yes -fill both
Note: See TracChangeset for help on using the changeset viewer.