use of org.apache.qpid.server.store.preferences.PreferencesRoot in project qpid-broker-j by apache.
the class AbstractVirtualHost method onOpen.
@Override
protected void onOpen() {
super.onOpen();
registerSystemNodes();
_messageStore = createMessageStore();
_messageStoreLogSubject = new MessageStoreLogSubject(getName(), _messageStore.getClass().getSimpleName());
_messageStore.addEventListener(this, Event.PERSISTENT_MESSAGE_SIZE_OVERFULL);
_messageStore.addEventListener(this, Event.PERSISTENT_MESSAGE_SIZE_UNDERFULL);
_fileSystemMaxUsagePercent = getContextValue(Integer.class, Broker.STORE_FILESYSTEM_MAX_USAGE_PERCENT);
_flowToDiskCheckPeriod = getContextValue(Long.class, FLOW_TO_DISK_CHECK_PERIOD);
_isDiscardGlobalSharedSubscriptionLinksOnDetach = getContextValue(Boolean.class, DISCARD_GLOBAL_SHARED_SUBSCRIPTION_LINKS_ON_DETACH);
QpidServiceLoader serviceLoader = new QpidServiceLoader();
for (ConnectionValidator validator : serviceLoader.instancesOf(ConnectionValidator.class)) {
if ((_enabledConnectionValidators.isEmpty() && (_disabledConnectionValidators.isEmpty()) || !_disabledConnectionValidators.contains(validator.getType())) || _enabledConnectionValidators.contains(validator.getType())) {
_connectionValidators.add(validator);
}
}
PreferencesRoot preferencesRoot = (VirtualHostNode) getParent();
_preferenceStore = preferencesRoot.createPreferenceStore();
_linkRegistry = createLinkRegistry();
createHousekeepingExecutor();
}
use of org.apache.qpid.server.store.preferences.PreferencesRoot in project qpid-broker-j by apache.
the class BrokerImpl method onOpen.
@Override
protected void onOpen() {
super.onOpen();
PreferencesRoot preferencesRoot = (SystemConfig) getParent();
_preferenceStore = preferencesRoot.createPreferenceStore();
getEventLogger().message(BrokerMessages.STARTUP(CommonProperties.getReleaseVersion(), CommonProperties.getBuildVersion()));
getEventLogger().message(BrokerMessages.PLATFORM(System.getProperty("java.vendor"), System.getProperty("java.runtime.version", System.getProperty("java.version")), SystemUtils.getOSName(), SystemUtils.getOSVersion(), SystemUtils.getOSArch(), String.valueOf(getNumberOfCores())));
long directMemory = getMaxDirectMemorySize();
long heapMemory = Runtime.getRuntime().maxMemory();
getEventLogger().message(BrokerMessages.MAX_MEMORY(heapMemory, directMemory));
_flowToDiskThreshold = getContextValue(Long.class, BROKER_FLOW_TO_DISK_THRESHOLD);
_compactMemoryThreshold = getContextValue(Long.class, Broker.COMPACT_MEMORY_THRESHOLD);
_compactMemoryInterval = getContextValue(Long.class, Broker.COMPACT_MEMORY_INTERVAL);
_housekeepingCheckPeriod = getContextValue(Long.class, Broker.QPID_BROKER_HOUSEKEEPING_CHECK_PERIOD);
if (SystemUtils.getProcessPid() != null) {
getEventLogger().message(BrokerMessages.PROCESS(SystemUtils.getProcessPid()));
}
registerSystemAddressSpaces();
assignTargetSizes();
}
Aggregations