PL-8582 Unable to enable Vaadin productionMode using WebConfig

This commit is contained in:
Yuriy Artamonov 2017-02-03 12:56:51 +04:00
parent 68ebe2f2ce
commit 430eea321b
2 changed files with 5 additions and 5 deletions

View File

@ -272,21 +272,21 @@ public interface WebConfig extends Config {
* @return true if push should use long polling transport instead of websocket+xhr
*/
@Property("cuba.web.pushLongPolling")
@DefaultBoolean(value = false)
@DefaultBoolean(false)
boolean getUsePushLongPolling();
/**
* @return true if push is enabled
*/
@Property("cuba.web.pushEnabled")
@DefaultBoolean(value = true)
@DefaultBoolean(true)
boolean getPushEnabled();
/**
* @return true if production mode is enabled
*/
@Property("cuba.web.productionMode")
@DefaultBoolean(value = true)
@DefaultBoolean(false)
boolean getProductionMode();
/**

View File

@ -134,8 +134,8 @@ public class CubaApplicationServlet extends VaadinServlet {
if (Strings.isNullOrEmpty(initParameters.getProperty(Constants.SERVLET_PARAMETER_PRODUCTION_MODE))) {
boolean productionMode = webConfig.getProductionMode();
if (!productionMode) {
initParameters.setProperty(Constants.SERVLET_PARAMETER_PRODUCTION_MODE, String.valueOf(false));
if (productionMode) {
initParameters.setProperty(Constants.SERVLET_PARAMETER_PRODUCTION_MODE, String.valueOf(true));
}
}