SnmpKit.SnmpSim.LazyDevicePool (snmpkit v0.6.4)
Lazy Device Pool Manager for on-demand device creation and lifecycle management. Supports 10K+ devices with minimal memory footprint through lazy instantiation.
Features:
- On-demand device creation when first accessed
- Automatic cleanup of idle devices to conserve resources
- Port-based device type determination
- Efficient tracking of active devices and last access times
- Resource monitoring and cleanup scheduling
Summary
Functions
Returns a specification to start this module under a supervisor.
Force cleanup of idle devices immediately.
Clear the device cache - alias for shutdown_all_devices for compatibility.
Configure device types for specific port ranges.
Get or create a device for the specified port. Creates the device on first access if it doesn't exist.
Get statistics about the device pool.
Callback implementation for GenServer.init/1
.
Shutdown all devices and reset the pool.
Shutdown a specific device.
Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Force cleanup of idle devices immediately.
Clear the device cache - alias for shutdown_all_devices for compatibility.
Configure device types for specific port ranges.
Get or create a device for the specified port. Creates the device on first access if it doesn't exist.
Get statistics about the device pool.
Callback implementation for GenServer.init/1
.
Shutdown all devices and reset the pool.
Shutdown a specific device.