Forum Discussion

FPKELD2019's avatar
FPKELD2019
Occasional Contributor
6 years ago

Can not get Properties to work with MQ connection of AMQP plugin

Hi SmartBear,

 

ReadyAPI v2.8 Pro.

 

We have not succeed in getting Properties to work with AMQP plugin MQ configuration.

 

The issue we see is with Properties:

  1. Cannot get project properties to work with AMQP plugin connection configuration. We create a project property called “ourProperty” and inserted ${#Project#ourProperty} as Host value in AMQP plugin connection configuration. When running AMQP step we get message “Unable to declare exchange due to the following error: Unable to create AMQP connection due to the following error: ${#Project#ourProperty } ${#Project#ourProperty}”.

 

Could you please point to an example of Properties that work with plugin AMQP MQ connection configuration?

 

Regards
Keld

  • Hi FPKELD2019 

     

    I can't help with your AMQP issue (point 1 of  your post) as I don't have an AMQP MQ to test against - but regarding point 2 of your post - you said you're publishing json payloads via the Queue and you're using a the DataGen test step to do it?

    I don't bother with that - when I need a unique GUID created dynamically in my payloads I just hardcode the following dynamic script snippet into the json's GUI attribute value as follows:

     

    {
    "GUIDAttribute" : "${=java.util.UUID.randomUUID()}"
    }

    In regards to point 1 - if you're sure you're tried the normal property handling  - then I'd raise a ticket with Smartbear - link as follows: https://community.smartbear.com

     

    I know hasn't helped with point1, but this might help with point2 and if you use this it will get you around the AMQP property issue.

     

    Cheers,

     

    rich

     

  • richie's avatar
    richie
    Community Hero

    Hi FPKELD2019 

     

    I can't help with your AMQP issue (point 1 of  your post) as I don't have an AMQP MQ to test against - but regarding point 2 of your post - you said you're publishing json payloads via the Queue and you're using a the DataGen test step to do it?

    I don't bother with that - when I need a unique GUID created dynamically in my payloads I just hardcode the following dynamic script snippet into the json's GUI attribute value as follows:

     

    {
    "GUIDAttribute" : "${=java.util.UUID.randomUUID()}"
    }

    In regards to point 1 - if you're sure you're tried the normal property handling  - then I'd raise a ticket with Smartbear - link as follows: https://community.smartbear.com

     

    I know hasn't helped with point1, but this might help with point2 and if you use this it will get you around the AMQP property issue.

     

    Cheers,

     

    rich

     

    • FPKELD2019's avatar
      FPKELD2019
      Occasional Contributor

      Hej Rich,

       

      Your solution makes it possible to insert GUID’s in JSON. Thanks.

       

      Have a (minor?) extra challenge, need to insert the same GUID twice into the JSON message in step AMQP Publish. Not sure how to solve.

       

      Regards

      Keld

      • sonya_m's avatar
        sonya_m
        SmartBear Alumni (Retired)

        richie great job as always! 

         

        FPKELD2019 as for the ‘extra challenge’ of yours, could you create a new topic for this part? It would be much easier to locate in the Community then!

         

        In the meantime, I'll mark richie's reply as a solution in this thread.