Skip to content
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
5 changes: 1 addition & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -264,10 +264,7 @@ subprojects {
options.compilerArgs << "-Xlint:-rawtypes"
options.compilerArgs << "-Xlint:-serial"
options.compilerArgs << "-Xlint:-try"
// AutoMQ inject start
// TODO: remove me, when upgrade to 4.x
// options.compilerArgs << "-Werror"
// AutoMQ inject start
options.compilerArgs << "-Werror"

// --release is the recommended way to select the target release, but it's only supported in Java 9 so we also
// set --source and --target via `sourceCompatibility` and `targetCompatibility` a couple of lines below
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ public void configure(Map<String, ?> configs, String saslMechanism, List<AppConf
this.mechanism = saslMechanism;
}

@SuppressWarnings("removal")
@Override
public void handle(Callback[] callbacks) throws UnsupportedCallbackException {
Subject subject = Subject.getSubject(AccessController.getContext());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ public void configure(Map<String, ?> configs, String saslMechanism, List<AppConf
configured = true;
}

@SuppressWarnings("removal")
@Override
public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException {
if (!configured())
Expand All @@ -94,6 +95,7 @@ public void close() {
// empty
}

@SuppressWarnings("removal")
private void handleCallback(OAuthBearerTokenCallback callback) throws IOException {
if (callback.token() != null)
throw new IllegalArgumentException("Callback had a token already");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,7 @@ public int getBasicConstraints() {
return this.origCertificate.getBasicConstraints();
}

@SuppressWarnings("deprecation")
@Override
public Principal getIssuerDN() {
return this.origCertificate.getIssuerDN();
Expand Down Expand Up @@ -370,6 +371,7 @@ public byte[] getSignature() {
return this.origCertificate.getSignature();
}

@SuppressWarnings("deprecation")
@Override
public Principal getSubjectDN() {
return this.origCertificate.getSubjectDN();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ public void testWithZeroTokens() {
assertEquals(IOException.class, e.getCause().getClass());
}

@SuppressWarnings("removal")
@Test()
public void testWithPotentiallyMultipleTokens() throws Exception {
OAuthBearerSaslClientCallbackHandler handler = createCallbackHandler();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ public void setUpOnce() throws CertificateException, NoSuchAlgorithmException {
chainWithValidAndInvalidEndCertificates = generateKeyChainIncludingCA(false, true, true, false);
}

@SuppressWarnings("deprecation")
@Test
void testNeverExpiringX509Certificate() throws Exception {
final KeyPair keyPair = TestSslUtils.generateKeyPair("RSA");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@ public class DistributedHerder extends AbstractHerder implements Runnable {
* @param uponShutdown any {@link AutoCloseable} objects that should be closed when this herder is {@link #stop() stopped},
* after all services and resources owned by this herder are stopped
*/
@SuppressWarnings("this-escape")
public DistributedHerder(DistributedConfig config,
Time time,
Worker worker,
Expand All @@ -272,6 +273,7 @@ public DistributedHerder(DistributedConfig config,
}

// visible for testing
@SuppressWarnings("this-escape")
DistributedHerder(DistributedConfig config,
Worker worker,
String workerId,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@
*/
public class ClassLoaderFactory implements PluginClassLoaderFactory {

@SuppressWarnings("removal")
public DelegatingClassLoader newDelegatingClassLoader(ClassLoader parent) {
return AccessController.doPrivileged(
(PrivilegedAction<DelegatingClassLoader>) () -> new DelegatingClassLoader(parent)
);
}

@SuppressWarnings("removal")
public PluginClassLoader newPluginClassLoader(URL pluginLocation, URL[] urls, ClassLoader parent) {
return AccessController.doPrivileged(
(PrivilegedAction<PluginClassLoader>) () -> new PluginClassLoader(pluginLocation, urls, parent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ private PluginScanResult scanUrlsAndAddPlugins(PluginSource source) {
*/
protected abstract PluginScanResult scanPlugins(PluginSource source);

@SuppressWarnings("removal")
private void loadJdbcDrivers(final ClassLoader loader) {
// Apply here what java.sql.DriverManager does to discover and register classes
// implementing the java.sql.Driver interface.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ public MultiThreadedEventProcessor(
* @param time The time.
* @param eventAccumulator The event accumulator.
*/
@SuppressWarnings("this-escape")
public MultiThreadedEventProcessor(
LogContext logContext,
String threadPrefix,
Expand Down
Loading