fix iot_app
This commit is contained in:
parent
298e615794
commit
cc10502a58
@ -13,21 +13,18 @@
|
||||
|
||||
start(_StartType, _StartArgs) ->
|
||||
io:setopts([{encoding, unicode}]),
|
||||
%% 启动数据库
|
||||
start_mnesia(),
|
||||
%% 导入固定数据到mnesia
|
||||
|
||||
%% 加速内存的回收
|
||||
erlang:system_flag(fullsweep_after, 16),
|
||||
|
||||
{ok, SupPid} = iot_sup:start_link(),
|
||||
%% 启动数据库
|
||||
start_mnesia(),
|
||||
%% 启动udp服务
|
||||
start_udp_server(),
|
||||
%% 启动http服务
|
||||
start_http_server(),
|
||||
|
||||
%% 启动连接池
|
||||
ok = hackney_pool:start_pool(influx_pool, [{timeout, 150000}, {max_connections, 100}]),
|
||||
|
||||
iot_sup:start_link().
|
||||
{ok, SupPid}.
|
||||
|
||||
stop(_State) ->
|
||||
ok.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user