Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a client who would like to be able to group streams, apps etc. in different categories in the Operations Monitor.
I was thinking of using tags in the QMC to do this. But is there any way of retrieving those tags in the current Operations Monitor?
The client is currently on June 2018 - 12.26.1
Thank you in advance for any help you might be able to provide.
Hi, let's do some small modification in loadscript. It will be easy. It is almost prepared (depends on version of app)
jump to the part of code "qrs_appobject" and do few changes:
Look for my changes in parts where you see MY_APP_TAGs and MY_TAG_KEY
RestConnectorMasterTable:
SQL SELECT
"id" AS "id_u2",
"engineObjectId",
"createdDate",
"modifiedDate",
"modifiedByUserName",
"description",
"objectType",
"publishTime" AS "publishTime_u0",
"published" AS "published_u0",
"approved",
"name" AS "name_u2",
"__KEY_root",
(SELECT
"userId",
"userDirectory",
"__FK_owner"
FROM "owner" FK "__FK_owner"),
(SELECT
// "id" AS "id_u0",
"name" AS "MY_APP_TAGs",
// "privileges" AS "privileges_u0",
"__FK_tags"
FROM "tags" FK "__FK_tags"),
// (SELECT
// "@Value",
// "__FK_tags"
// FROM "tags" FK "__FK_tags" ArrayValueAlias "@Value"),
(SELECT
"id" AS "id_u1",
"__KEY_app",
"__FK_app"
FROM "app" PK "__KEY_app" FK "__FK_app")
FROM JSON (wrap on) "root" PK "__KEY_root";
LET NumRows_monitor_apps_REST_appobject = NoOfRows('RestConnectorMasterTable');
[tags]:
LOAD MY_APP_TAGs,
[__FK_tags] AS MY_TAG_KEY
RESIDENT RestConnectorMasterTable
WHERE NOT IsNull([__FK_tags]);
Also one more little change
AppObject:
LOAD
[id_u2] AS AppObjectId,
[engineObjectId],
date(alt(
date#(left(createdDate,10),'YYYY-MM-DD'),
date#(left(createdDate,10),'YYYY/MM/DD'),
date#(left(createdDate,10),'MM-DD-YYYY'),
date#(left(createdDate,10),'MM/DD/YYYY'),
date#(left(createdDate,10),'YYYY.MM.DD'),
'No valid date')
) as [App Object Created Date],
date(alt(
date#(left(modifiedDate,10),'YYYY-MM-DD'),
date#(left(modifiedDate,10),'YYYY/MM/DD'),
date#(left(modifiedDate,10),'MM-DD-YYYY'),
date#(left(modifiedDate,10),'MM/DD/YYYY'),
date#(left(modifiedDate,10),'YYYY.MM.DD'),
'No valid date')
) as [App Object Modified Date],
[modifiedByUserName] AS [App Object Modified By],
[description] AS [App Object Description],
[objectType] AS [App Object Type],
if(left(publishTime_u0,4)='1753','Never',timestamp([publishTime_u0])) AS [App Object Publish Time],
If(lower([published_u0])='true',dual('Published',1),dual('Unpublished',0)) AS [App Object Published],
If(lower([approved])='true',dual('Approved',1),dual('Not Approved',0)) AS [App Object Approved],
If(lower(objectType)='sheet',
If(lower([published_u0])='true',
If(lower([approved])='true','Base Sheet','Community Sheet'),
'Private Sheet'),
Null()) AS [Sheet Type],
If(lower(objectType)='sheet',name_u2) AS [Sheet Name],
[name_u2] AS [App Object Name],
[__KEY_root] AS MY_TAG_KEY, // Will only need __KEY_root with tags or custom properties
ApplyMap('owner_map',__KEY_root,'Missing App Object Owner') AS [App Object Owner],
ApplyMap('app_map',__KEY_root,'Missing App') AS ObjectId // This is AppId to link to the App
RESIDENT RestConnectorMasterTable
WHERE NOT IsNull([__KEY_root]);
I don't know if that is Integrated into the out of the box App. you should be able to use the data model viewer to see this or maybe selection tools as you can search field-names there. if it is not possible just ask the Sysadmin to duplicate it and transfer ownership to you.
You will likely need to customize it and hit the rest endpoints and add code to extract the Tags, I know custom properties are exposed in the Apps rest endpoint used by the operations monitor Tags are likely present as well.
However for the case you describe I'd lean towards custom properties as there is a great deal more control over the structure where as tags are kinda free-from and can apply to everything.
Hi, I did it today - tags for sheets in monitoring app. If still interested, I will help
Hi @lmcsedyz - I am keen to also do this - would appreciate any tips/walkthroughs to achieve this .. many thanks
Hi, let's do some small modification in loadscript. It will be easy. It is almost prepared (depends on version of app)
jump to the part of code "qrs_appobject" and do few changes:
Look for my changes in parts where you see MY_APP_TAGs and MY_TAG_KEY
RestConnectorMasterTable:
SQL SELECT
"id" AS "id_u2",
"engineObjectId",
"createdDate",
"modifiedDate",
"modifiedByUserName",
"description",
"objectType",
"publishTime" AS "publishTime_u0",
"published" AS "published_u0",
"approved",
"name" AS "name_u2",
"__KEY_root",
(SELECT
"userId",
"userDirectory",
"__FK_owner"
FROM "owner" FK "__FK_owner"),
(SELECT
// "id" AS "id_u0",
"name" AS "MY_APP_TAGs",
// "privileges" AS "privileges_u0",
"__FK_tags"
FROM "tags" FK "__FK_tags"),
// (SELECT
// "@Value",
// "__FK_tags"
// FROM "tags" FK "__FK_tags" ArrayValueAlias "@Value"),
(SELECT
"id" AS "id_u1",
"__KEY_app",
"__FK_app"
FROM "app" PK "__KEY_app" FK "__FK_app")
FROM JSON (wrap on) "root" PK "__KEY_root";
LET NumRows_monitor_apps_REST_appobject = NoOfRows('RestConnectorMasterTable');
[tags]:
LOAD MY_APP_TAGs,
[__FK_tags] AS MY_TAG_KEY
RESIDENT RestConnectorMasterTable
WHERE NOT IsNull([__FK_tags]);
Also one more little change
AppObject:
LOAD
[id_u2] AS AppObjectId,
[engineObjectId],
date(alt(
date#(left(createdDate,10),'YYYY-MM-DD'),
date#(left(createdDate,10),'YYYY/MM/DD'),
date#(left(createdDate,10),'MM-DD-YYYY'),
date#(left(createdDate,10),'MM/DD/YYYY'),
date#(left(createdDate,10),'YYYY.MM.DD'),
'No valid date')
) as [App Object Created Date],
date(alt(
date#(left(modifiedDate,10),'YYYY-MM-DD'),
date#(left(modifiedDate,10),'YYYY/MM/DD'),
date#(left(modifiedDate,10),'MM-DD-YYYY'),
date#(left(modifiedDate,10),'MM/DD/YYYY'),
date#(left(modifiedDate,10),'YYYY.MM.DD'),
'No valid date')
) as [App Object Modified Date],
[modifiedByUserName] AS [App Object Modified By],
[description] AS [App Object Description],
[objectType] AS [App Object Type],
if(left(publishTime_u0,4)='1753','Never',timestamp([publishTime_u0])) AS [App Object Publish Time],
If(lower([published_u0])='true',dual('Published',1),dual('Unpublished',0)) AS [App Object Published],
If(lower([approved])='true',dual('Approved',1),dual('Not Approved',0)) AS [App Object Approved],
If(lower(objectType)='sheet',
If(lower([published_u0])='true',
If(lower([approved])='true','Base Sheet','Community Sheet'),
'Private Sheet'),
Null()) AS [Sheet Type],
If(lower(objectType)='sheet',name_u2) AS [Sheet Name],
[name_u2] AS [App Object Name],
[__KEY_root] AS MY_TAG_KEY, // Will only need __KEY_root with tags or custom properties
ApplyMap('owner_map',__KEY_root,'Missing App Object Owner') AS [App Object Owner],
ApplyMap('app_map',__KEY_root,'Missing App') AS ObjectId // This is AppId to link to the App
RESIDENT RestConnectorMasterTable
WHERE NOT IsNull([__KEY_root]);