compatible with lua-resty-upstream api