Event Gateways - Settings
Configure global event gateway settings and resource allocation
Overview
Event Gateway Settings control the global configuration and resource allocation for all event gateways in ColdFusion. These settings determine how ColdFusion manages event processing threads, message queuing, and overall gateway performance.
The Settings page has four controls: Enable ColdFusion Event Gateway Services, Event Gateway Processing Threads, Maximum Number of Events to Queue, and the Start SMS Test Server button. Startup timeouts are configured per gateway type on the Gateway Types page, not here.
Gateway Service Settings
Core settings that control event gateway service behavior.
Enable Event Gateway Services
ENABLEEVENTGATEWAYSERVICE, shipped in Adobe's official Docker image)Start SMS Test Server
Thread Pool Configuration
Control the number of threads available for event processing across all gateways.
Event Gateway Processing Threads
Medium volume: 50-100 threads
High volume: 100-200+ threads
- Monitor thread usage under typical load
- Increase if events are queuing excessively
- Consider number of active gateways and expected concurrent events
- Balance with available CPU cores and memory
- Each thread consumes memory (typically 1-2 MB per thread)
Event Queue Settings
Configure how ColdFusion queues and processes gateway events.
Maximum Number of Events to Queue
Medium volume: 2000-5000
High volume: 10000+
- Monitor queue depth under normal and peak loads
- If queue frequently fills up, increase thread pool first
- Only increase queue size if events arrive faster than threads can process
- Very large queues may indicate processing bottlenecks that need optimization
Monitoring Event Gateways
Gateway settings and instance status are available through the Administrator API (cfide.adminapi.eventgateway). The getGatewayHelper(gatewayID) function returns a gateway type's own helper object and does not provide monitoring methods.
// Log in to the Admin API
createObject("component", "cfide.adminapi.administrator").login(adminPassword);
// List configured gateway instances
eg = createObject("component", "cfide.adminapi.eventgateway");
writeDump(eg.getGatewayInstances());
// Started (true) or stopped (false) for one instance
writeDump(eg.getGatewayInstanceStatus("SMS_Notifications"));
// The two Settings page values
writeOutput(eg.getGatewayProperty("ThreadPoolSize"));
writeOutput(eg.getGatewayProperty("MaxQueueSize"));
// Event counters since server start (EventsIn or EventsOut)
writeOutput(eg.getGatewayEvents("SMS_Notifications", "EventsIn"));Performance Tuning Recommendations
Low Volume (< 100 events/min)
- Thread Pool
- 10-25 threads
- Queue Size
- 500-1000 events
Conservative settings for occasional event processing with minimal resource overhead.
Medium Volume (100-1000 events/min)
- Thread Pool
- 50-100 threads
- Queue Size
- 2000-5000 events
Balanced configuration for steady event processing with room for traffic spikes.
High Volume (> 1000 events/min)
- Thread Pool
- 100-200+ threads
- Queue Size
- 10000+ events
Aggressive settings for high-throughput scenarios. Monitor memory and CPU carefully.
- Start with conservative settings and increase based on monitoring
- Confirm your edition supports the gateway types you plan to use
- Monitor thread pool utilization and queue depth under load
- Increase threads before increasing queue size
- Optimize CFC event handlers for fast processing
- Consider dedicated ColdFusion instances for high-volume gateways
- Use external message queuing (RabbitMQ, Kafka) for very high volumes
Common Issues & Solutions
Events Being Dropped
- Check if event queue is full (increase queue size or thread pool)
- Monitor thread pool utilization (increase threads if maxed out)
- Review CFC handler logs for errors during processing
- Verify Event Gateway Services are enabled
- Check gateway instance is running and not failed
- Review eventgateway.log for errors
High Memory Usage
- Reduce thread pool size if over-allocated
- Decrease queue size to reduce queued event memory
- Optimize CFC handlers to release resources promptly
- Check for memory leaks in custom gateway Java code
- Increase JVM heap size if genuinely needed for workload
Slow Event Processing
- Increase thread pool size to process events faster
- Optimize CFC handler performance (database queries, external calls)
- Implement asynchronous processing for slow operations
- Check for thread contention or database bottlenecks
- Consider horizontal scaling (multiple CF instances)