This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new 8fc4c84525 Javadoc improvements
8fc4c84525 is described below
commit 8fc4c8452589687109ea0a5f72a10b0c764ad3a3
Author: Mark Thomas <[email protected]>
AuthorDate: Thu Aug 14 17:33:50 2025 +0100
Javadoc improvements
Methods with Javadoc that override/implement methods without identified
by Cursor. Actual Javadoc changes not AI generated.
---
java/jakarta/servlet/GenericServlet.java | 9 +--------
java/org/apache/catalina/core/StandardContext.java | 2 ++
.../apache/catalina/ha/session/BackupManager.java | 20 +++++++-------------
java/org/apache/catalina/servlets/CGIServlet.java | 10 ++--------
java/org/apache/catalina/util/LifecycleBase.java | 9 +++++----
.../org/apache/catalina/valves/ErrorReportValve.java | 8 ++------
.../apache/catalina/valves/ParameterLimitValve.java | 8 ++------
7 files changed, 21 insertions(+), 45 deletions(-)
diff --git a/java/jakarta/servlet/GenericServlet.java
b/java/jakarta/servlet/GenericServlet.java
index 589b8ba05d..19043e89b8 100644
--- a/java/jakarta/servlet/GenericServlet.java
+++ b/java/jakarta/servlet/GenericServlet.java
@@ -127,17 +127,10 @@ public abstract class GenericServlet implements Servlet,
ServletConfig, java.io.
}
/**
- * Called by the servlet container to indicate to a servlet that the
servlet is being placed into service. See
- * {@link Servlet#init}.
+ * {@inheritDoc}
* <p>
* This implementation stores the {@link ServletConfig} object it receives
from the servlet container for later use.
* When overriding this form of the method, call
<code>super.init(config)</code>.
- *
- * @param config the <code>ServletConfig</code> object that contains
configuration information for this servlet
- *
- * @exception ServletException if an exception occurs that interrupts the
servlet's normal operation
- *
- * @see UnavailableException
*/
@Override
public void init(ServletConfig config) throws ServletException {
diff --git a/java/org/apache/catalina/core/StandardContext.java
b/java/org/apache/catalina/core/StandardContext.java
index 70c817a061..3232d6fa39 100644
--- a/java/org/apache/catalina/core/StandardContext.java
+++ b/java/org/apache/catalina/core/StandardContext.java
@@ -4741,6 +4741,8 @@ public class StandardContext extends ContainerBase
implements Context, Notificat
}
/**
+ * {@inheritDoc}
+ * <p>
* Destroy needs to clean up the context completely. The problem is that
undoing all the config in start() and
* restoring a 'fresh' state is impossible. After
stop()/destroy()/init()/start() we should have the same state as
* if a fresh start was done - i.e. read modified web.xml, etc. This can
only be done by completely removing the
diff --git a/java/org/apache/catalina/ha/session/BackupManager.java
b/java/org/apache/catalina/ha/session/BackupManager.java
index 073ee9ebc8..4943de2424 100644
--- a/java/org/apache/catalina/ha/session/BackupManager.java
+++ b/java/org/apache/catalina/ha/session/BackupManager.java
@@ -122,13 +122,10 @@ public class BackupManager extends ClusterManagerBase
implements MapOwner, Distr
/**
- * Start this component and implement the requirements of
- * {@link org.apache.catalina.util.LifecycleBase#startInternal()}. Starts
the cluster communication channel, this
- * will connect with the other nodes in the cluster, and request the
current session state to be transferred to this
- * node.
- *
- * @exception LifecycleException if this component detects a fatal error
that prevents this component from being
- * used
+ * {@inheritDoc}
+ * <p>
+ * Starts the cluster communication channel, this will connect with the
other nodes in the cluster, and request the
+ * current session state to be transferred to this node.
*/
@Override
protected void startInternal() throws LifecycleException {
@@ -161,12 +158,9 @@ public class BackupManager extends ClusterManagerBase
implements MapOwner, Distr
/**
- * Stop this component and implement the requirements of
- * {@link org.apache.catalina.util.LifecycleBase#stopInternal()}. This
will disconnect the cluster communication
- * channel and stop the listener thread.
- *
- * @exception LifecycleException if this component detects a fatal error
that prevents this component from being
- * used
+ * {@inheritDoc}
+ * <p>
+ * This will disconnect the cluster communication channel and stop the
listener thread.
*/
@Override
protected void stopInternal() throws LifecycleException {
diff --git a/java/org/apache/catalina/servlets/CGIServlet.java
b/java/org/apache/catalina/servlets/CGIServlet.java
index ab3f7f6fd2..02507fb14b 100644
--- a/java/org/apache/catalina/servlets/CGIServlet.java
+++ b/java/org/apache/catalina/servlets/CGIServlet.java
@@ -290,15 +290,9 @@ public final class CGIServlet extends HttpServlet {
/**
+ * {@inheritDoc}
+ * <p>
* Sets instance variables.
- * <P>
- * Modified from Craig R. McClanahan's InvokerServlet
- * </P>
- *
- * @param config a <code>ServletConfig</code> object containing the
servlet's configuration and initialization
- * parameters
- *
- * @exception ServletException if an exception has occurred that
interferes with the servlet's normal operation
*/
@Override
public void init(ServletConfig config) throws ServletException {
diff --git a/java/org/apache/catalina/util/LifecycleBase.java
b/java/org/apache/catalina/util/LifecycleBase.java
index 1d59e54812..521ec1a86b 100644
--- a/java/org/apache/catalina/util/LifecycleBase.java
+++ b/java/org/apache/catalina/util/LifecycleBase.java
@@ -184,11 +184,11 @@ public abstract class LifecycleBase implements Lifecycle {
/**
* Subclasses must ensure that the state is changed to {@link
LifecycleState#STARTING} during the execution of this
* method. Changing state will trigger the {@link Lifecycle#START_EVENT}
event. If a component fails to start it may
- * either throw a {@link LifecycleException} which will cause it's parent
to fail to start, or it can place itself in
- * the error state in which case {@link #stop()} will be called on the
failed component but the parent component
+ * either throw a {@link LifecycleException} which will cause it's parent
to fail to start, or it can place itself
+ * in the error state in which case {@link #stop()} will be called on the
failed component but the parent component
* will continue to start normally.
*
- * @throws LifecycleException Start error occurred
+ * @exception LifecycleException if this component detects an error that
prevents this component from being started
*/
protected abstract void startInternal() throws LifecycleException;
@@ -257,7 +257,8 @@ public abstract class LifecycleBase implements Lifecycle {
* Subclasses must ensure that the state is changed to {@link
LifecycleState#STOPPING} during the execution of this
* method. Changing state will trigger the {@link Lifecycle#STOP_EVENT}
event.
*
- * @throws LifecycleException Stop error occurred
+ * @exception LifecycleException if this component detects an error that
prevents this component from being stopped
+ * cleanly
*/
protected abstract void stopInternal() throws LifecycleException;
diff --git a/java/org/apache/catalina/valves/ErrorReportValve.java
b/java/org/apache/catalina/valves/ErrorReportValve.java
index fcb673cd5a..cccc89a823 100644
--- a/java/org/apache/catalina/valves/ErrorReportValve.java
+++ b/java/org/apache/catalina/valves/ErrorReportValve.java
@@ -77,14 +77,10 @@ public class ErrorReportValve extends ValveBase {
// --------------------------------------------------------- Public Methods
/**
+ * {@inheritDoc}
+ * <p>
* Invoke the next Valve in the sequence. When the invoke returns, check
the response state. If the status code is
* greater than or equal to 400 or an uncaught exception was thrown then
the error handling will be triggered.
- *
- * @param request The servlet request to be processed
- * @param response The servlet response to be created
- *
- * @exception IOException if an input/output error occurs
- * @exception ServletException if a servlet error occurs
*/
@Override
public void invoke(Request request, Response response) throws IOException,
ServletException {
diff --git a/java/org/apache/catalina/valves/ParameterLimitValve.java
b/java/org/apache/catalina/valves/ParameterLimitValve.java
index f31192b4a8..c20f3fdb5d 100644
--- a/java/org/apache/catalina/valves/ParameterLimitValve.java
+++ b/java/org/apache/catalina/valves/ParameterLimitValve.java
@@ -243,14 +243,10 @@ public class ParameterLimitValve extends ValveBase {
}
/**
+ * {@inheritDoc}
+ * <p>
* Checks if any of the defined patterns matches the URI of the request
and if it does, enforces the corresponding
* parameter limit for the request. Then invoke the next Valve in the
sequence.
- *
- * @param request The servlet request to be processed
- * @param response The servlet response to be created
- *
- * @exception IOException if an input/output error occurs
- * @exception ServletException if a servlet error occurs
*/
@Override
public void invoke(Request request, Response response) throws IOException,
ServletException {
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]