I'm trying to find the table that joins Orion.Group (or Orion.Container) to Orion.APM.Applications.
The Orion.ContainerMembers table only have information about Nodes, but I can't find applications there.
Thank you juniordev. I managed to find what I needed with the following query:
SELECT app.NodeID as NodeId, app.ApplicationID as AppID, app.FullyQualifiedName as AppName, c.Name as GroupName
FROM Orion.APM.Application app
LEFT JOIN Orion.ContainerMemberSnapshots cms on cms.MemberUri = app.Uri
LEFT JOIN Orion.Container c on c.ContainerID = cms.ContainerID
I know it is not completely correct but maybe it is helpful for you. This code gives you for a node applications.
SELECT cm.ContainerID, n.Caption, apps.Name
FROM Orion.ContainerMembers cm
inner join Orion.Nodes n on CONCAT('swis://<hostname>/Orion/Orion.Nodes/NodeID=', n.NodeID) = cm.MemberUri
inner join Orion.APM.Application apps on apps.NodeID = n.NodeID
WHERE MemberEntityType = 'Orion.Nodes'
AND n.NodeID = 12009
You must change <hostname> info according to your system/hostname. And this code referred to Orion.Nodes Entity Type. You should change for that your purpose.
How often is ContainerMemberSnapshots updated ?
Also how is it updated ?
The ContainerMemberSnapshots are being updated so often, how you set the refresh frequency when creating the container (the first screen when adding/editing the group). It's by default set to 1 minute, so basicaly this means, that each minute there's evaluated the group membership ("Dynamic query" conditions + Static members), calculated the group availability and the tables are updated (as well as the account limitations based on the Containers are applied).
This is an interesting question.
I was baffled by this too, but as I was querying SWQL Studio for and API query to use, using ContainerMemberSnapshots was the table that actually reflected what I see in the Solarwinds UI.
I've tried adding nodes / apps / components / etc to groups and checked what was the behaviour in the ContainerMemberSnapshots table, and that is the one that seems to be updated. Would it be possible that there are more tables linking Groups to other entities in SW?
Hi Jan, This is not the case I see here on my installation of Solarwinds Version: "Orion Platform 2014.1.0, SAM 6.1.1, NPM 10.7, IVIM 1.9.0"
In here, I get the impression that the ContainerMembeSnapshot table is refreshed along the SW UI. Could it be that my refresh rate is set in some weird way to refresh every 0 seconds or anything along those lines that would give me the impression it's updating in realtime?
Would you know which tables the "Dynamic query" conditions + Static members are that defines group membership as per SW UI?
Well reffreshing in realtime is pretty suicidal idea since it's very expensive to compute. The mimimum allowed frequency is 60 seconds. It's of course possible to modify it in the Database, but I really don't recommend it.
The definitions for the group membership you'll find in the table ContainerMemberDefinitions. You'll recognize the static from dynamic definitions the way, that in column definition you'll find: