Refine search
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { return ThreadPoolType.valueOf(threadPoolTypeString); } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { validator = new ConcurrentValidator(modules.getPluggableValidators(), executor, UnusedBeans.isEnabled(configuration) ? new ConcurrentHashMap<>() : null); int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { validator = new ConcurrentValidator(modules.getPluggableValidators(), executor, UnusedBeans.isEnabled(configuration) ? new ConcurrentHashMap<>() : null); int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { validator = new ConcurrentValidator(modules.getPluggableValidators(), executor, UnusedBeans.isEnabled(configuration) ? new ConcurrentHashMap<>() : null); int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { ThreadPoolType threadPoolType = ThreadPoolType.valueOf(threadPoolTypeString); if (System.getSecurityManager() != null && ThreadPoolType.COMMON == threadPoolType) { threadPoolType = ThreadPoolType.FIXED; BootstrapLogger.LOG.commonThreadPoolWithSecurityManagerEnabled(threadPoolType); } return threadPoolType; } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { validator = new ConcurrentValidator(modules.getPluggableValidators(), executor, UnusedBeans.isEnabled(configuration) ? new ConcurrentHashMap<>() : null); int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { ThreadPoolType threadPoolType = ThreadPoolType.valueOf(threadPoolTypeString); if (System.getSecurityManager() != null && ThreadPoolType.COMMON == threadPoolType) { threadPoolType = ThreadPoolType.FIXED; BootstrapLogger.LOG.commonThreadPoolWithSecurityManagerEnabled(threadPoolType); } return threadPoolType; } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { validator = new ConcurrentValidator(modules.getPluggableValidators(), executor, UnusedBeans.isEnabled(configuration) ? new ConcurrentHashMap<>() : null); int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { ThreadPoolType threadPoolType = ThreadPoolType.valueOf(threadPoolTypeString); if (System.getSecurityManager() != null && ThreadPoolType.COMMON == threadPoolType) { threadPoolType = ThreadPoolType.FIXED; BootstrapLogger.LOG.commonThreadPoolWithSecurityManagerEnabled(threadPoolType); } return threadPoolType; } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }
if (configuration.getBooleanProperty(ConfigurationKey.BEAN_IDENTIFIER_INDEX_OPTIMIZATION)) { beanIdentifierIndex = new BeanIdentifierIndex(); services.add(BeanIdentifierIndex.class, beanIdentifierIndex); if (configuration.getBooleanProperty(ConfigurationKey.CONCURRENT_DEPLOYMENT) && services.contains(ExecutorServices.class)) { services.add(Validator.class, new ConcurrentValidator(executor)); } else { int preloaderThreadPoolSize = configuration.getIntegerProperty(ConfigurationKey.PRELOADER_THREAD_POOL_SIZE); if (preloaderThreadPoolSize > 0 && Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP)) { preloader = new ContainerLifecycleEventPreloader(preloaderThreadPoolSize, observerNotificationService.getGlobalLenientObserverNotifier());
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { ThreadPoolType threadPoolType = ThreadPoolType.valueOf(threadPoolTypeString); if (System.getSecurityManager() != null && ThreadPoolType.COMMON == threadPoolType) { threadPoolType = ThreadPoolType.FIXED; BootstrapLogger.LOG.commonThreadPoolWithSecurityManagerEnabled(threadPoolType); } return threadPoolType; } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }
private static ThreadPoolType initThreadPoolType(WeldConfiguration configuration) { String threadPoolTypeString = configuration.getStringProperty(ConfigurationKey.EXECUTOR_THREAD_POOL_TYPE); if (threadPoolTypeString.isEmpty()) { // do not create ExecutorServices by default if we do not have the "modifyThreadGroup" permission return Permissions.hasPermission(Permissions.MODIFY_THREAD_GROUP) ? ThreadPoolType.FIXED : ThreadPoolType.NONE; } else { try { ThreadPoolType threadPoolType = ThreadPoolType.valueOf(threadPoolTypeString); if (System.getSecurityManager() != null && ThreadPoolType.COMMON == threadPoolType) { threadPoolType = ThreadPoolType.FIXED; BootstrapLogger.LOG.commonThreadPoolWithSecurityManagerEnabled(threadPoolType); } return threadPoolType; } catch (Exception e) { throw BootstrapLogger.LOG.invalidThreadPoolType(threadPoolTypeString); } } }