client.create fails with 'No handler found for uri'
See original GitHub issueI’m currently on the latest api version and i’m trying to use create but it fails and returns this error.
Error: Bad Request
status: 400,
displayName: 'BadRequest',
message: 'Bad Request',
path: '/assets/asset/-KnD8KqWH-c2HpzL9lDM/_create',
query: {},
body: '{"name":"Hjjhs","timestamp":1498107174785,"teamId":"ID-GOES-HERE"}',
statusCode: 400,
response: 'No handler found for uri [//assets/asset/-KnD8KqWH-c2HpzL9lDM/_create] and method [POST]',
toString: [Function],
toJSON: [Function]
Would it have anything to do with the double //
in the returned path for the handler? I can submit new entries using a basic HTTP request with node but using this client always fails.
client.create({
index: 'assets',
type: 'asset',
id: id,
body: _.pick(data, elasticsearchFields),
}, function (error, response) {
if (error) {
console.log(error)
} else {
console.log(response)
}
});
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
No handler found for uri [/<index>/<type>/] and method [PUT]
The problem here is the way POST and PUT works, when you use POST , _id is optional, ES will generate a unique...
Read more >Solved: {"error":"no handler found for uri [/metadata/item...
Solved: Hello everyone, When setting up Geoportal 2.6.5 with ElasticSearch 8.1.3 on a Windows 10 VM, I followed the installation steps ...
Read more >Inconsistent API Response "error: no handler found for uri"
Hey, doing API POST Requests via Python (on MacOS) I did: elastic_client.update(index='.internal.alerts-security.alerts-default-000001' ...
Read more >Icinga2 | Elasticsearch Writer showing error "No Handler Found"
Hi Everyone, As per my use case, I am trying to writer my performance data from icinga2 into the Elasticsearch.
Read more >Loading streaming data from Dynamodb into ElasticSearch
I am facing following errors when triggering lambda for test event. {"error":"no handler found for uri [//lambda-index/_doc/CUSTOMER] and method [PUT]"} { ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I had same issue, it was because when I defined the elastic search URL I put ‘/’ at the end like this http://host/elasticsearch/ removing ‘/’ from the end solved this issue.
remove the slash at the end of http://host/elasticsearch/, solve the issue.