Announcement

Collapse
No announcement yet.

Use of configuration map in connection properties

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Use of configuration map in connection properties

    I've recently been trying to convert a lot of channels to use the configuration map.

    I have got a problem today with an smb writer connection where I have replaced the hardcoded username and password fields with variables from the config map.

    e.g. username was DOMAIN\Mirth and is now ${ESTH_Domain}\${ESTH_Domain_Mirth_Username}

    I'm now getting : QUEUED: Error writing file [SmbAuthException: Logon failure: unknown user name or bad password.]

    If I change the username back and hardcode it, but leave the config map item in for the password it works.

    Have I got a problem here because I am trying to use two different map variables in combination?

    Simon

  • #2
    Multiple variables like that should work just fine... Maybe it got queued before you set those values in the config map, and you don't have Regenerate Template enabled?
    Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

    Nicholas Rupley
    Work: 949-237-6069
    Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


    - How do I foo?
    - You just bar.

    Comment


    • #3
      Its not that - I changed it to regenerate template because I knew it would use the original values.

      Just to do a further test, I created a new config map item where the domain and username are already joined.

      I've put this in and it works, so changed back to the separate ones with '\' in between tried again and it failed. I think there is a genuine problem here. Perhaps it is because I used such long map names?

      Do you think you could attempt to reproduce this?

      Comment


      • #4
        Ah I see now... yes that is because of the backslash there. Velocity treats that as an escape character, so it thinks that you're trying to escape the "$" character that comes after it. So in your template use this instead:

        Code:
        ${ESTH_Domain}\\${ESTH_Domain_Mirth_Username}
        Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

        Nicholas Rupley
        Work: 949-237-6069
        Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


        - How do I foo?
        - You just bar.

        Comment


        • #5
          Excellent Nick. See... I do need a demo / velocity tutorial! That works just fine.

          Comment


          • #6
            Velocity itself has some good documentation: http://click.apache.org/docs/velocity/user-guide.html
            Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

            Nicholas Rupley
            Work: 949-237-6069
            Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


            - How do I foo?
            - You just bar.

            Comment


            • #7
              Following on from our communication yesterday, I cannot get any configuration map items to work in the DICOM connectors for Host, Port or Application Entity. Is this a problem restricted to DICOM or are there other connectors where this does not seem to be compatible?

              Comment


              • #8
                Here is the error:
                DICOM Sender error
                ERROR MESSAGE: ${Astraia_PACS_Send_Host}: unknown error

                Comment


                • #9
                  Ah yes... for the DICOM connectors, unfortunately right now not all of the fields support Velocity replacement. We have an open issue for that: MIRTH-2800
                  Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

                  Nicholas Rupley
                  Work: 949-237-6069
                  Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


                  - How do I foo?
                  - You just bar.

                  Comment

                  Working...
                  X