【发布时间】:2017-09-04 04:08:46
【问题描述】:
我有一个 phoenix 应用程序,它在生产中不断引发多个不同的异常。我正在尝试调查异常,但我不确定我的端点配置是否错误,这些错误是否存在于依赖项中?这些问题是否相关?哪个依赖项对它们负责?
我不想开票并在不同项目之间开始乒乓对话,所以我想先在这里问。
依赖关系
- 牛仔:1.0.4
- cowlib:1.0.2
- 牧场:1.2.1
- 凤凰:1.2
例外情况
1)
17:58:21.973 [error] Ranch protocol #PID<0.8216.13> (:cowboy_protocol) of listener Krihelinator.Endpoint.HTTP terminated
** (exit) an exception was raised:
** (FunctionClauseError) no function clause matching in :cowboy_protocol.parse_method/3
(cowboy) src/cowboy_protocol.erl:168: :cowboy_protocol.parse_method("", {:state, #Port<0.19168>, :ranch_tcp, [:cowboy_router, :cowboy_handler], true, [listener: Krihelinator.Endpoint.HTTP, dispatch: [{:_, [], [{["socket", "websocket"], [], Phoenix.Endpoint.CowboyWebSocket, {Phoenix.Transports.WebSocket, {Krihelinator.Endpoint, Krihelinator.UserSocket, :websocket}}}, {:_, [], Plug.Adapters.Cowboy.Handler, {Krihelinator.Endpoint, []}}]}]], :undefined, :undefined, 5, 1, 100, 4096, 64, 4096, 100, 5000, 1490810306970}, <<0, 0, 0, 113, 106, 129, 110, 48, 129, 107, 161, 3, 2, 1, 5, 162, 3, 2, 1, 10, 164, 129, 94, 48, 92, 160, 7, 3, 5, 0, 80, 128, 0, 16, 162, 4, 27, 2, 78, 77, 163, 23, 48, 21, 160, 3, 2, 1, 0, 161, ...>>)
2)
2017-04-06 06:21:14.693 [error] Ranch protocol #PID<0.21785.1> (:cowboy_protocol) of listener Krihelinator.Endpoint.HTTP terminated
** (exit) an exception was raised:
** (FunctionClauseError) no function clause matching in :cowboy_protocol.parse_uri_path/4
(cowboy) src/cowboy_protocol.erl:200: :cowboy_protocol.parse_uri_path("", {:state, #Port<0.6072>, :ranch_tcp, [:cowboy_router, :cowboy_handler], true, [listener: Krihelinator.Endpoint.HTTP, dispatch: [{:_, [], [{["socket", "websocket"], [], Phoenix.Endpoint.CowboyWebSocket, {Phoenix.Transports.WebSocket, {Krihelinator.Endpoint, Krihelinator.UserSocket, :websocket}}}, {:_, [], Plug.Adapters.Cowboy.Handler, {Krihelinator.Endpoint, []}}]}]], :undefined, :undefined, 5, 1, 100, 4096, 64, 4096, 100, 5000, 1491459679639}, <<71, 104, 48, 115, 116, 173, 0, 0, 0, 224, 0, 0, 0, 120, 156, 75, 83, 96, 96, 152, 195, 192, 192, 192, 6, 196, 140, 64, 188, 81, 150, 129, 129, 9, 72, 7, 167, 22, 149, 101, 38, 167, 42, 4, 36, 38, 103, 43, 24, 50, ...>>, <<2, 0, 84, 245, 43, 92>>)
3)
18:20:18.395 [error] Ranch protocol #PID<0.28926.18> (:cowboy_protocol) of listener Krihelinator.Endpoint.HTTP terminated
** (exit) an exception was raised:
** (FunctionClauseError) no function clause matching in :cow_http_hd.token_ci_list_sep/3
(cowlib) src/cow_http_hd.erl:191: :cow_http_hd.token_ci_list_sep("Te", [], "keep-alive")
(cowlib) src/cow_http_hd.erl:31: :cow_http_hd.parse_connection/1
(cowboy) src/cowboy_req.erl:189: :cowboy_req.new/14
(cowboy) src/cowboy_protocol.erl:410: :cowboy_protocol.request/9
如您所见,我不知道为什么会出现这些问题。所以也许我没有提供足够的信息。如果需要,请询问更多。 任何帮助我解决这些问题或打开正确项目票证的指导将不胜感激。
【问题讨论】: