You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apisix.apache.org by junxu chen <ch...@apache.org> on 2020/06/04 01:07:36 UTC

The 'config.yaml' update issue when reuseport is enabled

We recently encountered a bug:
when reuseport is enabled by default, during the running of APISIX, modify
`config.yaml` and start without stopping APISIX. This resulted in some
workers still using the old config, some workers using the new config, and
the old workers could not be killed by `apisix stop`


I think we need to fix it by:

1. When running `apisix start`, Check if APISIX has been running. If is
running, remind to use `apisix reload`

2. `apisix reload` needs to regenerate nginx.conf according to config.yaml
and then reload

what do you think?

Re: The 'config.yaml' update issue when reuseport is enabled

Posted by jinwei <gx...@163.com>.
+1


On 06/04/2020 09:07, junxu chen wrote:
We recently encountered a bug:
when reuseport is enabled by default, during the running of APISIX, modify
`config.yaml` and start without stopping APISIX. This resulted in some
workers still using the old config, some workers using the new config, and
the old workers could not be killed by `apisix stop`


I think we need to fix it by:

1. When running `apisix start`, Check if APISIX has been running. If is
running, remind to use `apisix reload`

2. `apisix reload` needs to regenerate nginx.conf according to config.yaml
and then reload

what do you think?

Re: The 'config.yaml' update issue when reuseport is enabled

Posted by YuanSheng Wang <me...@apache.org>.
On Thu, Jun 4, 2020 at 10:35 AM Lang Wang <to...@apache.org> wrote:

> We may need to check nginx syntax before running apisix reload
>

agree this too. we can create a new issue about this.



>
> 在 2020年6月4日星期四,Ming Wen <we...@apache.org> 写道:
>
> > agreed
> >
> > Thanks,
> > Ming Wen, Apache APISIX & Apache SkyWalking
> > Twitter: _WenMing
> >
> >
> > junxu chen <ch...@apache.org> 于2020年6月4日周四 上午9:07写道:
> >
> > > We recently encountered a bug:
> > > when reuseport is enabled by default, during the running of APISIX,
> > modify
> > > `config.yaml` and start without stopping APISIX. This resulted in some
> > > workers still using the old config, some workers using the new config,
> > and
> > > the old workers could not be killed by `apisix stop`
> > >
> > >
> > > I think we need to fix it by:
> > >
> > > 1. When running `apisix start`, Check if APISIX has been running. If is
> > > running, remind to use `apisix reload`
> > >
> > > 2. `apisix reload` needs to regenerate nginx.conf according to
> > config.yaml
> > > and then reload
> > >
> > > what do you think?
> > >
> >
>


-- 
*MembPhis*
My github: https://github.com/membphis
Apache APISIX: https://github.com/apache/incubator-apisix

Re: The 'config.yaml' update issue when reuseport is enabled

Posted by Lang Wang <to...@apache.org>.
We may need to check nginx syntax before running apisix reload

在 2020年6月4日星期四,Ming Wen <we...@apache.org> 写道:

> agreed
>
> Thanks,
> Ming Wen, Apache APISIX & Apache SkyWalking
> Twitter: _WenMing
>
>
> junxu chen <ch...@apache.org> 于2020年6月4日周四 上午9:07写道:
>
> > We recently encountered a bug:
> > when reuseport is enabled by default, during the running of APISIX,
> modify
> > `config.yaml` and start without stopping APISIX. This resulted in some
> > workers still using the old config, some workers using the new config,
> and
> > the old workers could not be killed by `apisix stop`
> >
> >
> > I think we need to fix it by:
> >
> > 1. When running `apisix start`, Check if APISIX has been running. If is
> > running, remind to use `apisix reload`
> >
> > 2. `apisix reload` needs to regenerate nginx.conf according to
> config.yaml
> > and then reload
> >
> > what do you think?
> >
>

Re: The 'config.yaml' update issue when reuseport is enabled

Posted by Ming Wen <we...@apache.org>.
agreed

Thanks,
Ming Wen, Apache APISIX & Apache SkyWalking
Twitter: _WenMing


junxu chen <ch...@apache.org> 于2020年6月4日周四 上午9:07写道:

> We recently encountered a bug:
> when reuseport is enabled by default, during the running of APISIX, modify
> `config.yaml` and start without stopping APISIX. This resulted in some
> workers still using the old config, some workers using the new config, and
> the old workers could not be killed by `apisix stop`
>
>
> I think we need to fix it by:
>
> 1. When running `apisix start`, Check if APISIX has been running. If is
> running, remind to use `apisix reload`
>
> 2. `apisix reload` needs to regenerate nginx.conf according to config.yaml
> and then reload
>
> what do you think?
>