> I think you should consider the full upgrade plan for > `conf/config.yaml` between differeent APISIX version, > not just add the version number.
This file should be managed by the user. This file is the foundation of Apache APISIX. I don't think we can help users upgrade the configuration file `conf / config.yaml`, sometimes we don't even know how to fix it. It is wrong, it may be because the user wrote it wrong, or it may be because the version is too old. It is enough to make the error message friendly. On Thu, Mar 12, 2020 at 2:56 PM Ming Wen <[email protected]> wrote: > > If we use the latest configuration file + APISIX 1.0 to work together, it > will fail to start. > yes, start fail is expected in this case. > > your option 1 and option 2 are aim to make error msg friendly? Or you want > to check valid before start APISIX? > For the former, I don't think it's necessary; > for the latter, I think you should consider the full upgrade plan for > `conf/config.yaml` between differeent APISIX version, > not just add the version number. > > Thanks, > Ming Wen, Apache APISIX & Apache SkyWalking > Twitter: _WenMing > > > YuanSheng Wang <[email protected]> 于2020年3月12日周四 下午12:13写道: > > > On Wed, Mar 11, 2020 at 8:37 PM Ming Wen <[email protected]> wrote: > > > > > > can you give some examples to explain the start fail? > > > > If we use the latest configuration file + APISIX 1.0 to work together, it > > will fail to start. > > > > Version 1.0 configuration file: > > > > apisix: > > ... ... > > real_ip_header: "X-Real-IP" > > > > > > *real_ip_from: - 127.0.0.1 - > > 'unix:'* > > > > Current latest configuration file: > > > > apisix: > > ... ... > > nginx_config: > > http: > > real_ip_header: "X-Real-IP" > > > > > > * real_ip_from: - 127.0.0.1 - > > 'unix:'* > > > > > > YuanSheng Wang <[email protected]>于2020年3月11日 周三下午8:16写道: > > > > > > > Hi: > > > > > > > > Apache APISIX users use a different version of `conf/config.yaml`, > > > > this caused the service to fail to start. > > > > > > > > The update of Apache APISIX may cause the file `conf / config.yaml` > to > > > > be incompatible. > > > > > > > > There are two ways to resolve this bug: > > > > 1 Uses a version field in the file `conf/config.yaml`, the Apache > > > > APISIX can only work with the specified version config file. > > > > 2 Uses `jsonschema`[1] to check the configuration and identify such > > > > errors early. > > > > > > > > [1] https://github.com/api7/jsonschema > > > > > > > > -- > > > > MembPhis > > > > My github: https://github.com/membphis > > > > Apache APISIX: https://github.com/apache/incubator-apisix > > > > > > > -- > > > Thanks, > > > Ming Wen, Apache APISIX & Apache SkyWalking > > > Twitter: _WenMing > > > > > > > > -- > > MembPhis > > My github: https://github.com/membphis > > Apache APISIX: https://github.com/apache/incubator-apisix > > > -- *MembPhis* My github: https://github.com/membphis Apache APISIX: https://github.com/apache/incubator-apisix
