private boolean disableValidation() { return ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_DISABLE, Boolean.FALSE, Boolean.class); }
private boolean ignoreValidationError() { return ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_IGNORE_ERRORS, Boolean.FALSE, Boolean.class); }
private boolean ignoreValidationError() { return ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_IGNORE_ERRORS, Boolean.FALSE, Boolean.class); }
private boolean disableValidation() { return ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_DISABLE, Boolean.FALSE, Boolean.class); }
/** * The method reads and caches value of configuration property * {@link org.glassfish.jersey.server.ServerProperties#REDUCE_CONTEXT_PATH_SLASHES_ENABLED} for future purposes. */ private void cacheConfigEnableLeadingContextPathSlashes() { this.configReduceContextPathSlashesEnabled = ServerProperties.getValue(getConfiguration().getProperties(), ServerProperties.REDUCE_CONTEXT_PATH_SLASHES_ENABLED, false, Boolean.class); } }
/** * The method reads and caches value of configuration property * {@link ServerProperties#RESPONSE_SET_STATUS_OVER_SEND_ERROR} for future purposes. */ private void cacheConfigSetStatusOverSendError() { this.configSetStatusOverSendError = ServerProperties.getValue(getConfiguration().getProperties(), ServerProperties.RESPONSE_SET_STATUS_OVER_SEND_ERROR, false, Boolean.class); }
/** * The method reads and caches value of configuration property * {@link org.glassfish.jersey.server.ServerProperties#RESPONSE_SET_STATUS_OVER_SEND_ERROR} for future purposes. */ private void cacheConfigSetStatusOverSendError() { this.configSetStatusOverSendError = ServerProperties.getValue(getConfiguration().getProperties(), ServerProperties.RESPONSE_SET_STATUS_OVER_SEND_ERROR, false, Boolean.class); }
/** * Get application-wide tracing level threshold. * * @param configuration application configuration. * @return tracing level threshold. */ /*package*/ static TracingLogger.Level getTracingThreshold(Configuration configuration) { final String thresholdText = ServerProperties.getValue( configuration.getProperties(), ServerProperties.TRACING_THRESHOLD, String.class); return (thresholdText == null) ? TracingLogger.DEFAULT_LEVEL : TracingLogger.Level.valueOf(thresholdText); }
/** * Get application-wide tracing level threshold. * * @param configuration application configuration. * @return tracing level threshold. */ /*package*/ static TracingLogger.Level getTracingThreshold(Configuration configuration) { final String thresholdText = ServerProperties.getValue( configuration.getProperties(), ServerProperties.TRACING_THRESHOLD, String.class); return (thresholdText == null) ? TracingLogger.DEFAULT_LEVEL : TracingLogger.Level.valueOf(thresholdText); }
/** * Return configuration type of tracing support according to application configuration. * * By default tracing support is switched OFF. * * @param configuration application configuration. * @return configuration type, transformed text value to enum read from configuration or default. */ /*package*/ static TracingConfig getTracingConfig(Configuration configuration) { final String tracingText = ServerProperties.getValue(configuration.getProperties(), ServerProperties.TRACING, String.class); final TracingConfig result; if (tracingText != null) { result = TracingConfig.valueOf(tracingText); } else { result = DEFAULT_CONFIGURATION_TYPE; } return result; }
@Override public void configure(final FeatureContext context) { if (!context.getConfiguration().isRegistered(MonitoringFeature.class)) { final Boolean monitoringEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_ENABLED, Boolean.FALSE); final Boolean statisticsEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_STATISTICS_ENABLED, Boolean.FALSE); final Boolean mbeansEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_STATISTICS_MBEANS_ENABLED, Boolean.FALSE); if (monitoringEnabled || statisticsEnabled || mbeansEnabled) { context.register(MonitoringFeature.class); } } } }
@Override public void configure(final FeatureContext context) { if (!context.getConfiguration().isRegistered(MonitoringFeature.class)) { final Boolean monitoringEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_ENABLED, Boolean.FALSE); final Boolean statisticsEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_STATISTICS_ENABLED, Boolean.FALSE); final Boolean mbeansEnabled = ServerProperties.getValue(context.getConfiguration().getProperties(), ServerProperties.MONITORING_STATISTICS_MBEANS_ENABLED, Boolean.FALSE); if (monitoringEnabled || statisticsEnabled || mbeansEnabled) { context.register(MonitoringFeature.class); } } } }
/** * Return configuration type of tracing support according to application configuration. * * By default tracing support is switched OFF. * * @param configuration application configuration. * @return configuration type, transformed text value to enum read from configuration or default. */ /*package*/ static TracingConfig getTracingConfig(Configuration configuration) { final String tracingText = ServerProperties.getValue(configuration.getProperties(), ServerProperties.TRACING, String.class); final TracingConfig result; if (tracingText != null) { result = TracingConfig.valueOf(tracingText); } else { result = DEFAULT_CONFIGURATION_TYPE; } return result; }
private void setupApplicationName() { final String appName = ServerProperties.getValue(getProperties(), ServerProperties.APPLICATION_NAME, null, String.class); if (appName != null && getApplicationName() == null) { setApplicationName(appName); } } }
private void setupApplicationName() { final String appName = ServerProperties.getValue(getProperties(), ServerProperties.APPLICATION_NAME, null, String.class); if (appName != null && getApplicationName() == null) { setApplicationName(appName); } } }
configuration.getProperty(ServerProperties.PROCESSING_RESPONSE_ERRORS_ENABLED)); this.disableLocationHeaderRelativeUriResolution = ServerProperties.getValue(configuration.getProperties(), ServerProperties.LOCATION_HEADER_RELATIVE_URI_RESOLUTION_DISABLED, Boolean.FALSE, Boolean.class); this.rfc7231LocationHeaderRelativeUriResolution = ServerProperties.getValue(configuration.getProperties(), ServerProperties.LOCATION_HEADER_RELATIVE_URI_RESOLUTION_RFC7231, Boolean.FALSE, Boolean.class);
configuration.getProperty(ServerProperties.PROCESSING_RESPONSE_ERRORS_ENABLED)); this.disableLocationHeaderRelativeUriResolution = ServerProperties.getValue(configuration.getProperties(), ServerProperties.LOCATION_HEADER_RELATIVE_URI_RESOLUTION_DISABLED, Boolean.FALSE, Boolean.class); this.rfc7231LocationHeaderRelativeUriResolution = ServerProperties.getValue(configuration.getProperties(), ServerProperties.LOCATION_HEADER_RELATIVE_URI_RESOLUTION_RFC7231, Boolean.FALSE, Boolean.class);
ResourceConfig runtimeConfig = serverBag.getRuntimeConfig(); final boolean disableValidation = ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_DISABLE, Boolean.FALSE,
ResourceConfig runtimeConfig = serverBag.getRuntimeConfig(); final boolean disableValidation = ServerProperties.getValue(runtimeConfig.getProperties(), ServerProperties.RESOURCE_VALIDATION_DISABLE, Boolean.FALSE,
&& resourceConfig.isProperty(ServletProperties.FILTER_FORWARD_ON_404); this.queryParamsAsFormParams = !resourceConfig.isProperty(ServletProperties.QUERY_PARAMS_AS_FORM_PARAMS_DISABLED); this.configSetStatusOverSendError = ServerProperties.getValue(resourceConfig.getProperties(), ServerProperties.RESPONSE_SET_STATUS_OVER_SEND_ERROR, false, Boolean.class); this.backgroundTaskScheduler = appHandler.getInjectionManager()