You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shenyu.apache.org by GitBox <gi...@apache.org> on 2022/10/12 08:58:17 UTC

[GitHub] [shenyu] 847850277 opened a new pull request, #4073: [ISSUE #4029] api and api_rule_relation mapper

847850277 opened a new pull request, #4073:
URL: https://github.com/apache/shenyu/pull/4073

   <!-- Describe your PR here; eg. Fixes #issueNo -->
   
   <!--
   Thank you for proposing a pull request. This template will guide you through the essential steps necessary for a pull request.
   -->
   Make sure that:
   
   - [ ] You have read the [contribution guidelines](https://shenyu.apache.org/community/contributor-guide).
   - [ ] You submit test cases (unit or integration tests) that back your changes.
   - [ ] Your local test passed `./mvnw clean install -Dmaven.javadoc.skip=true`.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] codecov-commenter commented on pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#issuecomment-1276953017

   # [Codecov](https://codecov.io/gh/apache/shenyu/pull/4073?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#4073](https://codecov.io/gh/apache/shenyu/pull/4073?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (d8657a9) into [master](https://codecov.io/gh/apache/shenyu/commit/6a4f4e7bc2b9b113217606bb76c93248649a949f?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (6a4f4e7) will **decrease** coverage by `0.22%`.
   > The diff coverage is `100.00%`.
   
   ```diff
   @@             Coverage Diff              @@
   ##             master    #4073      +/-   ##
   ============================================
   - Coverage     69.92%   69.70%   -0.23%     
   - Complexity     6763     6769       +6     
   ============================================
     Files           937      939       +2     
     Lines         25533    25601      +68     
     Branches       2299     2297       -2     
   ============================================
   - Hits          17855    17846       -9     
   - Misses         6273     6343      +70     
   - Partials       1405     1412       +7     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/shenyu/pull/4073?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...va/org/apache/shenyu/admin/model/entity/ApiDO.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWFkbWluL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvYWRtaW4vbW9kZWwvZW50aXR5L0FwaURPLmphdmE=) | `100.00% <100.00%> (ø)` | |
   | [...e/shenyu/admin/model/entity/ApiRuleRelationDO.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWFkbWluL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvYWRtaW4vbW9kZWwvZW50aXR5L0FwaVJ1bGVSZWxhdGlvbkRPLmphdmE=) | `100.00% <100.00%> (ø)` | |
   | [...ache/shenyu/plugin/grpc/cache/GrpcClientCache.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LXBsdWdpbi9zaGVueXUtcGx1Z2luLWdycGMvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoZW55dS9wbHVnaW4vZ3JwYy9jYWNoZS9HcnBjQ2xpZW50Q2FjaGUuamF2YQ==) | `68.75% <0.00%> (-31.25%)` | :arrow_down: |
   | [.../client/server/consul/ShenyuConsulConfigWatch.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LXJlZ2lzdGVyLWNlbnRlci9zaGVueXUtcmVnaXN0ZXItY2xpZW50LXNlcnZlci9zaGVueXUtcmVnaXN0ZXItY2xpZW50LXNlcnZlci1jb25zdWwvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoZW55dS9yZWdpc3Rlci9jbGllbnQvc2VydmVyL2NvbnN1bC9TaGVueXVDb25zdWxDb25maWdXYXRjaC5qYXZh) | `60.41% <0.00%> (-25.00%)` | :arrow_down: |
   | [...controller/ShenyuClientHttpRegistryController.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWFkbWluL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvYWRtaW4vY29udHJvbGxlci9TaGVueXVDbGllbnRIdHRwUmVnaXN0cnlDb250cm9sbGVyLmphdmE=) | `77.77% <0.00%> (-22.23%)` | :arrow_down: |
   | [...yu/sync/data/http/refresh/AbstractDataRefresh.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LXN5bmMtZGF0YS1jZW50ZXIvc2hlbnl1LXN5bmMtZGF0YS1odHRwL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvc3luYy9kYXRhL2h0dHAvcmVmcmVzaC9BYnN0cmFjdERhdGFSZWZyZXNoLmphdmE=) | `68.96% <0.00%> (-13.80%)` | :arrow_down: |
   | [...ruptor/RegisterClientServerDisruptorPublisher.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWFkbWluL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvYWRtaW4vZGlzcnVwdG9yL1JlZ2lzdGVyQ2xpZW50U2VydmVyRGlzcnVwdG9yUHVibGlzaGVyLmphdmE=) | `52.94% <0.00%> (-11.77%)` | :arrow_down: |
   | [...a/org/apache/shenyu/common/utils/VersionUtils.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWNvbW1vbi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hlbnl1L2NvbW1vbi91dGlscy9WZXJzaW9uVXRpbHMuamF2YQ==) | `67.85% <0.00%> (-10.72%)` | :arrow_down: |
   | [...he/shenyu/loadbalancer/spi/RandomLoadBalancer.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LWxvYWRiYWxhbmNlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hlbnl1L2xvYWRiYWxhbmNlci9zcGkvUmFuZG9tTG9hZEJhbGFuY2VyLmphdmE=) | `81.81% <0.00%> (-9.10%)` | :arrow_down: |
   | [...che/shenyu/sync/data/http/HttpSyncDataService.java](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hlbnl1LXN5bmMtZGF0YS1jZW50ZXIvc2hlbnl1LXN5bmMtZGF0YS1odHRwL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGVueXUvc3luYy9kYXRhL2h0dHAvSHR0cFN5bmNEYXRhU2VydmljZS5qYXZh) | `81.63% <0.00%> (-8.17%)` | :arrow_down: |
   | ... and [33 more](https://codecov.io/gh/apache/shenyu/pull/4073/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
   
   :mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] 847850277 commented on pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
847850277 commented on PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#issuecomment-1278742526

   > format ddl
   
   fixed it


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] 847850277 commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
847850277 commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r994078106


##########
db/init/mysql/schema.sql:
##########
@@ -39,6 +39,52 @@ CREATE TABLE `alert_template`  (
 -- Records of alert_template
 -- ----------------------------
 
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS `api`;
+CREATE TABLE `api` (
+                       `id` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'primary key id',
+                       `context_path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the context_path',
+                       `path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the path',
+                       `http_method` int(0) NOT NULL COMMENT '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace',
+                       `consume` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'consume',
+                       `produce` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'produce',
+                       `version` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'api version,for example V0.01',
+                       `rpc_type` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc',
+                       `status` tinyint(4) NOT NULL COMMENT '0-unpublished1-published2-offline',
+                       `ext` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'extended fields',
+                       `owner` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'owner',
+                       `api_desc` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the api description',
+                       `document` text COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'complete documentation of the api, including request parameters and response parameters',
+                       `document_md5` char(32) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'document_md5',
+                       `source` int(0) NOT NULL COMMENT '0-swagger,1-annotation generation,2-create manuallym,3-import swagger,4-import yapi',

Review Comment:
   fix it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] 847850277 commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
847850277 commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r994078106


##########
db/init/mysql/schema.sql:
##########
@@ -39,6 +39,52 @@ CREATE TABLE `alert_template`  (
 -- Records of alert_template
 -- ----------------------------
 
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS `api`;
+CREATE TABLE `api` (
+                       `id` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'primary key id',
+                       `context_path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the context_path',
+                       `path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the path',
+                       `http_method` int(0) NOT NULL COMMENT '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace',
+                       `consume` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'consume',
+                       `produce` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'produce',
+                       `version` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'api version,for example V0.01',
+                       `rpc_type` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc',
+                       `status` tinyint(4) NOT NULL COMMENT '0-unpublished1-published2-offline',
+                       `ext` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'extended fields',
+                       `owner` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'owner',
+                       `api_desc` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the api description',
+                       `document` text COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'complete documentation of the api, including request parameters and response parameters',
+                       `document_md5` char(32) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'document_md5',
+                       `source` int(0) NOT NULL COMMENT '0-swagger,1-annotation generation,2-create manuallym,3-import swagger,4-import yapi',

Review Comment:
   fixed it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] dragon-zhang commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
dragon-zhang commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r994595786


##########
db/init/mysql/schema.sql:
##########
@@ -39,6 +39,52 @@ CREATE TABLE `alert_template`  (
 -- Records of alert_template
 -- ----------------------------
 
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS `api`;
+CREATE TABLE `api` (
+                       `id` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'primary key id',
+                       `context_path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the context_path',
+                       `path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the path',
+                       `http_method` int(0) NOT NULL COMMENT '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace',
+                       `consume` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'consume',
+                       `produce` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'produce',
+                       `version` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'api version,for example V0.01',
+                       `rpc_type` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc',
+                       `status` tinyint(4) NOT NULL COMMENT '0-unpublished1-published2-offline',

Review Comment:
   please change `status` to `state`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] dragon-zhang merged pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
dragon-zhang merged PR #4073:
URL: https://github.com/apache/shenyu/pull/4073


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] dragon-zhang commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
dragon-zhang commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r995789641


##########
db/init/pg/create-table.sql:
##########
@@ -47,6 +47,70 @@ MAXVALUE 9223372036854775807
 START 1
 CACHE 1;
 
+
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS "public"."api";
+CREATE TABLE "public"."api"
+(
+    "id"           varchar(128) COLLATE "pg_catalog"."default" NOT NULL,
+    "context_path" varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "api_path"     varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "http_method" int4 NOT NULL,
+    "consume"      varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "produce"      varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "version"      varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "rpc_type"     varchar(64) COLLATE "pg_catalog"."default"  NOT NULL,
+    "state" int2 NOT NULL,
+    "ext"          varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "api_owner"    varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "api_desc"     varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "api_source" int4 NOT NULL,
+    "document"     text COLLATE "pg_catalog"."default"         NOT NULL,
+    "document_md5" varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
+    "date_created" timestamp(6)                                NOT NULL DEFAULT timezone('UTC-8'::text, (now()):: timestamp (0) without time zone),
+    "date_updated" timestamp(6)                                NOT NULL DEFAULT timezone('UTC-8'::text, (now()):: timestamp (0) without time zone)
+)
+;
+COMMENT ON COLUMN "public"."api"."id" IS 'primary key id';
+COMMENT ON COLUMN "public"."api"."context_path" IS 'the context_path';
+COMMENT ON COLUMN "public"."api"."api_path" IS 'the api_path';
+COMMENT ON COLUMN "public"."api"."http_method" IS '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace';
+COMMENT ON COLUMN "public"."api"."consume" IS 'consume';
+COMMENT ON COLUMN "public"."api"."produce" IS 'produce';
+COMMENT ON COLUMN "public"."api"."version" IS 'api version,for example V0.01';
+COMMENT ON COLUMN "public"."api"."rpc_type" IS 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc';
+COMMENT ON COLUMN "public"."api"."state" IS '0-unpublished1-published2-offline';
+COMMENT ON COLUMN "public"."api"."ext" IS 'extended fields';
+COMMENT ON COLUMN "public"."api"."api_owner" IS 'api_owner';
+COMMENT ON COLUMN "public"."api"."api_desc" IS 'the api description';
+COMMENT ON COLUMN "public"."api"."api_source" IS '0-swagger,1-annotation generation,2-create manuallym,3-import swagger,4-import yapi';
+COMMENT ON COLUMN "public"."api"."document" IS 'complete documentation of the api, including request parameters and response parameters';
+COMMENT ON COLUMN "public"."api"."document_md5" IS 'document_md5';
+COMMENT ON COLUMN "public"."api"."date_created" IS 'create time';
+COMMENT ON COLUMN "public"."api"."date_updated" IS 'update time';
+
+
+
+-- ----------------------------
+-- Table structure for api_rule_relation
+-- ----------------------------
+DROP TABLE IF EXISTS "public"."api_rule_relation";
+CREATE TABLE "public"."api_rule_relation" (
+                                "id"           varchar(128) COLLATE "pg_catalog"."default" NOT NULL,
+                                "api_id"       varchar(128) COLLATE "pg_catalog"."default" NOT NULL,
+                                "rule_id"      varchar(128) COLLATE "pg_catalog"."default" NOT NULL,
+                                "date_created" timestamp(6) NOT NULL DEFAULT timezone('UTC-8'::text, (now())::timestamp(0) without time zone),
+                                "date_updated" timestamp(6) NOT NULL DEFAULT timezone('UTC-8'::text, (now())::timestamp(0) without time zone)

Review Comment:
   needs format here.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] 847850277 commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
847850277 commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r995554991


##########
db/init/mysql/schema.sql:
##########
@@ -39,6 +39,52 @@ CREATE TABLE `alert_template`  (
 -- Records of alert_template
 -- ----------------------------
 
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS `api`;
+CREATE TABLE `api` (
+                       `id` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'primary key id',
+                       `context_path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the context_path',
+                       `path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the path',
+                       `http_method` int(0) NOT NULL COMMENT '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace',
+                       `consume` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'consume',
+                       `produce` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'produce',
+                       `version` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'api version,for example V0.01',
+                       `rpc_type` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc',
+                       `status` tinyint(4) NOT NULL COMMENT '0-unpublished1-published2-offline',

Review Comment:
   fixed it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] dragon-zhang commented on a diff in pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
dragon-zhang commented on code in PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#discussion_r993663709


##########
db/init/mysql/schema.sql:
##########
@@ -39,6 +39,52 @@ CREATE TABLE `alert_template`  (
 -- Records of alert_template
 -- ----------------------------
 
+-- ----------------------------
+-- Table structure for api
+-- ----------------------------
+DROP TABLE IF EXISTS `api`;
+CREATE TABLE `api` (
+                       `id` varchar(128) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'primary key id',
+                       `context_path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the context_path',
+                       `path` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the path',
+                       `http_method` int(0) NOT NULL COMMENT '0-get,1-head,2-post,3-put,4-patch,5-delete,6-options,7-trace',
+                       `consume` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'consume',
+                       `produce` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'produce',
+                       `version` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'api version,for example V0.01',
+                       `rpc_type` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'http,dubbo,sofa,tars,websocket,springCloud,motan,grpc',
+                       `status` tinyint(4) NOT NULL COMMENT '0-unpublished1-published2-offline',
+                       `ext` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'extended fields',
+                       `owner` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'owner',
+                       `api_desc` varchar(1024) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'the api description',
+                       `document` text COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'complete documentation of the api, including request parameters and response parameters',
+                       `document_md5` char(32) COLLATE utf8mb4_unicode_ci NOT NULL COMMENT 'document_md5',
+                       `source` int(0) NOT NULL COMMENT '0-swagger,1-annotation generation,2-create manuallym,3-import swagger,4-import yapi',

Review Comment:
   `source` is a keyword, change it to `api_source`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shenyu] li-keguo commented on pull request #4073: [ISSUE #4029] api and api_rule_relation mapper

Posted by GitBox <gi...@apache.org>.
li-keguo commented on PR #4073:
URL: https://github.com/apache/shenyu/pull/4073#issuecomment-1277592205

   format ddl


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org