Bulidin tcl library fuction?

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Bulidin tcl library fuction?

  • Creator
    Topic
  • #49150
    Hongle Sun
    Participant

    Does anyone can point me out, in cloverleaf, is (are) there any built_in tcl library or function we can use, to check the status of procesees/thread or check the IB/OB messages queued within a thread(s)? thanks

Viewing 5 reply threads
  • Author
    Replies
    • #60906
      Jonathan Hamilton
      Participant

      There is a NetConfig api which is located in $HCIROOT/tcl/lib/cloverleaf/nci.tcl which allows you to query your NetConfig file for configuration settings.

      As far as checking the status of a running engine etc. the best option is to simply exec the ksh command in Tcl.  I.E.  set tStatus [exec hciconnstatus -c ].  You can also combine with grep, egrep and awk to limit your output.

      For statistics use the MSI Tcl extensions.  They are documented in the Users Guide and just about anything statistical can be found in them.

      Regards,

      Jonathan Hamilton

      HCA Healthcare.com

    • #60907
      Charlie Bursell
      Participant

      Be careful with the liripts.  Those are old scbarary calls to read the NetConfig .  Those are old scripts.  Whe they were written all thread and process names had to be lower case.  As such all thread and process names are returned in lower case.  You may bet mis-leading results.

      As for thread status, usi the msi calls.

    • #60908
      Mark Thompson
      Participant

      Someone must have fixed the scripts in a later version.  The ones that shipped with 5.3 & 5.4.1 don’t seem to have that problem.  I have a site with processes named BIG_PROCESS, little_process and Mixed_Process.  Their corresponding threads are named UPPER, lower and Mixed.

      Code:

      $ hcitcl
      hcitcl>netcfgLoad
      1
      hcitcl>netcfgGetProcList
      little_process BIG_PROCESS Mixed_Process
      hcitcl>netcfgGetConnList
      UPPER lower Mixed
      hcitcl>netcfgGetProcConns BIG_PROCESS
      UPPER
      hcitcl>exit


      Anyone who uses the nci.tlib procs should be aware they are not supported and may not be included or work properly with future Cloverleaf versions.

      - Mark Thompson
      HealthPartners

    • #60909
      Charlie Bursell
      Participant

      Those are not the commands I was referring to.  If you want to read the thread configuration, you get a keyed list.

      For example:

      set netconfig [file join $HciSiteDir NetConfig]

      nfLoad $netconfig processData hostData xlateData NetFilePrologue

      The array processData is indexed by each process name and contains a keyed list of it’s configuration.  Likewise hostData is an array indexed by thread names containing a keyed list of the thread configuration.

      For example:

      keylkeys hostData(input)

      SYMNAME AUTOSTART BITMAP COORDS CURXACTION DATAFORMAT DATAXLATE EOCONFIG GATEWAY THREADTYPE GROUPS HOSTDOWN KEEPMSGONDISK OUTBOUNDONLY PROCESSNAME PROTOCOL RECVC

      ONTROL REPLYFORMAT REPLYCONTROL REPLYXLATE SAVEMSGS SENDDATACTRL SENDREPLYCTRL SMS STARTPROCS USERECOVERDB

      It is these thread and process names that are always in lower case.

      If what you are doing fits your need, it’s OK.

    • #60910
      Bob Richardson
      Participant

      Greetings,

      Charlie, I am looking at some code that you had sent me a couple of weeks ago which checks if files are ready to process.  You referenced

      the nfLoad utility.  I have never heard about this guy until studying your code and finding this post.

      Is there any documentation on this utility and similar utilities in Cloverleaf that can save us a lot of grief and “redesigns of wheels”?

      Please advise… This is the kind of stuff that I had hoped to find out in my Cloverleaf Level certifications – maybe some sort of post Level III “piled higher and deeper” class could be offered to delve into the inner mysteries of Cloverleaf?

      Thanks again – continuing to learn as I grow older… (I hope).

    • #60911
      Charlie Bursell
      Participant

      These are internals that are not really meant to be used by the general public.  They are written for us (Quovadx) to do our thing.  They are there and if you want to use them, use at your own risk.  All of these are under $HCROOT/tcl/lib/cloverleaf.  They all use the old Tcl library method.

Viewing 5 reply threads
  • The forum ‘Cloverleaf’ is closed to new topics and replies.

Forum Statistics

Registered Users
5,117
Forums
28
Topics
9,292
Replies
34,435
Topic Tags
286
Empty Topic Tags
10