Hi!
We’re in the middle of testing out the Teneo Inquire client and are having some issues when trying to test the timeout setting. Could you please help us out?
Max
Hi!
We’re in the middle of testing out the Teneo Inquire client and are having some issues when trying to test the timeout setting. Could you please help us out?
Max
Hi MaxM! Welcome to the forum!
This Scala code might be helpful as a reference point,
package playground
import com.artisol.teneo.inquire.clientapi.QueryClient
import java.util
object scalaPlayground extends App {
val backendUrl: String = "INQUIRE_URL"
var clientParameters: util.HashMap[String, Object] = new util.HashMap[String, Object]()
clientParameters.put("timeout", 100.asInstanceOf[AnyRef])
clientParameters.put("esPageSize", 50.asInstanceOf[AnyRef])
val clientApi: QueryClient = QueryClient.create(backendUrl)
val user: String = "awesome.user@artificial-solutions.com"
val pass: String = "secretsauce"
clientApi.login(user, pass)
val lds: String = "PUBLISHED_ENV"
val tql: String = "la t.id, t.e1.userInput as userInput"
val result = clientApi.executeQuery(lds, tql, clientParameters)
print(result)
}
For groovy this might be helpful,
The tql client needs to have the timeout parameter on the submit query call.
client.submitQuery(lds, tql, ['timeout': 10000])
(Otherwise the timeout will be defaulted to 60 s.)
Warm regards,
Ramazan