jina icon indicating copy to clipboard operation
jina copied to clipboard

How to set GET method?

Open xuhaoguang opened this issue 1 year ago • 10 comments

image This is default POST method, But how can I set it's a GET method?

xuhaoguang avatar Oct 07 '23 07:10 xuhaoguang

Hey @xuhaoguang ,

You do not need to set it, Jina detects that there is a generator being returned and because of that exposes a GET endpoint when served via HTTP.

JoanFM avatar Oct 07 '23 08:10 JoanFM

ehh, But how can I use curl "localhost:12345/hc" to health_check method, but when I test, jina say I should send a json post data and Method Not Allowed

xuhaoguang avatar Oct 08 '23 00:10 xuhaoguang

image

xuhaoguang avatar Oct 08 '23 00:10 xuhaoguang

how are u defining this hc endpoint?

JoanFM avatar Oct 08 '23 03:10 JoanFM

image

xuhaoguang avatar Oct 08 '23 03:10 xuhaoguang

@xuhaoguang Did you find any workaround? I'm struggling with same.

that-rahul-guy avatar Nov 13 '23 05:11 that-rahul-guy

@that-rahul-guy what are you trying to do?

JoanFM avatar Nov 13 '23 07:11 JoanFM

Hi @JoanFM I am currently exploring jina as a framework to serve my LangChain Agent-tool architecture application. As for the GET method I was trying a similar thing what @xuhaoguang shared.

that-rahul-guy avatar Nov 15 '23 18:11 that-rahul-guy

Hey @xuhaoguang, which folder is that file in?

reshma045 avatar Dec 17 '23 15:12 reshma045

@jina-ai/product This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 14 days

jina-bot avatar Mar 17 '24 00:03 jina-bot

@jina-ai/product This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 14 days

jina-bot avatar Jun 16 '24 00:06 jina-bot