Azure-Sentinel
Azure-Sentinel copied to clipboard
Fixed 'jsonData' parameters and removed escape characters
Required items, please complete
Change(s):
- Updated workbook defintion for DataCollectionHealthMonitoring.json
Reason for Change(s):
- Json had incorrect parameters 'jsonData' which caused deployments from code to fail. Improper serialization. These improperly defined object will remain even if you export it again for deployment from an automated pipeline for example. I tested out this updated version which I now can properly import and export as much as I want.
Version updated:
- Yes
Testing Completed:
- Yes
Checked that the validations are passing and have addressed any issues that are present:
- See guidance below
Hi @TheCloudScout, We will review the changes and provide feedback. Thanks
Hi @TheCloudScout,
I'm getting below error while trying to test the workbook
whereas it's working as expected from the previous version of the workbook
Hi @TheCloudScout, Can you please suggest if Im missing something here. Thanks
Hi @TheCloudScout, Can you please suggest if Im missing something here. Thanks
I'm sorry for the late reply. I checked my changes and found the error. Right after I've created the pull request, I thought that I needed to update its version as mentioned in the guidelines.
On line 2 I changed:
"version": "Notebook/1.0",
and "version": "KqlParameterItem/1.0",
into:
"version": "Notebook/1.1",
and "version": "KqlParameterItem/1.1",
Which broke the template. So I've reverted this back.
Please try again, you'll notice that it works again.
The reason for this change (jsonbody) was mainly because we couldn't deploy the template as an ARM template from an automated pipeline. The Azure DevOps agents breaks on an error because of the json escaping within the jsonbody. By expanding this and removing the escape characters, it works flawlessly now on my end. I haven't made any changes to other parts of this workbook template.
Hi @TheCloudScout, Thanks for the updated workbook. I will review and share the feedback Thanks
Hi @TheCloudScout, I'm occupied with priority work. I will review and share the feedback soon. Thanks
Hi @TheCloudScout, I'm occupied with priority work. I will review and share the feedback today. Thanks
Hi @TheCloudScout,
Thanks for the quick fix. Now I'm able to view the dashboard properly but still there are few queries were failing. Can you please check and confirm from your end.
Thanks
Thanks @v-mchatla for you thorough testing! And you're very right! I completely missed the fact that these help functions stopped working, I was only focussen on the graphs and lists.
The main reason why I wanted to correct/update this template is because it was giving me issues when deploying it as an ARM template from an automated pipeline. Apparently the jsonData
is required to remain a string in a single line, instead of expanded into actual json rows.
I went back to my initial issue and fixed it by reverting the jsonData
lines back to its original state, and putting it between a string()
function in my ARM template:
"jsonData": "[string('[{ \"value\": \"Yes\", \"label\": \"Yes\"},\r\n {\"value\": \"No\", \"label\": \"No\", \"selected\":true }]')]"
Because we both spend quite some effort in this pull request, let's make sure it wasn't for nothing! ;-) I still was able to correct two very minor things:
- I found a placeholder/leftover subscriptionId which should be removed I guess
- Fixed indentation on the last few lines.
Let me know what you think.
Hi @TheCloudScout, Thanks for the detailed explanation. I will try to review and share my thoughts. Thanks
Hi @TheCloudScout, Sorry, I didnt get a chance to work on this from last 2days, I will allocate sometime today for this and share you the update. Thanks
Hi @TheCloudScout, Please expect some delay as we are occupied with priority work. Thanks
Hi @TheCloudScout, Can you please fix the version details, so that I can merge the PR. Thanks
Changes look good. Need one small change - please increment the version in workbook metadata file. Currently its 1.0.0 update it to 1.0.1
Sorry wasn't aware of this metadata file. I've updated the version.
Thanks for all of your efforts and feedback on this change!
Hi @TheCloudScout, please try pushing this branch again by taking latest from master since some checks have not been completed. Thanks.
@TheCloudScout, changes looks good, just update the branch once from master for the checks to run. Thanks.
Hi @TheCloudScout, Can you try taking latest from master, checks need to be completed in order to proceed with approval. Thanks
Hi @v-sabiraj, @v-mchatla, @v-atulyadav,
I've made a slight change by compacting the WorkbooksMetadata.json
to trigger a re-run on all tests. And this appeared to be working since all tests are currently running.