Skip to content

Commit 8682859

Browse files
authored
nit: fix RealmContextConfiguration.defaultRealm (apache#798)
1 parent 51a4537 commit 8682859

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

service/common/src/main/java/org/apache/polaris/service/context/RealmContextConfiguration.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
package org.apache.polaris.service.context;
2020

2121
import jakarta.validation.constraints.Size;
22-
import java.util.Set;
22+
import java.util.List;
2323

2424
public interface RealmContextConfiguration {
2525

@@ -28,13 +28,13 @@ public interface RealmContextConfiguration {
2828
* considered the default realm.
2929
*/
3030
@Size(min = 1)
31-
Set<String> realms();
31+
List<String> realms();
3232

3333
/** The header name that contains the realm identifier. */
3434
String headerName();
3535

3636
/** The default realm to use when no realm is specified. */
3737
default String defaultRealm() {
38-
return realms().iterator().next();
38+
return realms().getFirst();
3939
}
4040
}

0 commit comments

Comments
 (0)