Http_pollar input is not working with the certificate

Hi We are using http_poller to query elastic in logstash input with the selfsigned certificate. but not receieving any result and not prompting any error in the logstash. tls is enabled at elastic. when i run the same query in devtools it is returning the result set.

can you please suggest what could be the isssue.

below is the code snippet in logstash input.

input {
http_poller {
urls => {
sessionCreate => {
method => "GET"
url => "${inputurl}"
user => "${user}"
password => "${password}"
verify_cert => true
truststore => "/etc/dl/logstash/certs/rootca.jks"
headers => {
Accept => "application/json"
"Content-Type" => "application/json"
}
body => '{
"size": 0,
"aggs": {
"distinct_AgentID": {
"terms": {
"field": "AgentID",
"size": 1000
}
}
},
"_source": {
"includes": [
"AgentID"
]
},
"query": {"bool": {
"must":
{
"range":{
"StartDateTime" : {
"gt": "now-24h"
}
}
}

}}
}'
}
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.