我想在我的Phoenix App中使用这个库连接到Memcache:https://github.com/tsharju/memcache_client
当我运行我的服务器时,我收到此错误:
** (exit) exited in: :gen_server.call(Memcache.Client.Pool, {:checkout, #Reference<0.0.1.768>, true}, 5000)
** (EXIT) no process: the process is not alive or there's no process currently associated with the given name, possibly because its application isn't started
:erlang.send(Memcache.Client.Pool, {:"$gen_cast", {:cancel_waiting, #Reference<0.0.1.768>}}, [:noconnect])
我知道有一位医生说:
另外,请记住将:memcache_client添加到:applications列表中 您希望应用程序自动启动。
但我不明白我应该在凤凰应用中做些什么。有帮助吗?谢谢!
答案 0 :(得分:3)
在buildAngular
中,将mix.exs
添加到函数:memcache_client
中的密钥:applications
:
application/0
- &GT;
def application do
[mod: {MyApp, []},
applications: [:phoenix, :phoenix_pubsub, :phoenix_html, :cowboy, :logger, :gettext,
:phoenix_ecto, :postgrex]]
end
答案 1 :(得分:0)
解决了它。只需编辑mix.exs文件即可。有一个返回应用程序列表的方法应用程序:
--jar
端