Access to Instances
Your agent code can give the agent library access to your object instances. The agent library can call methods of those instances. You can either register a single instances, or register a provider that lets the agent library request instances on demand.
Instance Registration
Your stand-alone agent code can register a specific instance by calling TeaAgentServer.registerInstance (green arrow in the diagram above).
Your servlet agent code can register an instance by including it in the array that is the value of the servlet's getObjectInstances method.
On-Demand Access though Providers
Your agent code can also allow access to instances on demand by registering a provider instance. That is, your agent code:
- defines an object type class (in interface style) that implements TeaObject
- defines a corresponding provider class that implements TeaObjectProvider<T extends TeaObject>
- instantiates a provider object
- registers the provider object (orange arrow in the diagram)
For more information, see Provider
Copyright © Cloud Software Group, Inc. All Rights Reserved.