Package org.apache.camel.spi
Interface ExchangeFactoryManager
-
- All Superinterfaces:
AutoCloseable,Service,StaticService
public interface ExchangeFactoryManager extends StaticService
ManagesExchangeFactory.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddExchangeFactory(ExchangeFactory exchangeFactory)Adds theExchangeFactoryto be managed.intgetCapacity()The capacity the pool (for each consumer) uses for storing exchanges.intgetConsumerCounter()Number of consumers currently being managedCollection<ExchangeFactory>getExchangeFactories()Returns a read-only view of the managed factories.intgetPooledCounter()Number of currently exchanges being pooled (if pooled is in use)PooledObjectFactory.StatisticsgetStatistics()Aggregated statistics for all the managed exchange factoriesbooleanisStatisticsEnabled()Whether statistics is enabled.voidpurge()Purges the internal caches (if pooled)voidremoveExchangeFactory(ExchangeFactory exchangeFactory)Removes theExchangeFactoryfrom being managed (such as when a route is stopped/removed) or during shutdown.voidresetStatistics()Reset the statisticsvoidsetStatisticsEnabled(boolean statisticsEnabled)Whether statistics is enabled.
-
-
-
Method Detail
-
addExchangeFactory
void addExchangeFactory(ExchangeFactory exchangeFactory)
Adds theExchangeFactoryto be managed.- Parameters:
exchangeFactory- the exchange factory
-
removeExchangeFactory
void removeExchangeFactory(ExchangeFactory exchangeFactory)
Removes theExchangeFactoryfrom being managed (such as when a route is stopped/removed) or during shutdown.- Parameters:
exchangeFactory- the exchange factory
-
getExchangeFactories
Collection<ExchangeFactory> getExchangeFactories()
Returns a read-only view of the managed factories.
-
getConsumerCounter
int getConsumerCounter()
Number of consumers currently being managed
-
getCapacity
int getCapacity()
The capacity the pool (for each consumer) uses for storing exchanges. The default capacity is 100.
-
getPooledCounter
int getPooledCounter()
Number of currently exchanges being pooled (if pooled is in use)
-
isStatisticsEnabled
boolean isStatisticsEnabled()
Whether statistics is enabled.
-
setStatisticsEnabled
void setStatisticsEnabled(boolean statisticsEnabled)
Whether statistics is enabled.
-
resetStatistics
void resetStatistics()
Reset the statistics
-
purge
void purge()
Purges the internal caches (if pooled)
-
getStatistics
PooledObjectFactory.Statistics getStatistics()
Aggregated statistics for all the managed exchange factories
-
-