diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/etc/sessions/gcloud/session-store.xml b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/etc/sessions/gcloud/session-store.xml index f04a90aee519..43d7fd0fe03f 100644 --- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/etc/sessions/gcloud/session-store.xml +++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/etc/sessions/gcloud/session-store.xml @@ -10,49 +10,26 @@ - + - + - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/modules/session-store-gcloud.mod b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/modules/session-store-gcloud.mod index 80625f39fa1f..9ee2a31f749d 100644 --- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/modules/session-store-gcloud.mod +++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/config-template/modules/session-store-gcloud.mod @@ -42,6 +42,7 @@ etc/sessions/gcloud/session-store.xml #jetty.session.gcloud.model.createTime=createTime #jetty.session.gcloud.model.cookieSetTime=cookieSetTime #jetty.session.gcloud.model.lastNode=lastNode +#jetty.session.gcloud.model.lastSaved=lastSaved #jetty.session.gcloud.model.expiry=expiry #jetty.session.gcloud.model.maxInactive=maxInactive #jetty.session.gcloud.model.attributes=attributes diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStore.java b/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStore.java index 541116e1c126..d120ff593ac1 100644 --- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStore.java +++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStore.java @@ -55,6 +55,7 @@ public class GCloudSessionDataStore extends AbstractSessionDataStore public static final int DEFAULT_MAX_QUERY_RESULTS = 100; public static final int DEFAULT_MAX_RETRIES = 5; public static final int DEFAULT_BACKOFF_MS = 1000; + public static final String DEFAULT_NAMESPACE = ""; protected Datastore _datastore; protected KeyFactory _keyFactory; @@ -65,7 +66,7 @@ public class GCloudSessionDataStore extends AbstractSessionDataStore protected boolean _indexesPresent = false; protected EntityDataModel _model; protected boolean _modelProvided; - private String _namespace; + private String _namespace = DEFAULT_NAMESPACE; /** * EntityDataModel @@ -431,7 +432,7 @@ public void setNamespace(String namespace) _namespace = namespace; } - @ManagedAttribute(value = "gclound namespace", readonly = true) + @ManagedAttribute(value = "gcloud namespace", readonly = true) public String getNamespace() { return _namespace; diff --git a/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStoreFactory.java b/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStoreFactory.java index e35014296fd7..716e18f91028 100644 --- a/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStoreFactory.java +++ b/jetty-gcloud/jetty-gcloud-session-manager/src/main/java/org/eclipse/jetty/gcloud/session/GCloudSessionDataStoreFactory.java @@ -22,9 +22,9 @@ */ public class GCloudSessionDataStoreFactory extends AbstractSessionDataStoreFactory { - private String _namespace; - private int _maxRetries; - private int _backoffMs; + private String _namespace = GCloudSessionDataStore.DEFAULT_NAMESPACE; + private int _maxRetries = GCloudSessionDataStore.DEFAULT_MAX_RETRIES; + private int _backoffMs = GCloudSessionDataStore.DEFAULT_BACKOFF_MS; private GCloudSessionDataStore.EntityDataModel _model; public GCloudSessionDataStore.EntityDataModel getEntityDataModel() @@ -80,8 +80,9 @@ public SessionDataStore getSessionDataStore(SessionHandler handler) throws Excep ds.setBackoffMs(getBackoffMs()); ds.setMaxRetries(getMaxRetries()); ds.setGracePeriodSec(getGracePeriodSec()); - ds.setNamespace(_namespace); + ds.setNamespace(getNamespace()); ds.setSavePeriodSec(getSavePeriodSec()); + ds.setEntityDataModel(getEntityDataModel()); return ds; } } diff --git a/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/default.xml b/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/default.xml index 2da04b6b2c9d..07b47ee84b38 100644 --- a/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/default.xml +++ b/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/default.xml @@ -14,8 +14,8 @@ - - + + diff --git a/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/remote.xml b/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/remote.xml index 43675650e40a..377706a27c55 100644 --- a/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/remote.xml +++ b/jetty-hazelcast/src/main/config/etc/sessions/hazelcast/remote.xml @@ -10,21 +10,11 @@ - - - - - - - - - - - - - - - + + + + + diff --git a/jetty-http2/http2-server/src/main/config/etc/jetty-http2c.xml b/jetty-http2/http2-server/src/main/config/etc/jetty-http2c.xml index 3f77565aeecc..86b10ada984f 100644 --- a/jetty-http2/http2-server/src/main/config/etc/jetty-http2c.xml +++ b/jetty-http2/http2-server/src/main/config/etc/jetty-http2c.xml @@ -9,7 +9,7 @@ - + diff --git a/jetty-http2/http2-server/src/main/config/modules/http2c.mod b/jetty-http2/http2-server/src/main/config/modules/http2c.mod index 46b5364ce0b8..f1a6fc4f55af 100644 --- a/jetty-http2/http2-server/src/main/config/modules/http2c.mod +++ b/jetty-http2/http2-server/src/main/config/modules/http2c.mod @@ -18,13 +18,13 @@ etc/jetty-http2c.xml [ini-template] # tag::documentation[] ## Specifies the maximum number of concurrent requests per session. -# jetty.http2c.maxConcurrentStreams=1024 +# jetty.http2c.maxConcurrentStreams=128 ## Specifies the initial stream receive window (client to server) in bytes. -# jetty.http2c.initialStreamRecvWindow=65535 +# jetty.http2c.initialStreamRecvWindow=524288 ## Specifies the initial session receive window (client to server) in bytes. -# jetty.http2.initialSessionRecvWindow=1048576 +# jetty.http2.initialSessionRecvWindow=1232896 ## Specifies the maximum number of keys in all SETTINGS frames received by a session. # jetty.http2.maxSettingsKeys=64 diff --git a/jetty-rewrite/src/main/config/etc/jetty-rewrite-customizer.xml b/jetty-rewrite/src/main/config/etc/jetty-rewrite-customizer.xml index a60f80555b78..6a9bf7999c28 100644 --- a/jetty-rewrite/src/main/config/etc/jetty-rewrite-customizer.xml +++ b/jetty-rewrite/src/main/config/etc/jetty-rewrite-customizer.xml @@ -9,7 +9,7 @@ - + diff --git a/jetty-rewrite/src/main/config/etc/jetty-rewrite.xml b/jetty-rewrite/src/main/config/etc/jetty-rewrite.xml index e123113c5c22..c78237e0c036 100644 --- a/jetty-rewrite/src/main/config/etc/jetty-rewrite.xml +++ b/jetty-rewrite/src/main/config/etc/jetty-rewrite.xml @@ -10,7 +10,7 @@ - + diff --git a/jetty-server/src/main/config/etc/jetty-gzip.xml b/jetty-server/src/main/config/etc/jetty-gzip.xml index 16f60c923549..7659b2a195d0 100644 --- a/jetty-server/src/main/config/etc/jetty-gzip.xml +++ b/jetty-server/src/main/config/etc/jetty-gzip.xml @@ -13,11 +13,7 @@ - - - - @@ -26,6 +22,19 @@ + + + + + + + + + + + + + - + diff --git a/jetty-server/src/main/config/etc/sessions/jdbc/session-store.xml b/jetty-server/src/main/config/etc/sessions/jdbc/session-store.xml index 7c565b318ce5..963c5252b09a 100644 --- a/jetty-server/src/main/config/etc/sessions/jdbc/session-store.xml +++ b/jetty-server/src/main/config/etc/sessions/jdbc/session-store.xml @@ -8,8 +8,8 @@ - - + + diff --git a/jetty-server/src/main/config/modules/gzip.mod b/jetty-server/src/main/config/modules/gzip.mod index a11f9e70ee15..4a4320fba6ee 100644 --- a/jetty-server/src/main/config/modules/gzip.mod +++ b/jetty-server/src/main/config/modules/gzip.mod @@ -21,17 +21,23 @@ etc/jetty-gzip.xml ## Check whether a file with *.gz extension exists # jetty.gzip.checkGzExists=false -## Gzip compression level (-1 for default) -# jetty.gzip.compressionLevel=-1 - ## Inflate request buffer size, or 0 for no request inflation # jetty.gzip.inflateBufferSize=0 +## Inflater pool max size (-1 for unlimited, 0 for no pooling) +# jetty.gzip.inflaterPool.capacity=1024 + +## Inflater pool use GZIP compatible compression +#jetty.gzip.inflaterPool.noWrap=true + ## Deflater pool max size (-1 for unlimited, 0 for no pooling) -# jetty.gzip.deflaterPoolCapacity=-1 +# jetty.gzip.deflaterPool.capacity=1024 -## Inflater pool max size (-1 for unlimited, 0 for no pooling) -# jetty.gzip.inflaterPoolCapacity=-1 +## Gzip compression level (-1 for default) +# jetty.gzip.deflaterPool.compressionLevel=-1 + +## Deflater pool use GZIP compatible compression +# jetty.gzip.deflaterPool.noWrap=true ## Set the {@link Deflater} flush mode to use. # jetty.gzip.syncFlush=false diff --git a/jetty-server/src/main/config/modules/server.mod b/jetty-server/src/main/config/modules/server.mod index f9559177fde1..8c5a301578ca 100644 --- a/jetty-server/src/main/config/modules/server.mod +++ b/jetty-server/src/main/config/modules/server.mod @@ -62,8 +62,8 @@ etc/jetty.xml ## HTTP Compliance: RFC7230, RFC7230_LEGACY, RFC2616, RFC2616_LEGACY, LEGACY # jetty.httpConfig.compliance=RFC7230 -## URI Compliance: SAFE, STRICT -# jetty.httpConfig.uriCompliance=SAFE +## URI Compliance: DEFAULT, LEGACY, RFC3986, UNSAFE +# jetty.httpConfig.uriCompliance=DEFAULT ## Cookie compliance mode for parsing request Cookie headers: RFC2965, RFC6265 # jetty.httpConfig.requestCookieCompliance=RFC6265 diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStore.java b/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStore.java index 47d46564b819..49ee9690f160 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStore.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStore.java @@ -30,12 +30,15 @@ public abstract class AbstractSessionDataStore extends ContainerLifeCycle implements SessionDataStore { private static final Logger LOG = LoggerFactory.getLogger(AbstractSessionDataStore.class); + + public static final int DEFAULT_GRACE_PERIOD_SEC = 60 * 60; //default of 1hr + public static final int DEFAULT_SAVE_PERIOD_SEC = 0; protected SessionContext _context; //context associated with this session data store - protected int _gracePeriodSec = 60 * 60; //default of 1hr + protected int _gracePeriodSec = DEFAULT_GRACE_PERIOD_SEC; protected long _lastExpiryCheckTime = 0; //last time in ms that getExpired was called protected long _lastOrphanSweepTime = 0; //last time in ms that we deleted orphaned sessions - protected int _savePeriodSec = 0; //time in sec between saves + protected int _savePeriodSec = DEFAULT_SAVE_PERIOD_SEC; //time in sec between saves /** * Small utility class to allow us to diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStoreFactory.java b/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStoreFactory.java index 823502dc633b..d6b47dd328b0 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStoreFactory.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/session/AbstractSessionDataStoreFactory.java @@ -19,8 +19,8 @@ public abstract class AbstractSessionDataStoreFactory implements SessionDataStoreFactory { - int _gracePeriodSec; - int _savePeriodSec; + int _gracePeriodSec = AbstractSessionDataStore.DEFAULT_GRACE_PERIOD_SEC; + int _savePeriodSec = AbstractSessionDataStore.DEFAULT_SAVE_PERIOD_SEC; /** * @return the gracePeriodSec diff --git a/jetty-unixsocket/jetty-unixsocket-server/src/main/config-template/modules/unixsocket-http2c.mod b/jetty-unixsocket/jetty-unixsocket-server/src/main/config-template/modules/unixsocket-http2c.mod index 72d245711065..efae77ba2362 100644 --- a/jetty-unixsocket/jetty-unixsocket-server/src/main/config-template/modules/unixsocket-http2c.mod +++ b/jetty-unixsocket/jetty-unixsocket-server/src/main/config-template/modules/unixsocket-http2c.mod @@ -20,7 +20,7 @@ etc/jetty-unixsocket-http2c.xml [ini-template] ## Max number of concurrent streams per connection -# jetty.http2.maxConcurrentStreams=1024 +# jetty.http2.maxConcurrentStreams=128 ## Initial stream receive window (client to server) -# jetty.http2.initialStreamRecvWindow=65535 +# jetty.http2.initialStreamRecvWindow=524288