AppDynamics Proxy Support for Linux x64
This package provides platform-specific native (C/C++) extensions for proxy support and network communication for the AppDynamics Python Agent. It is an internal runtime dependency automatically managed by the main `appdynamics` agent package and is not intended for direct user interaction or import. The current version is 11.86.0 and it is released in conjunction with the main AppDynamics Python Agent.
Common errors
-
ModuleNotFoundError: No module named 'appdynamics_proxysupport_linux_x64'
cause The main `appdynamics` agent could not locate or load its internal `proxysupport` components, possibly due to a corrupted installation or a platform mismatch.fixReinstall the main `appdynamics` agent to ensure all platform-specific dependencies are correctly fetched and installed: `pip install --upgrade --force-reinstall appdynamics`. Ensure your environment (OS/architecture) corresponds to `linux-x64`. -
Failed to load AppDynamics native library: [error message related to shared object]
cause The native library provided by `appdynamics-proxysupport-linux-x64` failed to load, often due to incompatible glibc versions, missing runtime dependencies on the OS, or permissions issues.fixCheck the AppDynamics agent logs for the exact error message (e.g., `libstdc++.so.6` not found). Ensure your system's `glibc` version meets the agent's requirements (typically a reasonably modern Linux). For containerized environments, ensure the base image contains necessary runtime libraries. -
Proxy connection failed: [error message]
cause The native proxy support library attempted to connect to a proxy server but failed, potentially due to incorrect proxy configuration, network issues, or an unreachable proxy.fixVerify the proxy host, port, and authentication details in your AppDynamics agent configuration (usually environment variables like `AD_PROXY_HOST`, `AD_PROXY_PORT`, `AD_PROXY_USER`, `AD_PROXY_PASSWORD`). Ensure network connectivity from the agent host to the proxy server.
Warnings
- gotcha This package (`appdynamics-proxysupport-linux-x64`) is a platform-specific binary dependency. Installing it manually on a non-Linux x64 system will not work and can cause errors in the main AppDynamics agent.
- breaking Version mismatch between `appdynamics-proxysupport-linux-x64` and the main `appdynamics` agent. Installing incompatible versions manually can lead to runtime errors, agent failures, or incorrect data reporting.
- gotcha Python agent startup fails with warnings/errors about missing or uncallable native libraries when proxy support is enabled or required. This can happen if the `appdynamics-proxysupport-linux-x64` package's native binary cannot be loaded by the Python interpreter, often due to missing shared library dependencies (e.g., GLIBC versions).
Install
-
pip install appdynamics-proxysupport-linux-x64
Imports
- (None)
This package does not expose public symbols for direct import.
Quickstart
import os
import appdynamics.agent
from appdynamics.agent import initialize
# AppDynamics Agent Initialization (typical setup)
# Ensure these environment variables are set in your deployment environment
# e.g., in a Dockerfile, k8s manifest, or shell script
# AD_CONTROLLER_HOST: Your AppDynamics Controller Hostname
# AD_CONTROLLER_PORT: Your AppDynamics Controller Port (e.g., 8090)
# AD_AGENT_ACCOUNT_NAME: Your AppDynamics Account Name
# AD_AGENT_ACCOUNT_ACCESS_KEY: Your AppDynamics Account Access Key
# AD_APPLICATION_NAME: Your Application Name
# AD_TIER_NAME: Your Tier Name
# AD_NODE_NAME: Your Node Name
controller_host = os.environ.get('AD_CONTROLLER_HOST', 'localhost')
controller_port = int(os.environ.get('AD_CONTROLLER_PORT', '8090'))
account_name = os.environ.get('AD_AGENT_ACCOUNT_NAME', 'customer1')
account_access_key = os.environ.get('AD_AGENT_ACCOUNT_ACCESS_KEY', '')
application_name = os.environ.get('AD_APPLICATION_NAME', 'MyPythonApp')
tier_name = os.environ.get('AD_TIER_NAME', 'WebTier')
node_name = os.environ.get('AD_NODE_NAME', 'Node1')
try:
initialize(
controller={'host': controller_host, 'port': controller_port, 'ssl': False},
account={'name': account_name, 'access_key': account_access_key},
application={'name': application_name, 'tier_name': tier_name, 'node_name': node_name},
# For proxy settings, these would usually be set via environment variables as well
# e.g., AD_PROXY_HOST, AD_PROXY_PORT, etc.
# The appdynamics-proxysupport-linux-x64 package provides the native
# libraries that handle these proxy connections internally.
log={'log_level': 'INFO', 'output_path': 'stdout'},
auto_instrument=True # Usually enabled for web frameworks
)
print("AppDynamics Agent initialized successfully.")
except Exception as e:
print(f"Failed to initialize AppDynamics Agent: {e}")
print("Ensure environment variables are set correctly and controller is reachable.")
# Your application code would go here
def my_application_function():
print("Application function running...")
if __name__ == "__main__":
my_application_function()