Problem: Messages acumulating in inbound thread

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Problem: Messages acumulating in inbound thread

  • Creator
    Topic
  • #53852
    Gabriel Mendes
    Participant

      Hi all, I have one problem with my threads. I have one thread reading a XML file, converting into a CSV via tcl script, XLATING to a HL7 and sending to a host via LLP.

      The fileset local is reading the files and making the conversion, sending by mllp correctly and the files are being correctly deleted from the folder. However, looks like the messages are not being cleared from the buffer, because in my next iteration, even if I have no file to be readen, Cloverleaf still re-sends all messages that it has already send and they all are accumulated .

      Here is the result of a select in my Cloverleaf database:

      Code:


      Command Issued: hcidbdump -r
      Command status:0
      Command output:

                             C  
                             l T
                             a y F
                             s p w
      Created  Message Id     s e d Prio State Length Source          Dest
      ——– ————– – – – —- —– —— ————— —————
      16:01:04      [0.0.881] P D N 5120     1   1492 Read_XML                      
      16:00:33      [0.0.862] P D N 5120     1   1492 Read_XML                      
      16:00:17      [0.0.854] P D N 5120     1   1492 Read_XML                      

      Done. 3 messages selected

      Thanks in advance

    Viewing 2 reply threads
    • Author
      Replies
      • #79187
        James Cobane
        Participant

          Gabriel,

          In your tcl that is converting from XML to CSV, are you handling the disposition of the original message handle (i.e. $mh)?  It looks like you are not KILL’ing the orgininal message handle so the message continues to hang in the recovery database at state 1.  I’m assuming that you are creating a new CSV message (and handle) from the XML data, but you need to disp the original message handle as well.

          Hope that makes sense.

          Jim Cobane

          Henry Ford Health

        • #79188
          Brandon Grudt
          Participant

            What that boils down to, you want to make sure that if you no longer need the message you have the:

            return “KILL $mh”

            line at the end of your script.

          • #79189
            Gabriel Mendes
            Participant

              James and Brandon,

              Thank you very much for your replies

              In fact, it worked!

              I appended in my dispList a KILL command of my inbound message (XML) and continued a message that I created with the CSV in my message object. Here is my Code:

              Code:


                  set msg [msgcreate -recover $csv]
                  lappend dispList “CONTINUE $msg”
                  lappend dispList “KILL $mh”

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