{@code base} - if the "base" is not an absolute file: directory URL, this parameter will be treated
* as prefix for the resource access as defined in Http/Whiteboard Service specifications (access via
- * {@link org.osgi.service.http.HttpContext#getResource(String)} or
- * {@link org.osgi.service.http.context.ServletContextHelper#getResource(String)}.
+ * {@link org.ops4j.pax.web.service.http.HttpContext#getResource(String)} or
+ * {@link org.osgi.service.servlet.context.ServletContextHelper#getResource(String)}.
*
*
* @param urlBase if the "base" is found to be proper, accessible {@code file:} based directory, it is passed
* to this creation method and {@code base} can be safely ignored
* @param base According to HttpService and Whiteboard specifications, this is the base location for
* resource fetching. By default this base is prepended to a path and (combined) used as argument
- * to {@link org.osgi.service.http.HttpContext#getResource(String)} or
- * {@link org.osgi.service.http.context.ServletContextHelper#getResource(String)}. It should not end with
+ * to {@link org.ops4j.pax.web.service.http.HttpContext#getResource(String)} or
+ * {@link org.osgi.service.servlet.context.ServletContextHelper#getResource(String)}. It should not end with
* slash ({@code /}) and can be an empty string (meaning root of the bundle).
* @return
*/
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/WarManager.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/WarManager.java
index 084e008326..01b0e844df 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/WarManager.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/WarManager.java
@@ -23,7 +23,7 @@
*
* @author Hiram Chirino
*/
-@Review("Extend and integrate with org.osgi.service.http.runtime.HttpServiceRuntime for Karaf commands/services"
+@Review("Extend and integrate with org.osgi.service.servlet.runtime.HttpServiceRuntime for Karaf commands/services"
+ " like org.apache.karaf.web.WebContainerService and org.apache.karaf.http.core.ServletService")
public interface WarManager {
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/ServerConfiguration.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/ServerConfiguration.java
index a50aee908a..cf7a481ba2 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/ServerConfiguration.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/ServerConfiguration.java
@@ -23,7 +23,7 @@
public interface ServerConfiguration {
/**
- * Returns the temporary directory, directory that will be set as {@link javax.servlet.ServletContext#TEMPDIR}.
+ * Returns the temporary directory, directory that will be set as {@link jakarta.servlet.ServletContext#TEMPDIR}.
*
* @return the temporary directory
*/
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/SessionConfiguration.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/SessionConfiguration.java
index 746e41327f..d06ff0f138 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/SessionConfiguration.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/config/SessionConfiguration.java
@@ -16,11 +16,11 @@
package org.ops4j.pax.web.service.spi.config;
import java.io.File;
-import javax.servlet.SessionCookieConfig;
+import jakarta.servlet.SessionCookieConfig;
/**
*
While some session configuration parameters (those specified in {@code web.xml} and
- * {@link javax.servlet.SessionCookieConfig}) can be specified through {@link org.ops4j.pax.web.service.WebContainer}
+ * {@link jakarta.servlet.SessionCookieConfig}) can be specified through {@link org.ops4j.pax.web.service.WebContainer}
* and during WAR deployment, some server-specific options can be configured only globally through
* {@link org.ops4j.pax.web.service.PaxWebConstants#PID}.
*
@@ -28,7 +28,7 @@
*/
public interface SessionConfiguration {
- // --- configuration that matches web.xml and javax.servlet.SessionCookieConfig
+ // --- configuration that matches web.xml and jakarta.servlet.SessionCookieConfig
/**
* {@code /} - returns the time in minutes after which an inative settion times out.
@@ -85,7 +85,7 @@ public interface SessionConfiguration {
*/
String getSessionCookieSameSite();
- // --- configuration that's not related to web.xml or javax.servlet.SessionCookieConfig
+ // --- configuration that's not related to web.xml or jakarta.servlet.SessionCookieConfig
/**
* Allows configuration of Jetty's SessionHandler.SessionIdPathParameterName. By default it's {@code jsessionid}.
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultHttpContext.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultHttpContext.java
index d3b89614b8..f015f64d56 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultHttpContext.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultHttpContext.java
@@ -21,16 +21,16 @@
import java.util.LinkedHashSet;
import java.util.Objects;
import java.util.Set;
-import javax.servlet.ServletContext;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.ServletContext;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
import org.ops4j.pax.web.service.PaxWebConstants;
import org.ops4j.pax.web.service.WebContainerContext;
import org.ops4j.pax.web.service.spi.util.Path;
import org.osgi.framework.Bundle;
-import org.osgi.service.http.HttpContext;
-import org.osgi.service.http.HttpService;
+import org.ops4j.pax.web.service.http.HttpContext;
+import org.ops4j.pax.web.service.http.HttpService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -172,7 +172,7 @@ public int hashCode() {
* @return
*/
protected URL getResource(Bundle bundle, String name) {
- // "name" is passed from javax.servlet.ServletContext.getResource() which always should start with a slash
+ // "name" is passed from jakarta.servlet.ServletContext.getResource() which always should start with a slash
final String normalizedName = Path.normalizeResourcePath(name);
LOG.trace("Searching bundle [" + bundle + "] for resource [" + normalizedName + "]");
return bundle.getResource(normalizedName);
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultMultiBundleWebContainerContext.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultMultiBundleWebContainerContext.java
index 77a6c38944..856e31c71b 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultMultiBundleWebContainerContext.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultMultiBundleWebContainerContext.java
@@ -21,8 +21,8 @@
import java.util.Queue;
import java.util.Set;
import java.util.concurrent.ConcurrentLinkedQueue;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
import org.ops4j.pax.web.service.MultiBundleWebContainerContext;
import org.osgi.framework.Bundle;
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultServletContextHelper.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultServletContextHelper.java
index df9cca91ac..b46c9469ec 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultServletContextHelper.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/DefaultServletContextHelper.java
@@ -18,11 +18,11 @@
import java.io.IOException;
import java.net.URL;
import java.util.Set;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
import org.osgi.framework.Bundle;
-import org.osgi.service.http.context.ServletContextHelper;
+import org.osgi.service.servlet.context.ServletContextHelper;
/**
* Default {@link ServletContextHelper} as specified in "140.2 The Servlet Context". Actually there's no need
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/UniqueWebContainerContextWrapper.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/UniqueWebContainerContextWrapper.java
index 25bbd51383..c8c7392913 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/UniqueWebContainerContextWrapper.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/UniqueWebContainerContextWrapper.java
@@ -18,8 +18,8 @@
import java.io.IOException;
import java.net.URL;
import java.util.Set;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
import org.ops4j.pax.web.service.WebContainerContext;
import org.osgi.framework.Bundle;
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/WebContainerContextWrapper.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/WebContainerContextWrapper.java
index 11ff3f2183..d07a05249c 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/WebContainerContextWrapper.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/WebContainerContextWrapper.java
@@ -18,17 +18,17 @@
import java.io.IOException;
import java.net.URL;
import java.util.Set;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
import org.ops4j.pax.web.service.WebContainerContext;
import org.osgi.framework.Bundle;
-import org.osgi.service.http.HttpContext;
-import org.osgi.service.http.context.ServletContextHelper;
+import org.ops4j.pax.web.service.http.HttpContext;
+import org.osgi.service.servlet.context.ServletContextHelper;
/**
* A simple wrapper to enclose custom {@link HttpContext http contexts} (which gets registered directly to the
- * {@link org.osgi.service.http.HttpService}) or {@link ServletContextHelper} (registered via Whiteboard service)
+ * {@link org.ops4j.pax.web.service.http.HttpService}) or {@link ServletContextHelper} (registered via Whiteboard service)
* in an implementation of {@link org.ops4j.pax.web.service.WebContainerContext}.
*/
public class WebContainerContextWrapper extends DefaultHttpContext {
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/package-info.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/package-info.java
index 5aff4e02b7..0b32dff693 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/package-info.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/context/package-info.java
@@ -15,7 +15,7 @@
*/
/**
- *
This package provides various implementations of {@link org.osgi.service.http.HttpContext} and
+ *
This package provides various implementations of {@link org.ops4j.pax.web.service.http.HttpContext} and
* {@link org.ops4j.pax.web.service.WebContainerContext} to be used in:
*
Http Service implementation in pax-web-runtime bundle
*
Whiteboard Service implementation in pax-web-extender-whiteboard bundle
@@ -24,7 +24,7 @@
*
Unique implementations are wrappers for existing instances of
* {@link org.ops4j.pax.web.service.WebContainerContext} and
* {@link org.ops4j.pax.web.service.MultiBundleWebContainerContext} because Http Service specification says
- * that {@link org.osgi.service.http.HttpService#createDefaultHttpContext()} returns new instance on each call,
+ * that {@link org.ops4j.pax.web.service.http.HttpService#createDefaultHttpContext()} returns new instance on each call,
* however we don't want these new instances to refer to different internal representations of the contexts.
*
This class represents OSGi-specific {@link HttpContext}/{@link ServletContextHelper}
- * and points to single, server-specific {@link javax.servlet.ServletContext} and (at model level) to single
+ * and points to single, server-specific {@link jakarta.servlet.ServletContext} and (at model level) to single
* {@link ServletContextModel}. It maps directly 1:1 to an OSGi service registered by user:
*
{@link HttpContext} with legacy Pax Web servier registration properties
*
{@link ServletContextHelper} with standard properties and/or annotations
@@ -109,7 +109,7 @@
*
*
*
Shadowing {@link OsgiContextModel} (see
- * {@link org.osgi.service.http.runtime.dto.DTOConstants#FAILURE_REASON_SHADOWED_BY_OTHER_SERVICE}) can happen
+ * {@link org.osgi.service.servlet.runtime.dto.DTOConstants#FAILURE_REASON_SHADOWED_BY_OTHER_SERVICE}) can happen
* only when there's name/id conflict, so:
*
When there are two contexts with same name and different context path, one is chosen (using ranking)
* - that's the way to override {@code default} context, for example by changing its context path
@@ -120,7 +120,7 @@
* ranking
*
At actual server runtime level, each servlet is associated (through {@link ServletConfig#getServletContext()})
* with own {@link OsgiContextModel}, but there are things to do before actual request processing - like
- * calling {@link javax.servlet.ServletContainerInitializer#onStartup(Set, ServletContext)} methods. Here, the
+ * calling {@link jakarta.servlet.ServletContainerInitializer#onStartup(Set, ServletContext)} methods. Here, the
* {@link OsgiContextModel} passed to such calls is the highest ranked {@link OsgiContextModel} /
* {@link org.ops4j.pax.web.service.spi.servlet.OsgiServletContext} which may be different that the context
* associated with the servlets running in such context.
@@ -138,8 +138,8 @@
* (Whiteboard Service specification) context. If it's created (customized) for {@link HttpContext}
* (registered directly or via {@link org.ops4j.pax.web.service.whiteboard.HttpContextMapping}) and if it's a
* singleton, then such {@link OsgiContextModel} is equivalent to one created directly through
- * {@link org.osgi.service.http.HttpService} and user may continue to register servlets via
- * {@link org.osgi.service.http.HttpService} to such contexts. That's the way to change the context path of such
+ * {@link org.ops4j.pax.web.service.http.HttpService} and user may continue to register servlets via
+ * {@link org.ops4j.pax.web.service.http.HttpService} to such contexts. That's the way to change the context path of such
* context. Without any additional steps, the servlets (and filters and resources) registered through
* {@link org.ops4j.pax.web.service.WebContainer} will always be associated with {@link OsgiContextModel}
* that is lower ranked than the "default" {@link OsgiContextModel} coming from Whiteboard.
@@ -172,7 +172,7 @@ public final class OsgiContextModel extends Identity implements Comparable {
Bundle whiteboardBundle = context == null ? null : context.getBundle();
@@ -183,10 +183,10 @@ public final class OsgiContextModel extends Identity implements Comparable registration = DEFAULT_CONTEXT_MODEL.getContextRegistrationProperties();
registration.clear();
// We pretend that this ServletContextModel was:
- // - registered to represent the Whiteboard's "default" context (org.osgi.service.http.context.ServletContextHelper)
+ // - registered to represent the Whiteboard's "default" context (org.osgi.service.servlet.context.ServletContextHelper)
registration.put(HttpWhiteboardConstants.HTTP_WHITEBOARD_CONTEXT_NAME, HttpWhiteboardConstants.HTTP_WHITEBOARD_DEFAULT_CONTEXT_NAME);
- // - NOT registered to represent the HttpService's "default" context (org.osgi.service.http.HttpContext)
- registration.remove(HttpWhiteboardConstants.HTTP_SERVICE_CONTEXT_PROPERTY);
+ // - NOT registered to represent the HttpService's "default" context (org.ops4j.pax.web.service.http.HttpContext)
+ registration.remove(PaxWebConstants.HTTP_SERVICE_CONTEXT_PROPERTY);
registration.put(Constants.SERVICE_ID, DEFAULT_CONTEXT_MODEL.getServiceId());
registration.put(Constants.SERVICE_RANKING, DEFAULT_CONTEXT_MODEL.getServiceRank());
// - registered with "/" context path
@@ -301,8 +301,8 @@ public final class OsgiContextModel extends Identity implements Comparable connectors = new ArrayList<>();
/**
- *
This is the owner bundle of this context. For {@link org.osgi.service.http.HttpService}
- * scenario, that's the bundle of bundle-scoped {@link org.osgi.service.http.HttpService} used to create
+ *
This is the owner bundle of this context. For {@link org.ops4j.pax.web.service.http.HttpService}
+ * scenario, that's the bundle of bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService} used to create
* {@link HttpContext}. For Whiteboard scenario, that's the bundle registering
* {@link ServletContextHelper}. For old Pax Web Whiteboard, that can be a
* bundle which registered shared {@link HttpContext}.
@@ -356,7 +356,7 @@ public final class OsgiContextModel extends Identity implements ComparableAt {@link OsgiContextModel} level we track a list of {@link Change changes} that represent implicit
* unregistrations of dynamic servlets/filters/listeners that may have been added for example inside
- * {@link javax.servlet.ServletContainerInitializer#onStartup(Set, ServletContext)} method.
+ * {@link jakarta.servlet.ServletContainerInitializer#onStartup(Set, ServletContext)} method.
*
- *
JavaEE doesn't bother with unregistration of such elements, but Pax Web does ;)
+ *
JakartaEE doesn't bother with unregistration of such elements, but Pax Web does ;)
*
* @param unregistration
*/
@@ -676,7 +676,7 @@ public void addTagLibs(Collection tagLibs) {
}
public void addJspPropertyGroupDescriptor(JspPropertyGroupDescriptor descriptor) {
- // because javax.servlet.descriptor.JspConfigDescriptor may contain more property group descriptors, we
+ // because jakarta.servlet.descriptor.JspConfigDescriptor may contain more property group descriptors, we
// should implement some kind of identification. So descriptors are "same" if they share at least one
// URI pattern. In such case the property group is replaced, otherwise it is added.
for (Iterator it = jspConfiguration.getJspPropertyGroups().iterator(); it.hasNext(); ) {
@@ -737,7 +737,7 @@ public List getServerSpecificDescriptors() {
/**
* A "whiteboard" context can override implicit "httpservice" context. This allows users to override the
- * context (and its path for example) used in {@link org.osgi.service.http.HttpService} scenario.
+ * context (and its path for example) used in {@link org.ops4j.pax.web.service.http.HttpService} scenario.
* @return
*/
public boolean isWhiteboard() {
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServerModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServerModel.java
index 2d9b1b2616..7c9b3e557f 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServerModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServerModel.java
@@ -47,11 +47,11 @@
import java.util.concurrent.atomic.AtomicLong;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
-import javax.servlet.Filter;
-import javax.servlet.Servlet;
-import javax.servlet.ServletContainerInitializer;
-import javax.servlet.ServletContext;
-import javax.servlet.ServletException;
+import jakarta.servlet.Filter;
+import jakarta.servlet.Servlet;
+import jakarta.servlet.ServletContainerInitializer;
+import jakarta.servlet.ServletContext;
+import jakarta.servlet.ServletException;
import org.ops4j.pax.web.annotations.PaxWebConfiguration;
import org.ops4j.pax.web.service.PaxWebConstants;
@@ -104,29 +104,29 @@
import org.osgi.framework.ServiceFactory;
import org.osgi.framework.ServiceRegistration;
import org.osgi.framework.dto.ServiceReferenceDTO;
-import org.osgi.service.http.HttpContext;
-import org.osgi.service.http.HttpService;
-import org.osgi.service.http.NamespaceException;
-import org.osgi.service.http.context.ServletContextHelper;
-import org.osgi.service.http.runtime.HttpServiceRuntime;
-import org.osgi.service.http.runtime.dto.DTOConstants;
-import org.osgi.service.http.runtime.dto.ErrorPageDTO;
-import org.osgi.service.http.runtime.dto.FailedErrorPageDTO;
-import org.osgi.service.http.runtime.dto.FailedFilterDTO;
-import org.osgi.service.http.runtime.dto.FailedListenerDTO;
-import org.osgi.service.http.runtime.dto.FailedPreprocessorDTO;
-import org.osgi.service.http.runtime.dto.FailedResourceDTO;
-import org.osgi.service.http.runtime.dto.FailedServletContextDTO;
-import org.osgi.service.http.runtime.dto.FailedServletDTO;
-import org.osgi.service.http.runtime.dto.FilterDTO;
-import org.osgi.service.http.runtime.dto.ListenerDTO;
-import org.osgi.service.http.runtime.dto.PreprocessorDTO;
-import org.osgi.service.http.runtime.dto.RequestInfoDTO;
-import org.osgi.service.http.runtime.dto.ResourceDTO;
-import org.osgi.service.http.runtime.dto.RuntimeDTO;
-import org.osgi.service.http.runtime.dto.ServletContextDTO;
-import org.osgi.service.http.runtime.dto.ServletDTO;
-import org.osgi.service.http.whiteboard.HttpWhiteboardConstants;
+import org.ops4j.pax.web.service.http.HttpContext;
+import org.ops4j.pax.web.service.http.HttpService;
+import org.ops4j.pax.web.service.http.NamespaceException;
+import org.osgi.service.servlet.context.ServletContextHelper;
+import org.osgi.service.servlet.runtime.HttpServiceRuntime;
+import org.osgi.service.servlet.runtime.dto.DTOConstants;
+import org.osgi.service.servlet.runtime.dto.ErrorPageDTO;
+import org.osgi.service.servlet.runtime.dto.FailedErrorPageDTO;
+import org.osgi.service.servlet.runtime.dto.FailedFilterDTO;
+import org.osgi.service.servlet.runtime.dto.FailedListenerDTO;
+import org.osgi.service.servlet.runtime.dto.FailedPreprocessorDTO;
+import org.osgi.service.servlet.runtime.dto.FailedResourceDTO;
+import org.osgi.service.servlet.runtime.dto.FailedServletContextDTO;
+import org.osgi.service.servlet.runtime.dto.FailedServletDTO;
+import org.osgi.service.servlet.runtime.dto.FilterDTO;
+import org.osgi.service.servlet.runtime.dto.ListenerDTO;
+import org.osgi.service.servlet.runtime.dto.PreprocessorDTO;
+import org.osgi.service.servlet.runtime.dto.RequestInfoDTO;
+import org.osgi.service.servlet.runtime.dto.ResourceDTO;
+import org.osgi.service.servlet.runtime.dto.RuntimeDTO;
+import org.osgi.service.servlet.runtime.dto.ServletContextDTO;
+import org.osgi.service.servlet.runtime.dto.ServletDTO;
+import org.osgi.service.servlet.whiteboard.HttpWhiteboardConstants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -989,10 +989,10 @@ public OsgiContextModel createNewContextModel(WebContainerContext webContext, Bu
Hashtable registration = osgiContextModel.getContextRegistrationProperties();
registration.clear();
// we pretend that this HttpContext/ServletContextModel was:
- // - registered to NOT represent the Whiteboard's context (org.osgi.service.http.context.ServletContextHelper)
+ // - registered to NOT represent the Whiteboard's context (org.osgi.service.servlet.context.ServletContextHelper)
registration.remove(HttpWhiteboardConstants.HTTP_WHITEBOARD_CONTEXT_NAME);
- // - registered to represent the HttpService's context (org.osgi.service.http.HttpContext)
- registration.put(HttpWhiteboardConstants.HTTP_SERVICE_CONTEXT_PROPERTY, webContext.getContextId());
+ // - registered to represent the HttpService's context (org.ops4j.pax.web.service.http.HttpContext)
+ registration.put(PaxWebConstants.HTTP_SERVICE_CONTEXT_PROPERTY, webContext.getContextId());
// - registered with legacy context id parameter
registration.put(PaxWebConstants.SERVICE_PROPERTY_HTTP_CONTEXT_ID, webContext.getContextId());
// - registered with given context path
@@ -3102,7 +3102,7 @@ public void visitClearDynamicRegistrationsChange(ClearDynamicRegistrationsChange
eventListeners.entrySet().removeIf(e -> e.getValue().isDynamic());
}
- // --- implementation of org.osgi.service.http.runtime.HttpServiceRuntime
+ // --- implementation of org.osgi.service.servlet.runtime.HttpServiceRuntime
@Override
public RuntimeDTO getRuntimeDTO() {
@@ -3479,13 +3479,13 @@ public void collectWebApplications(Set webapps) {
// - pax-web-extender-war deploys "full" web applications based on web.xml (and fragments + annotations)
// - pax-web-extender-whiteboard tracks Whiteboard services (servlets, filters, listeners, ...) and installs
// the web elements together with matching "context"
- // - pax-web-runtime implements org.osgi.service.http.HttpService/org.ops4j.pax.web.service.WebContainer
+ // - pax-web-runtime implements org.ops4j.pax.web.service.http.HttpService/org.ops4j.pax.web.service.WebContainer
// and allows direct registration of web elements
//
// Whatever's the origin, every "web application" is about web elements registered into single implementation
- // of javax.servlet.ServletContext (target runtime specific) which is uniquely identified by its context path.
+ // of jakarta.servlet.ServletContext (target runtime specific) which is uniquely identified by its context path.
// However in OSGi (all 3 origins), web elements are not directly registered there - there's an intermediate
- // implementation of javax.servlet.ServletContext, common for all runtimes -
+ // implementation of jakarta.servlet.ServletContext, common for all runtimes -
// org.ops4j.pax.web.service.spi.servlet.OsgiServletContext. And from configuration perspective, there's
// 1:1 mapping with even more important object - org.ops4j.pax.web.service.spi.model.OsgiContextModel
//
@@ -3494,10 +3494,10 @@ public void collectWebApplications(Set webapps) {
// - WAB - one OsgiContextModel is created for the WAB and its context path - it's always the "best"
// OsgiContextModel for ServletContext with given context path
// - Whiteboard - first, one OsgiContextModel is created for each Whiteboard-registered service of
- // org.osgi.service.http.context.ServletContextHelper and web elements choose such helper using
+ // org.osgi.service.servlet.context.ServletContextHelper and web elements choose such helper using
// "osgi.http.whiteboard.context.select" service registration property (with specification-defined default)
// - HttpService - when registering web elements, a custom (or default, if null) instance of
- // org.osgi.service.http.HttpContext is passed along the registration. For each such HttpContext,
+ // org.ops4j.pax.web.service.http.HttpContext is passed along the registration. For each such HttpContext,
// a HttpService-specific (tied to the registering bundle) OsgiContextModel is created
//
// org.ops4j.pax.web.service.spi.model.WebApplicationModel class is not used internally for actual
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServiceModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServiceModel.java
index d8dfca5a34..08750643cf 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServiceModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServiceModel.java
@@ -64,9 +64,9 @@
import org.slf4j.LoggerFactory;
/**
- *
Service Model is kept at {@link org.osgi.service.http.HttpService} level, which is bundle-scoped in Pax Web
+ *
Service Model is kept at {@link org.ops4j.pax.web.service.http.HttpService} level, which is bundle-scoped in Pax Web
* (though Http Service specification doesn't mention the scope of Http Service). Its goal is to remember which
- * web elements were registered from given bundle (both {@link org.osgi.service.http.HttpService} usage
+ * web elements were registered from given bundle (both {@link org.ops4j.pax.web.service.http.HttpService} usage
* and Whiteboard service registrations).
*
*
This is just organizational separation, because the models are kept anyway at {@link ServerModel} and
@@ -84,7 +84,7 @@ public class ServiceModel implements BatchVisitor {
/**
* Full {@link ServerModel}, while this {@link ServiceModel} collects elements registered within the scope
- * of single bundle-scoped {@link org.osgi.service.http.HttpService} or (using Whiteboard) single
+ * of single bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService} or (using Whiteboard) single
* {@link org.osgi.framework.BundleContext#registerService bundle context}.
*/
private final ServerModel serverModel;
@@ -94,15 +94,15 @@ public class ServiceModel implements BatchVisitor {
/**
*
Servlets registered under alias in given context path (exact URL pattern) by given bundle-scoped
- * {@link org.osgi.service.http.HttpService}. Group of disjoint slices of
+ * {@link org.ops4j.pax.web.service.http.HttpService}. Group of disjoint slices of
* {@code org.ops4j.pax.web.service.spi.model.ServletContextModel#aliasMapping} for all context mappings.
*
- *
Kept to fulfill the contract of {@link org.osgi.service.http.HttpService#unregister(String)}, which
+ *
Kept to fulfill the contract of {@link org.ops4j.pax.web.service.http.HttpService#unregister(String)}, which
* doesn't distinguish servlets registered under the same alias into different contexts.
*
*
Two different servlets can be registered into two different context paths ({@link ServletContextModel})
* through two different {@link OsgiContextModel} under the same alias.
- * {@link org.osgi.service.http.HttpService#unregister(String)} should unregister both of them.
+ * {@link org.ops4j.pax.web.service.http.HttpService#unregister(String)} should unregister both of them.
*
*
Also, if single servlet model is registered into two different contexts, both of them should be unregistered
* when needed.
@@ -112,16 +112,16 @@ public class ServiceModel implements BatchVisitor {
*/
private final Map> aliasMapping = new HashMap<>();
- /** All servlet models registered by given bundle-scoped {@link org.osgi.service.http.HttpService}. */
+ /** All servlet models registered by given bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService}. */
private final Set servletModels = new HashSet<>();
- /** All filter models registered by given bundle-scoped {@link org.osgi.service.http.HttpService}. */
+ /** All filter models registered by given bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService}. */
private final Set filterModels = new HashSet<>();
- /** All event listener models registered by given bundle-scoped {@link org.osgi.service.http.HttpService}. */
+ /** All event listener models registered by given bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService}. */
private final Set eventListenerModels = new HashSet<>();
- /** All container initializer models registered by given bundle-scoped {@link org.osgi.service.http.HttpService}. */
+ /** All container initializer models registered by given bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService}. */
private final Set containerInitializerModels = new HashSet<>();
/** Welcome files are just kept as a sets - separately for each {@link ContextKey}. */
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServletContextModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServletContextModel.java
index 5046a18a49..78b2c087b0 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServletContextModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServletContextModel.java
@@ -19,7 +19,7 @@
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
-import javax.servlet.ServletContext;
+import jakarta.servlet.ServletContext;
import org.ops4j.pax.web.service.spi.model.elements.ErrorPageModel;
import org.ops4j.pax.web.service.spi.model.elements.FilterModel;
@@ -28,12 +28,12 @@
/**
*
This class is 1:1 representation of server-specific {@link ServletContext} and is unaware of
- * OSGi-related representation of a context (like {@link org.osgi.service.http.HttpContext} and
- * {@link org.osgi.service.http.context.ServletContextHelper}).
+ * OSGi-related representation of a context (like {@link org.ops4j.pax.web.service.http.HttpContext} and
+ * {@link org.osgi.service.servlet.context.ServletContextHelper}).
*
*
It represents a web application (that could be described using single {@code web.xml} descriptor),
* while the web elements (like servlets, filters, ...) or configuration (session, JSP config, ...) are
- * contributed possibly by many bundles (bundle-scoped {@link org.osgi.service.http.HttpService} services or
+ * contributed possibly by many bundles (bundle-scoped {@link org.ops4j.pax.web.service.http.HttpService} services or
* whiteboard service registrations).
*
*
Normally, web applications are represented by {@code web.xml} files which are parsed by server-specific
@@ -43,10 +43,10 @@
* {@code org.apache.tomcat.util.descriptor.web.WebXmlParser#parseWebXml()}
*
*
- *
When user registers (through {@link org.osgi.service.http.HttpService} or Whiteboard) a web element
+ *
When user registers (through {@link org.ops4j.pax.web.service.http.HttpService} or Whiteboard) a web element
* (like servlet), the registration seems unique, but physically, given servlet has to be explicitly registered
* to all related {@link ServletContextModel} (and eventually - {@link ServletContext}). It is even more important
- * during unregistration - simple call to {@link org.osgi.service.http.HttpService#unregister(String)} has to
+ * during unregistration - simple call to {@link org.ops4j.pax.web.service.http.HttpService#unregister(String)} has to
* iterate over all mapped {@link ServletContextModel} contexts.
*
*
Each {@link OsgiContextModel} pointing to this class may declare virtual hosts. Actual, server
@@ -68,7 +68,7 @@ public final class ServletContextModel extends Identity {
private final Map servletNameMapping = new HashMap<>();
/**
- *
Http Service specification ({@link org.osgi.service.http.HttpService#registerServlet}) uses the concept
+ *
Http Service specification ({@link org.ops4j.pax.web.service.http.HttpService#registerServlet}) uses the concept
* of alias and requires it to be unique. It's effectively a nexact URL mapping for a servlet,
* according to "12.2 Specification of Mappings" from Servlet specification.
*
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModel.java
index 501072c2e3..84e35068d1 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModel.java
@@ -20,7 +20,7 @@
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Set;
-import javax.servlet.ServletContainerInitializer;
+import jakarta.servlet.ServletContainerInitializer;
import org.ops4j.pax.web.service.spi.model.events.ContainerInitializerEventData;
import org.ops4j.pax.web.service.spi.whiteboard.WhiteboardWebContainerView;
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModelAware.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModelAware.java
index ed2ec43216..90fbe978ce 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModelAware.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ContainerInitializerModelAware.java
@@ -16,7 +16,7 @@
package org.ops4j.pax.web.service.spi.model.elements;
/**
- * Specialized interface to communicate with {@link javax.servlet.ServletContainerInitializer} instances which
+ * Specialized interface to communicate with {@link jakarta.servlet.ServletContainerInitializer} instances which
* should be aware of {@link ContainerInitializerModel}. There's of course only one (as of 2021-07-27) such SCI,
* which is used to register already instantiated WebSocket endpoints, but we still need this interface.
*/
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ElementModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ElementModel.java
index e77209db22..628d51d55e 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ElementModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ElementModel.java
@@ -36,22 +36,22 @@
/**
*
Base class for all models representing actual elements of a web application (or
- * context), the most obvious model is representing {@link javax.servlet.Servlet}.
+ * context), the most obvious model is representing {@link jakarta.servlet.Servlet}.
*
- *
What user does (through {@link org.osgi.service.http.HttpService} or by publishing Whiteboard services) is
+ *
What user does (through {@link org.ops4j.pax.web.service.http.HttpService} or by publishing Whiteboard services) is
* a registration of web elements (like servlets) always within the context of ... well, a context
* (possibly many, as permitted by Whiteboard Service specification).
*
*
A context is not an element itself (thus - not a model), it's rather:
- *
actual {@link javax.servlet.ServletContext} from server point of view
- *
OSGi abstraction ({@link org.osgi.service.http.HttpContext} or
- * {@link org.osgi.service.http.context.ServletContextHelper}) providing additional/bridged functionality,
- * when delegating some of it to actual {@link javax.servlet.ServletContext}
+ *
actual {@link jakarta.servlet.ServletContext} from server point of view
+ *
OSGi abstraction ({@link org.ops4j.pax.web.service.http.HttpContext} or
+ * {@link org.osgi.service.servlet.context.ServletContextHelper}) providing additional/bridged functionality,
+ * when delegating some of it to actual {@link jakarta.servlet.ServletContext}
*
*
*
Each element, when registered through Whiteboard Service, may turn out to unregister some existing
* element when it uses conflicting URL mapping but has lower ranking or service id. Such conflicts lead
- * to trivial {@link org.osgi.service.http.NamespaceException} when using Http Service.
+ * to trivial {@link org.ops4j.pax.web.service.http.NamespaceException} when using Http Service.
*
* @param type of the service that user registers to be processed by Whiteboard extender (whether standard
* OSGi CMPN Whiteboard or Pax Web specific Whiteboard extender)
@@ -85,7 +85,7 @@ public abstract class ElementModel
/**
* When an element is registered as Whiteboard service, we have to keep the reference here, so we can
* use {@link ServiceReference#getBundle() a bundle} and its context to obtain a reference to
- * {@link org.osgi.service.http.context.ServletContextHelper} associated with the element.
+ * {@link org.osgi.service.servlet.context.ServletContextHelper} associated with the element.
*/
private ServiceReference elementReference;
@@ -95,7 +95,7 @@ public abstract class ElementModel
private boolean prototype = false;
/**
- * Because user may specify Whiteboard service (e.g., {@link javax.servlet.Servlet}) using legacy service
+ * Because user may specify Whiteboard service (e.g., {@link jakarta.servlet.Servlet}) using legacy service
* like {@link org.ops4j.pax.web.service.whiteboard.ServletMapping} we can't assume if method returning this
* servlet returns a singleton or an instance on each call. So we wrap such
* {@link org.ops4j.pax.web.service.whiteboard.ServletMapping} inside this {@link Supplier} to delay
@@ -108,9 +108,9 @@ public abstract class ElementModel
/**
* Even if the element is not registered as Whiteboard service, we still need a bundle in which scope
* the element was registered (for example using
- * {@link org.osgi.service.http.HttpService#registerServlet}), so
+ * {@link org.ops4j.pax.web.service.http.HttpService#registerServlet}), so
* we can use its {@link org.osgi.framework.BundleContext} to obtain proper reference to
- * {@link org.osgi.service.http.context.ServletContextHelper} if needed.
+ * {@link org.osgi.service.servlet.context.ServletContextHelper} if needed.
*/
private Bundle registeringBundle;
@@ -327,7 +327,7 @@ public void setRegisteringBundle(Bundle registeringBundle) {
/**
* Some Whiteboard services specify context selector using
- * {@link org.osgi.service.http.whiteboard.HttpWhiteboardConstants#HTTP_WHITEBOARD_CONTEXT_SELECT} service
+ * {@link org.osgi.service.servlet.whiteboard.HttpWhiteboardConstants#HTTP_WHITEBOARD_CONTEXT_SELECT} service
* registration property and some (legacy) using {@link ContextRelated#getContextId()}/{@link ContextRelated#getContextSelectFilter()}.
* After setting the selector, we no longer have to resolve one.
* @param mappingSelector
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ErrorPageModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ErrorPageModel.java
index 58ca32c32e..7dfbe92bd2 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ErrorPageModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ErrorPageModel.java
@@ -27,9 +27,9 @@
import org.ops4j.pax.web.service.spi.whiteboard.WhiteboardWebContainerView;
import org.ops4j.pax.web.service.whiteboard.ErrorPageMapping;
import org.osgi.framework.wiring.BundleWiring;
-import org.osgi.service.http.runtime.dto.DTOConstants;
-import org.osgi.service.http.runtime.dto.ErrorPageDTO;
-import org.osgi.service.http.runtime.dto.FailedErrorPageDTO;
+import org.osgi.service.servlet.runtime.dto.DTOConstants;
+import org.osgi.service.servlet.runtime.dto.ErrorPageDTO;
+import org.osgi.service.servlet.runtime.dto.FailedErrorPageDTO;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/EventListenerModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/EventListenerModel.java
index 023848af14..0d661a1e88 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/EventListenerModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/EventListenerModel.java
@@ -21,9 +21,9 @@
import org.ops4j.pax.web.service.spi.util.Utils;
import org.ops4j.pax.web.service.spi.whiteboard.WhiteboardWebContainerView;
import org.osgi.framework.BundleContext;
-import org.osgi.service.http.runtime.dto.DTOConstants;
-import org.osgi.service.http.runtime.dto.FailedListenerDTO;
-import org.osgi.service.http.runtime.dto.ListenerDTO;
+import org.osgi.service.servlet.runtime.dto.DTOConstants;
+import org.osgi.service.servlet.runtime.dto.FailedListenerDTO;
+import org.osgi.service.servlet.runtime.dto.ListenerDTO;
import java.util.Arrays;
import java.util.EventListener;
@@ -47,7 +47,7 @@ public class EventListenerModel extends ElementModelholder classes which
* control the lifecycle of servlets/filters, but here we do it ourselves, as there's no
- * lifecycle of the listener itself from the point of view of JavaEE Servlets specification.
+ * lifecycle of the listener itself from the point of view of JakartaEE Servlets specification.
* @return
*/
public EventListener resolveEventListener() {
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/FilterModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/FilterModel.java
index 3763c57a14..d585af09af 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/FilterModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/FilterModel.java
@@ -32,9 +32,9 @@
import java.util.UUID;
import java.util.function.Supplier;
import java.util.stream.Collectors;
-import javax.servlet.DispatcherType;
-import javax.servlet.Filter;
-import javax.servlet.FilterConfig;
+import jakarta.servlet.DispatcherType;
+import jakarta.servlet.Filter;
+import jakarta.servlet.FilterConfig;
import org.ops4j.pax.web.service.PaxWebConstants;
import org.ops4j.pax.web.service.spi.model.OsgiContextModel;
@@ -44,11 +44,11 @@
import org.ops4j.pax.web.service.spi.whiteboard.WhiteboardWebContainerView;
import org.osgi.framework.Bundle;
import org.osgi.framework.ServiceReference;
-import org.osgi.service.http.runtime.dto.DTOConstants;
-import org.osgi.service.http.runtime.dto.FailedFilterDTO;
-import org.osgi.service.http.runtime.dto.FailedPreprocessorDTO;
-import org.osgi.service.http.runtime.dto.FilterDTO;
-import org.osgi.service.http.runtime.dto.PreprocessorDTO;
+import org.osgi.service.servlet.runtime.dto.DTOConstants;
+import org.osgi.service.servlet.runtime.dto.FailedFilterDTO;
+import org.osgi.service.servlet.runtime.dto.FailedPreprocessorDTO;
+import org.osgi.service.servlet.runtime.dto.FilterDTO;
+import org.osgi.service.servlet.runtime.dto.PreprocessorDTO;
/**
* Set of parameters describing everything that's required to register a {@link Filter}.
@@ -57,7 +57,7 @@ public class FilterModel extends ElementModel {
/**
*
URL patterns and servlet names (per dispatcher type) as specified by:
- *
Pax Web specific extensions to {@link org.osgi.service.http.HttpService}
+ *
Pax Web specific extensions to {@link org.ops4j.pax.web.service.http.HttpService}
*
Whiteboard Service specification
*
Servlet API specification
*
@@ -74,8 +74,8 @@ public class FilterModel extends ElementModel {
private String[] flatDispatcherTypes;
/**
- * When using {@link javax.servlet.ServletContext#addFilter(String, Filter)} and
- * {@link javax.servlet.FilterRegistration.Dynamic#addMappingForServletNames(EnumSet, boolean, String...)} we
+ * When using {@link jakarta.servlet.ServletContext#addFilter(String, Filter)} and
+ * {@link jakarta.servlet.FilterRegistration.Dynamic#addMappingForServletNames(EnumSet, boolean, String...)} we
* need to store distinct sets of mappings separately for different dispatchers (and order)
*/
private final List dynamicUrlPatterns = new LinkedList<>();
@@ -107,11 +107,11 @@ public class FilterModel extends ElementModel {
private final Class extends Filter> filterClass;
/**
- * Flag used for models registered using {@link javax.servlet.ServletContext#addFilter}
+ * Flag used for models registered using {@link jakarta.servlet.ServletContext#addFilter}
*/
private boolean dynamic = false;
- /** Flag to mark a {@link FilterModel} for {@link org.osgi.service.http.whiteboard.Preprocessor} */
+ /** Flag to mark a {@link FilterModel} for {@link org.osgi.service.servlet.whiteboard.Preprocessor} */
private boolean preprocessor = false;
/**
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/JspConfigurationModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/JspConfigurationModel.java
index 5cdd8830d1..d540628fac 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/JspConfigurationModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/JspConfigurationModel.java
@@ -18,9 +18,9 @@
import java.util.Collection;
import java.util.LinkedList;
import java.util.List;
-import javax.servlet.descriptor.JspConfigDescriptor;
-import javax.servlet.descriptor.JspPropertyGroupDescriptor;
-import javax.servlet.descriptor.TaglibDescriptor;
+import jakarta.servlet.descriptor.JspConfigDescriptor;
+import jakarta.servlet.descriptor.JspPropertyGroupDescriptor;
+import jakarta.servlet.descriptor.TaglibDescriptor;
import org.ops4j.pax.web.service.spi.config.Configuration;
import org.ops4j.pax.web.service.spi.model.OsgiContextModel;
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConfigurationModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConfigurationModel.java
index ef1172e24d..8a887be433 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConfigurationModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConfigurationModel.java
@@ -43,7 +43,7 @@
*
*
*
- *
Additionally, security declarations may be passed through {@link javax.servlet.ServletRegistration.Dynamic#setServletSecurity}
+ *
Additionally, security declarations may be passed through {@link jakarta.servlet.ServletRegistration.Dynamic#setServletSecurity}
* and for example, Tomcat passes the arguments to {@code org.apache.catalina.core.StandardContext#addServletSecurity()}.
*/
public class SecurityConfigurationModel extends ElementModel {
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConstraintModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConstraintModel.java
index 412edca7c2..d8ec10fcd8 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConstraintModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SecurityConstraintModel.java
@@ -15,8 +15,8 @@
*/
package org.ops4j.pax.web.service.spi.model.elements;
-import javax.servlet.ServletSecurityElement;
-import javax.servlet.annotation.ServletSecurity;
+import jakarta.servlet.ServletSecurityElement;
+import jakarta.servlet.annotation.ServletSecurity;
import java.util.ArrayList;
import java.util.List;
@@ -44,7 +44,7 @@ public class SecurityConstraintModel {
/**
* If the security constraint model was created from Servlet-specific configuration like:
- *
{@link javax.servlet.ServletRegistration.Dynamic#setServletSecurity(ServletSecurityElement)}, or
+ *
{@link jakarta.servlet.ServletRegistration.Dynamic#setServletSecurity(ServletSecurityElement)}, or
*
{@link ServletSecurity} annotation
*
we remember the associated {@link ServletModel}, so dynamic security constraints are properly applied.
*/
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ServletModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ServletModel.java
index 0e22f99215..e3e8435bf6 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ServletModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/ServletModel.java
@@ -30,10 +30,10 @@
import java.util.Map;
import java.util.UUID;
import java.util.function.Supplier;
-import javax.servlet.MultipartConfigElement;
-import javax.servlet.Servlet;
-import javax.servlet.ServletConfig;
-import javax.servlet.ServletContext;
+import jakarta.servlet.MultipartConfigElement;
+import jakarta.servlet.Servlet;
+import jakarta.servlet.ServletConfig;
+import jakarta.servlet.ServletContext;
import org.ops4j.pax.web.service.PaxWebConstants;
import org.ops4j.pax.web.service.spi.config.JspConfiguration;
@@ -45,13 +45,13 @@
import org.ops4j.pax.web.service.whiteboard.ServletMapping;
import org.osgi.framework.Bundle;
import org.osgi.framework.ServiceReference;
-import org.osgi.service.http.HttpService;
-import org.osgi.service.http.context.ServletContextHelper;
-import org.osgi.service.http.runtime.dto.DTOConstants;
-import org.osgi.service.http.runtime.dto.FailedResourceDTO;
-import org.osgi.service.http.runtime.dto.FailedServletDTO;
-import org.osgi.service.http.runtime.dto.ResourceDTO;
-import org.osgi.service.http.runtime.dto.ServletDTO;
+import org.ops4j.pax.web.service.http.HttpService;
+import org.osgi.service.servlet.context.ServletContextHelper;
+import org.osgi.service.servlet.runtime.dto.DTOConstants;
+import org.osgi.service.servlet.runtime.dto.FailedResourceDTO;
+import org.osgi.service.servlet.runtime.dto.FailedServletDTO;
+import org.osgi.service.servlet.runtime.dto.ResourceDTO;
+import org.osgi.service.servlet.runtime.dto.ServletDTO;
/**
* Set of parameters describing everything that's required to register a {@link Servlet}.
@@ -406,13 +406,6 @@ public Boolean performValidation() throws Exception {
initParams.put("jspFile", jspFile);
}
- if (multipartConfigElement != null && multipartConfigElement.getLocation() != null) {
- if (System.getSecurityManager() != null && !getRegisteringBundle().hasPermission(new FilePermission(multipartConfigElement.getLocation(), "read,write,delete"))) {
- dtoFailureCode = DTOConstants.FAILURE_REASON_SERVLET_WRITE_TO_LOCATION_DENIED;
- throw new IllegalArgumentException("No Write permission to " + multipartConfigElement.getLocation());
- }
- }
-
dtoFailureCode = -1;
return Boolean.TRUE;
}
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SessionConfigurationModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SessionConfigurationModel.java
index 96f4f837d4..81710661e9 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SessionConfigurationModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/SessionConfigurationModel.java
@@ -17,8 +17,8 @@
import java.util.HashSet;
import java.util.Set;
-import javax.servlet.SessionCookieConfig;
-import javax.servlet.SessionTrackingMode;
+import jakarta.servlet.SessionCookieConfig;
+import jakarta.servlet.SessionTrackingMode;
import org.ops4j.pax.web.service.PaxWebConstants;
import org.ops4j.pax.web.service.spi.model.OsgiContextModel;
@@ -51,7 +51,7 @@ public class SessionConfigurationModel {
// - SameSite(enum None/Strict/Lax) - "Session cookie sameSite mode. Currently this is encoded in the session comment until sameSite is supported by SessionCookieConfig"
// - SecureRequestOnly(boolean) (different than SessionCookieConfig.setSecure()) - "if session cookie is to be marked as secure only on HTTPS requests"
// - SessionIdPathParameterName(string), default "jsessionid" - "the URL path parameter name for session id URL rewriting (null or "none" for no rewriting)"
- // - UsingCookies(boolean), default true, set if javax.servlet.SessionTrackingMode.COOKIE is used
+ // - UsingCookies(boolean), default true, set if jakarta.servlet.SessionTrackingMode.COOKIE is used
// Tomcat (org.apache.catalina.core.StandardContext):
// - sessionCookiePathUsesTrailingSlash(boolean), default false - "Is a / added to the end of the session cookie path to ensure browsers, particularly IE, don't send a session cookie for context /foo with requests intended for context /foobar."
// Undertow:
diff --git a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/WebSocketModel.java b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/WebSocketModel.java
index b9fdbfa26e..adf9120450 100644
--- a/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/WebSocketModel.java
+++ b/pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/elements/WebSocketModel.java
@@ -15,9 +15,9 @@
*/
package org.ops4j.pax.web.service.spi.model.elements;
-import javax.websocket.Decoder;
-import javax.websocket.Encoder;
-import javax.websocket.server.ServerEndpoint;
+import jakarta.websocket.Decoder;
+import jakarta.websocket.Encoder;
+import jakarta.websocket.server.ServerEndpoint;
import org.ops4j.pax.web.service.spi.model.events.WebSocketEventData;
import org.ops4j.pax.web.service.spi.whiteboard.WhiteboardWebContainerView;
@@ -33,11 +33,11 @@ public class WebSocketModel extends ElementModel