Skip to content

[BUG] Getting DeadlineTimeoutException error during security tests after upgrading to 3.0 #583

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

Merged
merged 1 commit into from
Jan 5, 2023
Merged
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 @@ -111,13 +111,19 @@ abstract class PluginRestTestCase : OpenSearchRestTestCase() {
// create adminDN (super-admin) client
val uri = javaClass.classLoader.getResource("security/sample.pem").toURI()
val configPath = PathUtils.get(uri).parent.toAbsolutePath()
SecureRestClientBuilder(settings, configPath).setSocketTimeout(60000).build()
SecureRestClientBuilder(settings, configPath)
.setSocketTimeout(60000)
.setConnectionRequestTimeout(180000)
.build()
}
false -> {
// create client with passed user
val userName = System.getProperty("user")
val password = System.getProperty("password")
SecureRestClientBuilder(hosts, isHttps(), userName, password).setSocketTimeout(60000).build()
SecureRestClientBuilder(hosts, isHttps(), userName, password)
.setSocketTimeout(60000)
.setConnectionRequestTimeout(180000)
.build()
}
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,17 @@ class SecurityNotificationIT : PluginRestTestCase() {

@Before
fun create() {

if (userClient == null) {
createUser(user, user, arrayOf())
userClient = SecureRestClientBuilder(clusterHosts.toTypedArray(), isHttps(), user, user).setSocketTimeout(60000).build()
}
createUser(user, user, arrayOf())
userClient = SecureRestClientBuilder(clusterHosts.toTypedArray(), isHttps(), user, user)
.setSocketTimeout(60000)
.setConnectionRequestTimeout(180000)
.build()
}

@After
fun cleanup() {

userClient?.close()
userClient = null
}

fun `test Create slack notification config with user that has create Notification permission`() {
Expand Down