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 void
addExchangeFactory(ExchangeFactory exchangeFactory)
Adds theExchangeFactory
to be managed.int
getCapacity()
The capacity the pool (for each consumer) uses for storing exchanges.int
getConsumerCounter()
Number of consumers currently being managedCollection<ExchangeFactory>
getExchangeFactories()
Returns a read-only view of the managed factories.int
getPooledCounter()
Number of currently exchanges being pooled (if pooled is in use)PooledObjectFactory.Statistics
getStatistics()
Aggregated statistics for all the managed exchange factoriesboolean
isStatisticsEnabled()
Whether statistics is enabled.void
purge()
Purges the internal caches (if pooled)void
removeExchangeFactory(ExchangeFactory exchangeFactory)
Removes theExchangeFactory
from being managed (such as when a route is stopped/removed) or during shutdown.void
resetStatistics()
Reset the statisticsvoid
setStatisticsEnabled(boolean statisticsEnabled)
Whether statistics is enabled.
-
-
-
Method Detail
-
addExchangeFactory
void addExchangeFactory(ExchangeFactory exchangeFactory)
Adds theExchangeFactory
to be managed.- Parameters:
exchangeFactory
- the exchange factory
-
removeExchangeFactory
void removeExchangeFactory(ExchangeFactory exchangeFactory)
Removes theExchangeFactory
from 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
-
-