Skip to content

Commit 03bc72f

Browse files
wendigolosipiuk
authored andcommitted
Move throws declaration to new line
1 parent ddaa765 commit 03bc72f

File tree

12 files changed

+50
-25
lines changed

12 files changed

+50
-25
lines changed

client/trino-client/src/main/java/io/trino/client/auth/external/CompositeRedirectHandler.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ public CompositeRedirectHandler(List<ExternalRedirectStrategy> strategies)
3434
}
3535

3636
@Override
37-
public void redirectTo(URI uri) throws RedirectException
37+
public void redirectTo(URI uri)
38+
throws RedirectException
3839
{
3940
RedirectException redirectException = new RedirectException("Could not redirect to " + uri);
4041
for (RedirectHandler handler : handlers) {

client/trino-client/src/main/java/io/trino/client/auth/external/SystemOutPrintRedirectHandler.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ public class SystemOutPrintRedirectHandler
1919
implements RedirectHandler
2020
{
2121
@Override
22-
public void redirectTo(URI uri) throws RedirectException
22+
public void redirectTo(URI uri)
23+
throws RedirectException
2324
{
2425
System.out.println("External authentication required. Please go to:");
2526
System.out.println(uri.toString());

core/trino-main/src/main/java/io/trino/server/security/HeaderAuthenticator.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ public HeaderAuthenticator(HeaderAuthenticatorConfig authenticatorConfig, Header
4646
}
4747

4848
@Override
49-
public Identity authenticate(ContainerRequestContext request) throws AuthenticationException
49+
public Identity authenticate(ContainerRequestContext request)
50+
throws AuthenticationException
5051
{
5152
AuthenticationException exception = null;
5253
Map<String, List<String>> lowerCasedHeaders = request.getHeaders().entrySet().stream()

core/trino-main/src/test/java/io/trino/execution/scheduler/TestBinPackingNodeAllocator.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -704,6 +704,7 @@ private static void assertEventually(ThrowingRunnable assertion)
704704

705705
interface ThrowingRunnable
706706
{
707-
void run() throws Exception;
707+
void run()
708+
throws Exception;
708709
}
709710
}

lib/trino-hdfs/src/test/java/io/trino/hdfs/TestFileSystemCache.java

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,8 @@ public void testFileSystemCache()
7979
}
8080

8181
@Test
82-
public void testFileSystemCacheException() throws IOException
82+
public void testFileSystemCacheException()
83+
throws IOException
8384
{
8485
HdfsEnvironment environment = new HdfsEnvironment(
8586
new DynamicHdfsConfiguration(new HdfsConfigurationInitializer(new HdfsConfig()), ImmutableSet.of()),
@@ -98,7 +99,8 @@ public void testFileSystemCacheException() throws IOException
9899
}
99100

100101
@Test
101-
public void testFileSystemCacheConcurrency() throws InterruptedException, ExecutionException, IOException
102+
public void testFileSystemCacheConcurrency()
103+
throws InterruptedException, ExecutionException, IOException
102104
{
103105
int numThreads = 20;
104106
List<Callable<Void>> callableTasks = new ArrayList<>();
@@ -127,15 +129,17 @@ private static FileSystem getFileSystem(HdfsEnvironment environment, ConnectorId
127129
@FunctionalInterface
128130
public interface FileSystemConsumer
129131
{
130-
void consume(FileSystem fileSystem) throws IOException;
132+
void consume(FileSystem fileSystem)
133+
throws IOException;
131134
}
132135

133136
private static class FileSystemCloser
134137
implements FileSystemConsumer
135138
{
136139
@Override
137140
@SuppressModernizer
138-
public void consume(FileSystem fileSystem) throws IOException
141+
public void consume(FileSystem fileSystem)
142+
throws IOException
139143
{
140144
fileSystem.close(); /* triggers fscache.remove() */
141145
}
@@ -163,7 +167,8 @@ public static class CreateFileSystemsAndConsume
163167
}
164168

165169
@Override
166-
public Void call() throws IOException
170+
public Void call()
171+
throws IOException
167172
{
168173
for (int i = 0; i < getCallsPerInvocation; i++) {
169174
FileSystem fs = getFileSystem(environment, ConnectorIdentity.ofUser("user" + random.nextInt(userCount)));

lib/trino-phoenix5-patched/src/main/java/org/apache/phoenix/shaded/org/apache/zookeeper/client/StaticHostProvider.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ public final class StaticHostProvider
2828
{
2929
public interface Resolver
3030
{
31-
InetAddress[] getAllByName(String name) throws UnknownHostException;
31+
InetAddress[] getAllByName(String name)
32+
throws UnknownHostException;
3233
}
3334

3435
private final List<InetSocketAddress> serverAddresses = new ArrayList<InetSocketAddress>(5);

plugin/trino-exchange-filesystem/src/main/java/io/trino/plugin/exchange/filesystem/FileSystemExchangeStorage.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222
public interface FileSystemExchangeStorage
2323
extends AutoCloseable
2424
{
25-
void createDirectories(URI dir) throws IOException;
25+
void createDirectories(URI dir)
26+
throws IOException;
2627

2728
ExchangeStorageReader createExchangeStorageReader(List<ExchangeSourceFile> sourceFiles, int maxPageStorageSize);
2829

@@ -37,5 +38,6 @@ public interface FileSystemExchangeStorage
3738
int getWriteBufferSize();
3839

3940
@Override
40-
void close() throws IOException;
41+
void close()
42+
throws IOException;
4143
}

plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/TestIcebergMergeAppend.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ public class TestIcebergMergeAppend
4848
private IcebergTableOperationsProvider tableOperationsProvider;
4949

5050
@Override
51-
protected QueryRunner createQueryRunner() throws Exception
51+
protected QueryRunner createQueryRunner()
52+
throws Exception
5253
{
5354
DistributedQueryRunner queryRunner = IcebergQueryRunner.createIcebergQueryRunner();
5455
File baseDir = queryRunner.getCoordinator().getBaseDataDir().resolve("iceberg_data").toFile();

plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/catalog/hms/TestIcebergHiveMetastoreTableOperationsReleaseLockFailure.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ public class TestIcebergHiveMetastoreTableOperationsReleaseLockFailure
4949
private File baseDir;
5050

5151
@Override
52-
protected LocalQueryRunner createQueryRunner() throws Exception
52+
protected LocalQueryRunner createQueryRunner()
53+
throws Exception
5354
{
5455
Session session = testSessionBuilder()
5556
.setCatalog(ICEBERG_CATALOG)

plugin/trino-kudu/src/main/java/io/trino/plugin/kudu/KuduClientWrapper.java

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,28 +30,37 @@
3030
public interface KuduClientWrapper
3131
extends AutoCloseable
3232
{
33-
KuduTable createTable(String name, Schema schema, CreateTableOptions builder) throws KuduException;
33+
KuduTable createTable(String name, Schema schema, CreateTableOptions builder)
34+
throws KuduException;
3435

35-
DeleteTableResponse deleteTable(String name) throws KuduException;
36+
DeleteTableResponse deleteTable(String name)
37+
throws KuduException;
3638

37-
AlterTableResponse alterTable(String name, AlterTableOptions ato) throws KuduException;
39+
AlterTableResponse alterTable(String name, AlterTableOptions ato)
40+
throws KuduException;
3841

39-
ListTablesResponse getTablesList() throws KuduException;
42+
ListTablesResponse getTablesList()
43+
throws KuduException;
4044

41-
ListTablesResponse getTablesList(String nameFilter) throws KuduException;
45+
ListTablesResponse getTablesList(String nameFilter)
46+
throws KuduException;
4247

43-
boolean tableExists(String name) throws KuduException;
48+
boolean tableExists(String name)
49+
throws KuduException;
4450

45-
KuduTable openTable(String name) throws KuduException;
51+
KuduTable openTable(String name)
52+
throws KuduException;
4653

4754
KuduScanner.KuduScannerBuilder newScannerBuilder(KuduTable table);
4855

4956
KuduScanToken.KuduScanTokenBuilder newScanTokenBuilder(KuduTable table);
5057

5158
KuduSession newSession();
5259

53-
KuduScanner deserializeIntoScanner(byte[] serializedScanToken) throws IOException;
60+
KuduScanner deserializeIntoScanner(byte[] serializedScanToken)
61+
throws IOException;
5462

5563
@Override
56-
void close() throws KuduException;
64+
void close()
65+
throws KuduException;
5766
}

0 commit comments

Comments
 (0)