feat: refactor apis for existing check and other apis#535
Conversation
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ |
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| // Copyright 2017 The Kubernetes Authors. |
There was a problem hiding this comment.
are these headers must to be kept ?
There was a problem hiding this comment.
Is this file from Kubernetes repo?
There was a problem hiding this comment.
some code copy from Kubernetes dashboard , so i think it's better to keep their license. what do you think ? @moonming
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| // Copyright 2017 The Kubernetes Authors. |
There was a problem hiding this comment.
Is this file from Kubernetes repo?
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| // Copyright 2017 The Kubernetes Authors. |
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| // Copyright 2017 The Kubernetes Authors. |
|
This method is not right. What is the license of the original code?
nic-chen <[email protected]>于2020年10月5日 周一下午9:31写道:
***@***.**** commented on this pull request.
------------------------------
In api/internal/core/store/query.go
<#535 (comment)>
:
> + * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+// Copyright 2017 The Kubernetes Authors.
some code copy from Kubernetes dashboard , so i think it's better to keep
their license. what do you think ? @moonming <https://github.com/moonming>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#535 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGJZBKYXWZRPE5RE5STNBV3SJHDBRANCNFSM4SDXIAEQ>
.
--
Thanks,
Ming Wen
Twitter: _WenMing
|
the Apache License, Version 2.0 |
|
Please add codecov |
|
we can leave the lincense issues when merge to master. @nic-chen |
|
@nic-chen what's the code coverage? |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ |
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| // Copyright 2017 The Kubernetes Authors. |
| r.PATCH("/apisix/admin/ssl/:id", wgin.Wraps(h.Patch, | ||
| wrapper.InputType(reflect.TypeOf(UpdateInput{})))) | ||
| r.DELETE("/apisix/admin/ssl", wgin.Wraps(h.BatchDelete, | ||
| r.DELETE("/apisix/admin/ssl/:ids", wgin.Wraps(h.BatchDelete, |
There was a problem hiding this comment.
why we use ids here? I think it should be id, the singular should be used here.
you could see in my repo: main code of refactoring: the handlers using api test, so it couldn't calculate coverage correctly. |
|
@membphis we leave the license issues and fix it later. |
|
I will merge this pr. |
please create issues for them |
ok |
|
Please link this PR in those issues :D |
OK |
* feat: refactor some codes and append store core * refference droplet and write a API demo * fmt project * feat: add validator for generic store; add demo error * feat: upgrade droplet * chore: add structures (#484) * add upstream struct * fix structures * feat: append stock check for generic store * feat: add consumer CURD refactoring (#486) * feat: add consumer CURD refactoring * remove debug * remove useless slashes * feat: add SSL refactoring (#488) Co-authored-by: Vinci Xu <[email protected]> * feat: add Service and Upstream refactoring (#497) * feat: add Service and Upstream refactoring * fix add license * feat: add store hub and flake id (#534) * feat: add store hub and flake id * feat: add store interface to easy est * fix: add test cases for refactored apis and fix bugs (#528) * test: delete mysql version test cases. * fix: add ssl test cases and bug fix * fix: list api should return an empty array not a null for client * test: consumer test cases * fix: code style * test: init etcd in github action * fix: skip checking generated file's license * feat: add store hub and flake id (#534) * feat: add store hub and flake id * feat: add store interface to easy est * fix CI failed Co-authored-by: Vinci Xu <[email protected]> * feat: refactor apis for existing check and other apis (#535) * fix code style * fix code style * feat support query * feat: support query * change: `like` to `equal` * fix api status * feat: upstream existing check * feat: refactor api for upstream names * fix: license * test: add unit test cases * fix: update bug * test: add test cases for route * fix: unified respond format * test: remove test bug * feat: ssl existing check * fix bug: auto generate id * fix: improve consumer * fix: remove key and keys in ssl respond * fix: when list is empty, should respond an empty array * fix code style * feat: plugin orchestration * fix delete bug * fix bug * fix: keep the same request params and respond with the old format * fix: append sort for list and using sync.Map instead of map * feature: sync json schema from APISIX and check schema when create or update resource (#551) * feat: json schema check * fix: don't need to define struct for each resource, because that may cause json schema check fail. * test: add handler test cases * test: complete consumer test cases * test: add test cases for schema check * fix code style and license * feat: add schema check for plugins * test: add ssl handler test cases * test: add test cases for upstream and service * test: add test cases for route * test: add note for route create * test: update CI * fix: remove useless file * test: fix CI * fix: ci fail * test: fix lib `dag-to-lua`'s path in CI * fix: URI for route may be empty * fix: remove empty lines * fix: refactor validator of json schema * fix code style * fix cicd * chore: update docker file * fix: should check schema after id generated * fix code style * chore: page_number -> page * fix: schema sync script * fix: code style * feat: support search for resource list (#557) * feat: support search for resource list * fix ci * feature: refactor plugin api and auth api (#556) * feat: refactor plugin and healthy api * feat: refactor authentication api * fix: remove useless files * chore: update json schema * test: add login test * test: add test for plugin * fix: license * fix auth bug * fix route search by uri * feat: compatible with PUT method of `admin api` and nodes of upstream (#561) * feat: support labels * feat: compatible with PUT method of `admin api` * fix mock test fail * feat: upstream nodes format * test: add test case * fix code style * fix: update schema sync tool * feat: compatible with HTTP status of `admin api` (#563) * feat: compatible with HTTP status of `admin api` * test cases and improve * fix: check input.ID before using it * fix: remove CI branch * fix: remove useless dependences * add license for json.lua * fix license issue * remove * fix: remove viper that depend github.com/hashicorp/hcl * fix license issue * fix: skip license check temporarily for CI Co-authored-by: vincixu <[email protected]> Co-authored-by: ShiningRush <[email protected]> Co-authored-by: WenMing <[email protected]>
Please answer these questions before submitting a pull request
New feature or improvement
feat: refactor apis for existing check and other apis
such as:
/apisix/admin/notexist/upstreams/apisix/admin/names/upstreams/apisix/admin/notexist/routes/apisix/admin/check_ssl_certand so on.