Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #12023 - Remove deprecated classes/methods. #12146

Open
wants to merge 1 commit into
base: jetty-12.1.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ public boolean accept(Connection connection)
attachable.setAttachment(new EntryHolder(entry));
onCreated(connection);
entry.enable(connection, false);
idle(connection, false);
return true;
}

Expand Down Expand Up @@ -359,7 +358,6 @@ protected Connection activate()

if (LOG.isDebugEnabled())
LOG.debug("Activated {} {}", entry, pool);
acquired(connection);
return connection;
}
return null;
Expand All @@ -380,10 +378,7 @@ public boolean isActive(Connection connection)
@Override
public boolean release(Connection connection)
{
if (!deactivate(connection))
return false;
released(connection);
return idle(connection, isStopped());
return deactivate(connection);
}

protected boolean deactivate(Connection connection)
Expand Down Expand Up @@ -432,10 +427,7 @@ public boolean remove(Connection connection)
if (LOG.isDebugEnabled())
LOG.debug("Removed ({}) {} {}", removed, holder.entry, pool);
if (removed)
{
released(connection);
onRemoved(connection);
}
return removed;
}

Expand All @@ -449,45 +441,6 @@ protected void onCreated(Connection connection)
{
}

/**
* @param connection the {@link Connection} that become idle
* @param close whether this pool is closing
* @return {@code true} to indicate that the connection is idle, {@code false} otherwise
* @deprecated Racy API. Do not use. There is no replacement.
*/
@Deprecated(since = "12.0.8", forRemoval = true)
protected boolean idle(Connection connection, boolean close)
sbordet marked this conversation as resolved.
Show resolved Hide resolved
{
return !close;
}

/**
* @param connection the {@link Connection} that was acquired
* @deprecated Racy API. Do not use. There is no replacement.
*/
@Deprecated(since = "12.0.8", forRemoval = true)
protected void acquired(Connection connection)
{
}

/**
* @param connection the {@link Connection} that was released
* @deprecated Racy API. Do not use. There is no replacement.
*/
@Deprecated(since = "12.0.8", forRemoval = true)
protected void released(Connection connection)
{
}

/**
* @param connection the {@link Connection} that was removed
* @deprecated replaced by {@link #onRemoved(Connection)}
*/
@Deprecated(since = "12.0.8", forRemoval = true)
protected void removed(Connection connection)
{
}

/**
* <p>Callback method invoked when a {@link Connection} has been removed from this pool.</p>
*
Expand All @@ -496,7 +449,6 @@ protected void removed(Connection connection)
*/
protected void onRemoved(Connection connection)
{
removed(connection);
}

Collection<Connection> getIdleConnections()
Expand Down Expand Up @@ -610,7 +562,6 @@ public void succeeded(Connection connection)
onCreated(connection);
pending.decrementAndGet();
reserved.enable(connection, false);
idle(connection, false);
super.succeeded(connection);
proceed();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@ public boolean release(Connection connection)
quarantine.put(connection, holder);
if (LOG.isDebugEnabled())
LOG.debug("Validating for {}ms {}", timeout, connection);

released(connection);
return true;
}

Expand Down Expand Up @@ -135,7 +133,6 @@ public void run()
quarantine.remove(connection);
if (!closed)
deactivate(connection);
idle(connection, closed);
proceed();
}
}
Expand Down
Loading