This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Dynamic Managed Component question

I would like to create a dynamic managed component query to create a service. I would like the service to contain Net Monitor Devices but only those that also have an Oracle agent on the host that the Net Monitor is checking. I was hoping to use a query such as:

NetMonitorDevice where deviceReference.referredObject.agents instanceof DBO_Agent_Model 

but this does not work as an error says the NetMonitorDevice does not have a property "agents". I thought I was doing a "walk along a property path" because I could follow this path in the script console, but maybe not.

Is what I would like to do possible?

Thanks,

Kris 

Parents
  • So, I tried a different approach:

    NetMonitorDevice where deviceReference.referredObject.agents in (Agent where topologyTypeName = 'DBO_Agent_Model')

    and I get the same error:

    QueryException: java.lang.IllegalArgumentException: Type 'foglight-5:NetMonitorDevice:7' does not have a property with the name 'agents'

    However if I deliberately make a mistake in the query and look for a property called agent, I get this:

    NetMonitorDevice where deviceReference.referredObject.agent in (Agent where topologyTypeName = 'DBO_Agent_Model')

    QueryException: java.lang.IllegalArgumentException: Type 'foglight-5:Host:21' does not have a property with the name 'agent'

    So it looks like the walk down the property path is working but when it gets to the Host object it can't find the property agent, which is correct. But when I try to look for the property agents that does belong to Host, it says it doesn't belong to NetMonitorDevice. I don't understand why that is.

    Kris

Reply
  • So, I tried a different approach:

    NetMonitorDevice where deviceReference.referredObject.agents in (Agent where topologyTypeName = 'DBO_Agent_Model')

    and I get the same error:

    QueryException: java.lang.IllegalArgumentException: Type 'foglight-5:NetMonitorDevice:7' does not have a property with the name 'agents'

    However if I deliberately make a mistake in the query and look for a property called agent, I get this:

    NetMonitorDevice where deviceReference.referredObject.agent in (Agent where topologyTypeName = 'DBO_Agent_Model')

    QueryException: java.lang.IllegalArgumentException: Type 'foglight-5:Host:21' does not have a property with the name 'agent'

    So it looks like the walk down the property path is working but when it gets to the Host object it can't find the property agent, which is correct. But when I try to look for the property agents that does belong to Host, it says it doesn't belong to NetMonitorDevice. I don't understand why that is.

    Kris

Children
No Data