Duong_Nguyen-Nhat_2335

How to escape curly brackets in Dynamic Property

Discussion created by Duong_Nguyen-Nhat_2335 on Jul 29, 2016
When you need to create a Dynamic Property of type Short Text. This Dynamic Property will contain a JSON document. This Dynamic Property needs to be an Expression because It will be pulling values from other Dynamic Properties.

But as most of you know, a JSON document has curly brackets. In Expressions, curly brackets are expected to contain the reference to another dynamic property.

Here is the example Expression :

{
"AGGSERVICE_URL": "{/cloudfoundry/hostname}.west-1.fe.gopivotal.com"
}

And you want to escape the curly brackets on the 1st and 3rd lines.

For now it's kind of limitation of Dynamic Properties. But we do have a workaround for this as below:

- Create 2 dynamic properties of type Single Line Text
- Value of the first dynamic property is {
- Value of the second dynamic property is }

And then you can set your dynamic property like: {first_dynamic} your JSON document {second_dynamic}

Outcomes