diff --git a/aspnet-core/database/ApiGateway-Init.sql b/aspnet-core/database/ApiGateway-Init.sql index d44a5ec71..ce756354f 100644 --- a/aspnet-core/database/ApiGateway-Init.sql +++ b/aspnet-core/database/ApiGateway-Init.sql @@ -11,7 +11,7 @@ Target Server Version : 80020 File Encoding : 65001 - Date: 30/07/2020 16:54:44 + Date: 05/08/2020 15:56:55 */ SET NAMES utf8mb4; @@ -159,26 +159,6 @@ INSERT INTO `appapigatewayauthoptions` VALUES (67, 1267383367629807616, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (68, 1267817055527632896, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (69, 1267817221286526976, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (70, 1268893687085518848, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (71, 1273527659565547520, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (72, 1273542336509079552, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (73, 1273542755520049152, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (74, 1273543111322857472, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (75, 1273543850526994432, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (76, 1273544135009857536, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (77, 1273544377432240128, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (78, 1273544549834911744, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (79, 1273545100509278208, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (80, 1273545462146363392, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (81, 1273545765801390080, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (82, 1273877904709361664, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (83, 1273878097483767808, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (84, 1273878425839050752, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (85, 1273879014778052608, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (86, 1273879265417076736, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (87, 1273879533101752320, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (88, 1274294160109314048, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (89, 1274524600855441408, '', ''); -INSERT INTO `appapigatewayauthoptions` VALUES (90, 1274543888438525952, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (91, 1285579388652576768, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (92, 1285580096881778688, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (93, 1285582774663864320, '', ''); @@ -189,6 +169,10 @@ INSERT INTO `appapigatewayauthoptions` VALUES (97, 1288658305156964352, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (98, 1288658491216289792, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (99, 1288658638302142464, '', ''); INSERT INTO `appapigatewayauthoptions` VALUES (100, 1288658791784308736, '', ''); +INSERT INTO `appapigatewayauthoptions` VALUES (101, 1290849478956199936, '', ''); +INSERT INTO `appapigatewayauthoptions` VALUES (102, 1290849628051124224, '', ''); +INSERT INTO `appapigatewayauthoptions` VALUES (103, 1290849798553776128, '', ''); +INSERT INTO `appapigatewayauthoptions` VALUES (104, 1290849978032238592, '', ''); -- ---------------------------- -- Table structure for appapigatewaybalanceroptions @@ -272,33 +256,11 @@ INSERT INTO `appapigatewaybalanceroptions` VALUES (63, NULL, 1263305430536855552 INSERT INTO `appapigatewaybalanceroptions` VALUES (64, NULL, 1263639172959174656, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (65, NULL, 1264799968944640000, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (66, NULL, 1264800070161584128, '', '', 0); -INSERT INTO `appapigatewaybalanceroptions` VALUES (67, 1265168245423443968, NULL, 'LeastConnection', '', 60000); INSERT INTO `appapigatewaybalanceroptions` VALUES (68, NULL, 1267360794414161920, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (69, NULL, 1267383367629807616, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (70, NULL, 1267817055527632896, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (71, NULL, 1267817221286526976, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (72, NULL, 1268893687085518848, '', '', 0); -INSERT INTO `appapigatewaybalanceroptions` VALUES (73, 1273519675519270912, NULL, 'RoundRobin', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (74, NULL, 1273527659565547520, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (75, NULL, 1273542336509079552, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (76, NULL, 1273542755520049152, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (77, NULL, 1273543111322857472, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (78, NULL, 1273543850526994432, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (79, NULL, 1273544135009857536, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (80, NULL, 1273544377432240128, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (81, NULL, 1273544549834911744, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (82, NULL, 1273545100509278208, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (83, NULL, 1273545462146363392, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (84, NULL, 1273545765801390080, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (85, NULL, 1273877904709361664, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (86, NULL, 1273878097483767808, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (87, NULL, 1273878425839050752, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (88, NULL, 1273879014778052608, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (89, NULL, 1273879265417076736, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (90, NULL, 1273879533101752320, 'LeastConnection', '', 6000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (91, NULL, 1274294160109314048, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (92, NULL, 1274524600855441408, 'LeastConnection', '', 60000); -INSERT INTO `appapigatewaybalanceroptions` VALUES (93, NULL, 1274543888438525952, 'LeastConnection', '', 60000); INSERT INTO `appapigatewaybalanceroptions` VALUES (94, NULL, 1285579388652576768, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (95, NULL, 1285580096881778688, 'LeastConnection', '', 60000); INSERT INTO `appapigatewaybalanceroptions` VALUES (96, NULL, 1285582774663864320, 'LeastConnection', '', 60000); @@ -309,6 +271,10 @@ INSERT INTO `appapigatewaybalanceroptions` VALUES (100, NULL, 128865830515696435 INSERT INTO `appapigatewaybalanceroptions` VALUES (101, NULL, 1288658491216289792, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (102, NULL, 1288658638302142464, '', '', 0); INSERT INTO `appapigatewaybalanceroptions` VALUES (103, NULL, 1288658791784308736, '', '', 0); +INSERT INTO `appapigatewaybalanceroptions` VALUES (104, NULL, 1290849478956199936, '', '', 0); +INSERT INTO `appapigatewaybalanceroptions` VALUES (105, NULL, 1290849628051124224, '', '', 0); +INSERT INTO `appapigatewaybalanceroptions` VALUES (106, NULL, 1290849798553776128, '', '', 0); +INSERT INTO `appapigatewaybalanceroptions` VALUES (107, NULL, 1290849978032238592, '', '', 0); -- ---------------------------- -- Table structure for appapigatewaycacheoptions @@ -392,26 +358,6 @@ INSERT INTO `appapigatewaycacheoptions` VALUES (67, 1267383367629807616, 0, ''); INSERT INTO `appapigatewaycacheoptions` VALUES (68, 1267817055527632896, NULL, NULL); INSERT INTO `appapigatewaycacheoptions` VALUES (69, 1267817221286526976, NULL, NULL); INSERT INTO `appapigatewaycacheoptions` VALUES (70, 1268893687085518848, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (71, 1273527659565547520, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (72, 1273542336509079552, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (73, 1273542755520049152, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (74, 1273543111322857472, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (75, 1273543850526994432, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (76, 1273544135009857536, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (77, 1273544377432240128, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (78, 1273544549834911744, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (79, 1273545100509278208, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (80, 1273545462146363392, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (81, 1273545765801390080, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (82, 1273877904709361664, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (83, 1273878097483767808, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (84, 1273878425839050752, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (85, 1273879014778052608, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (86, 1273879265417076736, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (87, 1273879533101752320, NULL, NULL); -INSERT INTO `appapigatewaycacheoptions` VALUES (88, 1274294160109314048, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (89, 1274524600855441408, 0, ''); -INSERT INTO `appapigatewaycacheoptions` VALUES (90, 1274543888438525952, 0, ''); INSERT INTO `appapigatewaycacheoptions` VALUES (91, 1285579388652576768, NULL, NULL); INSERT INTO `appapigatewaycacheoptions` VALUES (92, 1285580096881778688, NULL, NULL); INSERT INTO `appapigatewaycacheoptions` VALUES (93, 1285582774663864320, 0, ''); @@ -422,6 +368,10 @@ INSERT INTO `appapigatewaycacheoptions` VALUES (97, 1288658305156964352, 0, ''); INSERT INTO `appapigatewaycacheoptions` VALUES (98, 1288658491216289792, 0, ''); INSERT INTO `appapigatewaycacheoptions` VALUES (99, 1288658638302142464, 0, ''); INSERT INTO `appapigatewaycacheoptions` VALUES (100, 1288658791784308736, 0, ''); +INSERT INTO `appapigatewaycacheoptions` VALUES (101, 1290849478956199936, NULL, NULL); +INSERT INTO `appapigatewaycacheoptions` VALUES (102, 1290849628051124224, 0, ''); +INSERT INTO `appapigatewaycacheoptions` VALUES (103, 1290849798553776128, 0, ''); +INSERT INTO `appapigatewaycacheoptions` VALUES (104, 1290849978032238592, 0, ''); -- ---------------------------- -- Table structure for appapigatewaydiscovery @@ -447,8 +397,6 @@ CREATE TABLE `appapigatewaydiscovery` ( -- Records of appapigatewaydiscovery -- ---------------------------- INSERT INTO `appapigatewaydiscovery` VALUES (1, 1260841964962947072, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO `appapigatewaydiscovery` VALUES (2, 1265168245423443968, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -INSERT INTO `appapigatewaydiscovery` VALUES (3, 1273519675519270912, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); -- ---------------------------- -- Table structure for appapigatewaydynamicreroute @@ -599,33 +547,11 @@ INSERT INTO `appapigatewayhttpoptions` VALUES (63, NULL, 1263305430536855552, 0, INSERT INTO `appapigatewayhttpoptions` VALUES (64, NULL, 1263639172959174656, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (65, NULL, 1264799968944640000, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (66, NULL, 1264800070161584128, 0, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (67, 1265168245423443968, NULL, 1000, 0, 0, 1, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (68, NULL, 1267360794414161920, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (69, NULL, 1267383367629807616, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (70, NULL, 1267817055527632896, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (71, NULL, 1267817221286526976, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (72, NULL, 1268893687085518848, 0, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (73, 1273519675519270912, NULL, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (74, NULL, 1273527659565547520, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (75, NULL, 1273542336509079552, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (76, NULL, 1273542755520049152, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (77, NULL, 1273543111322857472, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (78, NULL, 1273543850526994432, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (79, NULL, 1273544135009857536, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (80, NULL, 1273544377432240128, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (81, NULL, 1273544549834911744, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (82, NULL, 1273545100509278208, 10000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (83, NULL, 1273545462146363392, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (84, NULL, 1273545765801390080, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (85, NULL, 1273877904709361664, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (86, NULL, 1273878097483767808, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (87, NULL, 1273878425839050752, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (88, NULL, 1273879014778052608, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (89, NULL, 1273879265417076736, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (90, NULL, 1273879533101752320, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (91, NULL, 1274294160109314048, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (92, NULL, 1274524600855441408, 1000, 0, 0, 0, 0); -INSERT INTO `appapigatewayhttpoptions` VALUES (93, NULL, 1274543888438525952, 1000, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (94, NULL, 1285579388652576768, 0, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (95, NULL, 1285580096881778688, 1000, 0, 0, 1, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (96, NULL, 1285582774663864320, 1000, 0, 0, 1, 0); @@ -636,6 +562,10 @@ INSERT INTO `appapigatewayhttpoptions` VALUES (100, NULL, 1288658305156964352, 1 INSERT INTO `appapigatewayhttpoptions` VALUES (101, NULL, 1288658491216289792, 1000, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (102, NULL, 1288658638302142464, 1000, 0, 0, 0, 0); INSERT INTO `appapigatewayhttpoptions` VALUES (103, NULL, 1288658791784308736, 1000, 0, 0, 0, 0); +INSERT INTO `appapigatewayhttpoptions` VALUES (104, NULL, 1290849478956199936, 0, 0, 0, 0, 0); +INSERT INTO `appapigatewayhttpoptions` VALUES (105, NULL, 1290849628051124224, 0, 0, 0, 0, 0); +INSERT INTO `appapigatewayhttpoptions` VALUES (106, NULL, 1290849798553776128, 0, 0, 0, 0, 0); +INSERT INTO `appapigatewayhttpoptions` VALUES (107, NULL, 1290849978032238592, 0, 0, 0, 0, 0); -- ---------------------------- -- Table structure for appapigatewayqosoptions @@ -719,33 +649,11 @@ INSERT INTO `appapigatewayqosoptions` VALUES (63, NULL, 1263305430536855552, 50, INSERT INTO `appapigatewayqosoptions` VALUES (64, NULL, 1263639172959174656, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (65, NULL, 1264799968944640000, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (66, NULL, 1264800070161584128, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (67, 1265168245423443968, NULL, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (68, NULL, 1267360794414161920, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (69, NULL, 1267383367629807616, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (70, NULL, 1267817055527632896, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (71, NULL, 1267817221286526976, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (72, NULL, 1268893687085518848, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (73, 1273519675519270912, NULL, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (74, NULL, 1273527659565547520, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (75, NULL, 1273542336509079552, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (76, NULL, 1273542755520049152, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (77, NULL, 1273543111322857472, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (78, NULL, 1273543850526994432, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (79, NULL, 1273544135009857536, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (80, NULL, 1273544377432240128, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (81, NULL, 1273544549834911744, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (82, NULL, 1273545100509278208, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (83, NULL, 1273545462146363392, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (84, NULL, 1273545765801390080, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (85, NULL, 1273877904709361664, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (86, NULL, 1273878097483767808, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (87, NULL, 1273878425839050752, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (88, NULL, 1273879014778052608, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (89, NULL, 1273879265417076736, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (90, NULL, 1273879533101752320, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (91, NULL, 1274294160109314048, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (92, NULL, 1274524600855441408, 50, 60000, 30000); -INSERT INTO `appapigatewayqosoptions` VALUES (93, NULL, 1274543888438525952, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (94, NULL, 1285579388652576768, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (95, NULL, 1285580096881778688, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (96, NULL, 1285582774663864320, 50, 60000, 30000); @@ -756,6 +664,10 @@ INSERT INTO `appapigatewayqosoptions` VALUES (100, NULL, 1288658305156964352, 50 INSERT INTO `appapigatewayqosoptions` VALUES (101, NULL, 1288658491216289792, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (102, NULL, 1288658638302142464, 50, 60000, 30000); INSERT INTO `appapigatewayqosoptions` VALUES (103, NULL, 1288658791784308736, 50, 60000, 30000); +INSERT INTO `appapigatewayqosoptions` VALUES (104, NULL, 1290849478956199936, 50, 60000, 30000); +INSERT INTO `appapigatewayqosoptions` VALUES (105, NULL, 1290849628051124224, 50, 60000, 30000); +INSERT INTO `appapigatewayqosoptions` VALUES (106, NULL, 1290849798553776128, 50, 60000, 30000); +INSERT INTO `appapigatewayqosoptions` VALUES (107, NULL, 1290849978032238592, 50, 60000, 30000); -- ---------------------------- -- Table structure for appapigatewayratelimitoptions @@ -778,8 +690,6 @@ CREATE TABLE `appapigatewayratelimitoptions` ( -- Records of appapigatewayratelimitoptions -- ---------------------------- INSERT INTO `appapigatewayratelimitoptions` VALUES (1, 1260841964962947072, 'ClientId', '您的操作过快,请稍后再试!', 'ocelot', 1, 429); -INSERT INTO `appapigatewayratelimitoptions` VALUES (2, 1265168245423443968, 'ClientId', '{\n \"error\": {\n \"code\": \"429\",\n \"message\": \"对不起,在处理您的请求期间出现了一个服务器内部错误!\",\n \"details\": \"您的操作过快,请稍后再试!\",\n \"validationErrors\": []\n }\n}', 'ocelot', 1, 429); -INSERT INTO `appapigatewayratelimitoptions` VALUES (3, 1273519675519270912, 'ClientId', NULL, 'ocelot', 1, 429); -- ---------------------------- -- Table structure for appapigatewayratelimitrule @@ -869,26 +779,6 @@ INSERT INTO `appapigatewayratelimitrule` VALUES (67, 1267383367629807616, NULL, INSERT INTO `appapigatewayratelimitrule` VALUES (68, 1267817055527632896, NULL, '', 0, NULL, NULL, NULL); INSERT INTO `appapigatewayratelimitrule` VALUES (69, 1267817221286526976, NULL, '', 0, NULL, NULL, NULL); INSERT INTO `appapigatewayratelimitrule` VALUES (70, 1268893687085518848, NULL, '', 0, NULL, NULL, NULL); -INSERT INTO `appapigatewayratelimitrule` VALUES (71, 1273527659565547520, NULL, 'apigateway-host-client,apigateway-admin-client', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (72, 1273542336509079552, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (73, 1273542755520049152, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (74, 1273543111322857472, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (75, 1273543850526994432, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (76, 1273544135009857536, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (77, 1273544377432240128, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (78, 1273544549834911744, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (79, 1273545100509278208, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (80, 1273545462146363392, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (81, 1273545765801390080, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (82, 1273877904709361664, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (83, 1273878097483767808, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (84, 1273878425839050752, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (85, 1273879014778052608, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (86, 1273879265417076736, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (87, 1273879533101752320, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (88, 1274294160109314048, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (89, 1274524600855441408, NULL, '', 1, '1m', 60, 200); -INSERT INTO `appapigatewayratelimitrule` VALUES (90, 1274543888438525952, NULL, '', 1, '1m', 60, 200); INSERT INTO `appapigatewayratelimitrule` VALUES (91, 1285579388652576768, NULL, '', 0, NULL, NULL, NULL); INSERT INTO `appapigatewayratelimitrule` VALUES (92, 1285580096881778688, NULL, '', 1, '1m', 60, 200); INSERT INTO `appapigatewayratelimitrule` VALUES (93, 1285582774663864320, NULL, '', 1, '1m', 60, 200); @@ -899,6 +789,10 @@ INSERT INTO `appapigatewayratelimitrule` VALUES (97, 1288658305156964352, NULL, INSERT INTO `appapigatewayratelimitrule` VALUES (98, 1288658491216289792, NULL, '', 0, NULL, NULL, NULL); INSERT INTO `appapigatewayratelimitrule` VALUES (99, 1288658638302142464, NULL, '', 0, NULL, NULL, NULL); INSERT INTO `appapigatewayratelimitrule` VALUES (100, 1288658791784308736, NULL, '', 0, NULL, NULL, NULL); +INSERT INTO `appapigatewayratelimitrule` VALUES (101, 1290849478956199936, NULL, '', 0, NULL, NULL, NULL); +INSERT INTO `appapigatewayratelimitrule` VALUES (102, 1290849628051124224, NULL, '', 0, NULL, NULL, NULL); +INSERT INTO `appapigatewayratelimitrule` VALUES (103, 1290849798553776128, NULL, '', 0, NULL, NULL, NULL); +INSERT INTO `appapigatewayratelimitrule` VALUES (104, 1290849978032238592, NULL, '', 0, NULL, NULL, NULL); -- ---------------------------- -- Table structure for appapigatewayreroute @@ -1000,7 +894,7 @@ INSERT INTO `appapigatewayreroute` VALUES (62, '{}', '9810656b884947e3897e776b47 INSERT INTO `appapigatewayreroute` VALUES (63, '{}', '12254ca25e15420faa694f62148dd694', 1263305106250047488, '平台服务-特定租户管理', '/api/multi-tenancy/tenants/{id}', '', '', '/api/multi-tenancy/tenants/{id}', 'GET,PUT,DELETE,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (64, '{}', '27761205c6344bfebbafbc077781ab76', 1263305244594970624, '平台服务-租户连接字符串', '/api/multi-tenancy/tenants/{id}/connection-string', '', '', '/api/multi-tenancy/tenants/{id}/concatenation', 'GET,PUT,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 2, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (65, '{}', 'af470c53a25340fd9248fd0309ad41ef', 1263305430536855552, '平台服务-特定租户连接字符串', '/api/multi-tenancy/tenants/{id}/connection-string/{name}', '', '', '/api/multi-tenancy/tenants/{id}/concatenation/{name}', 'GET,DELETE,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 1, 30000, 1, '', 'TEST-APP'); -INSERT INTO `appapigatewayreroute` VALUES (66, '{}', 'a7a61cb210484794a5ad380938630058', 1263639172959174656, '平台服务-配置管理', '/api/abp/setting', '', '', '/api/abp/setting', 'GET,PUT,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); +INSERT INTO `appapigatewayreroute` VALUES (66, '{}', '50b18f8d4ddb4540b142877a7852f20d', 1263639172959174656, '【平台服务】- 公共配置', '/api/settings/by-global', '', '', '/api/settings/by-global', 'GET,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (67, '{}', '858056ce80b8420084b60d62ef4aa25c', 1264799968944640000, '平台服务-验证手机号', '/api/account/phone/verify', '', '', '/api/account/phone/verify', 'POST,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (68, '{}', 'd460979de403436e840de179767ed770', 1264800070161584128, '平台服务-手机号注册', '/api/account/phone/register', '', '', '/api/account/phone/register', 'POST,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (69, '{}', 'd2329516ff954ab68f29c69da8db725a', 1267360794414161920, '即时通讯-通知', '/signalr-hubs/notifications/{everything}', '', '', '/signalr-hubs/notifications/{everything}', 'POST,GET,OPTIONS,PUT,DELETE,', '', '', '', '', '', '', '', 1, '', '', 'ws', '127.0.0.1:30020,', '', '', '', 1, 30000, 1, '', 'TEST-APP'); @@ -1018,6 +912,10 @@ INSERT INTO `appapigatewayreroute` VALUES (104, '{}', '3515e75becf9447492ad60466 INSERT INTO `appapigatewayreroute` VALUES (105, '{}', 'aab0a24d930f4f9687497e5ccaac2a31', 1288658491216289792, '【身份认证服务】- 查询组织机构最后一个子节点', '/api/identity/organization-units/last-children', '', '', '/api/identity/organization-units/last-children', 'GET,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (106, '{}', 'edf67e297c6d494baf3ea66465418faf', 1288658638302142464, '【身份认证服务】- 组织机构角色管理', '/api/identity/organization-units/management-roles', '', '', '/api/identity/organization-units/management-roles', 'GET,POST,DELETE,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); INSERT INTO `appapigatewayreroute` VALUES (107, '{}', '21bcb13e71c648a98861ce9b6fb3e7b0', 1288658791784308736, '【身份认证服务】- 组织机构用户管理', '/api/identity/organization-units/management-users', '', '', '/api/identity/organization-units/management-users', 'GET,POST,DELETE,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); +INSERT INTO `appapigatewayreroute` VALUES (108, '{}', '417a4518e0da4db0a2704511d6a8c343', 1290849478956199936, '【平台服务】- 当前租户配置', '/api/settings/by-tenant', '', '', '/api/settings/by-tenant', 'GET,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); +INSERT INTO `appapigatewayreroute` VALUES (109, '{}', 'e937ff4ea11e4f0ca39d079c7a83b960', 1290849628051124224, '【平台服务】- 用户配置', '/api/settings/by-user', '', '', '/api/settings/by-user', 'GET,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); +INSERT INTO `appapigatewayreroute` VALUES (110, '{}', '22212bc751b743678d9c2f095d05ce25', 1290849798553776128, '【平台服务】- 当前用户配置', '/api/settings/by-current-user', '', '', '/api/settings/by-current-user', 'GET,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); +INSERT INTO `appapigatewayreroute` VALUES (111, '{}', '8dfa430d752a4b4a869ad401b3802a62', 1290849978032238592, '【平台服务】- 配置管理', '/api/settings', '', '', '/api/settings', 'GET,PUT,', '', '', '', '', '', '', '', 1, '', '', 'HTTP', '127.0.0.1:30010,', '', '', '', 0, 30000, 1, '', 'TEST-APP'); -- ---------------------------- -- Table structure for appapigatewayroutegroup @@ -1047,7 +945,7 @@ CREATE TABLE `appapigatewayroutegroup` ( -- ---------------------------- -- Records of appapigatewayroutegroup -- ---------------------------- -INSERT INTO `appapigatewayroutegroup` VALUES ('08d7f735-a83b-49ab-8cee-5d602502bea8', '{}', '8484f6852d3b4252a0b6bf278f9afd48', '2020-05-13 20:03:32.524271', NULL, '2020-05-13 21:34:30.407974', NULL, 0, NULL, NULL, '测试组', 'TEST-APP', '测试网关分组', '127.0.0.1', '测试网关分组', 1); +INSERT INTO `appapigatewayroutegroup` VALUES ('08d7f735-a83b-49ab-8cee-5d602502bea8', '{}', '83cac848676f4b658d5c9f7d802a497a', '2020-05-13 20:03:32.524271', NULL, '2020-08-05 15:43:28.205288', 'bf289dbb-838e-a89b-c622-39f51dcc4f43', 0, NULL, NULL, 'abp后台管理', 'TEST-APP', 'abp后台管理', '127.0.0.1', 'abp后台管理项目网关', 1); -- ---------------------------- -- Table structure for appapigatewaysecurityoptions @@ -1131,26 +1029,6 @@ INSERT INTO `appapigatewaysecurityoptions` VALUES (67, 1267383367629807616, '', INSERT INTO `appapigatewaysecurityoptions` VALUES (68, 1267817055527632896, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (69, 1267817221286526976, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (70, 1268893687085518848, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (71, 1273527659565547520, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (72, 1273542336509079552, '127.0.0.1', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (73, 1273542755520049152, '127.0.0.1', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (74, 1273543111322857472, '127.0.0.1', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (75, 1273543850526994432, '127.0.0.1', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (76, 1273544135009857536, '127.0.0.1', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (77, 1273544377432240128, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (78, 1273544549834911744, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (79, 1273545100509278208, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (80, 1273545462146363392, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (81, 1273545765801390080, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (82, 1273877904709361664, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (83, 1273878097483767808, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (84, 1273878425839050752, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (85, 1273879014778052608, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (86, 1273879265417076736, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (87, 1273879533101752320, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (88, 1274294160109314048, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (89, 1274524600855441408, '', ''); -INSERT INTO `appapigatewaysecurityoptions` VALUES (90, 1274543888438525952, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (91, 1285579388652576768, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (92, 1285580096881778688, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (93, 1285582774663864320, '', ''); @@ -1161,6 +1039,10 @@ INSERT INTO `appapigatewaysecurityoptions` VALUES (97, 1288658305156964352, '', INSERT INTO `appapigatewaysecurityoptions` VALUES (98, 1288658491216289792, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (99, 1288658638302142464, '', ''); INSERT INTO `appapigatewaysecurityoptions` VALUES (100, 1288658791784308736, '', ''); +INSERT INTO `appapigatewaysecurityoptions` VALUES (101, 1290849478956199936, '', ''); +INSERT INTO `appapigatewaysecurityoptions` VALUES (102, 1290849628051124224, '', ''); +INSERT INTO `appapigatewaysecurityoptions` VALUES (103, 1290849798553776128, '', ''); +INSERT INTO `appapigatewaysecurityoptions` VALUES (104, 1290849978032238592, '', ''); -- ---------------------------- -- Table structure for cap.published @@ -1179,17 +1061,6 @@ CREATE TABLE `cap.published` ( INDEX `IX_ExpiresAt`(`ExpiresAt`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_0900_ai_ci ROW_FORMAT = Dynamic; --- ---------------------------- --- Records of cap.published --- ---------------------------- -INSERT INTO `cap.published` VALUES (1288657615026184192, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288657615026184192\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:08:12 +08:00\",\"cap-corr-id\":\"1288657615026184192\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:08:12.1765932+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:08:12', '2020-07-31 10:08:12', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288657799890132992, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288657799890132992\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:08:56 +08:00\",\"cap-corr-id\":\"1288657799890132992\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:08:56.2542+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Modify\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:08:56', '2020-07-31 10:08:56', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288657941858934784, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288657941858934784\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:09:30 +08:00\",\"cap-corr-id\":\"1288657941858934784\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:09:30.1028+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:09:30', '2020-07-31 10:09:30', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288658134121635840, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288658134121635840\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:10:15 +08:00\",\"cap-corr-id\":\"1288658134121635840\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:10:15.9418485+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:10:16', '2020-07-31 10:10:16', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288658305198907392, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288658305198907392\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:10:56 +08:00\",\"cap-corr-id\":\"1288658305198907392\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:10:56.7297211+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:10:57', '2020-07-31 10:10:57', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288658491258232832, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288658491258232832\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:11:41 +08:00\",\"cap-corr-id\":\"1288658491258232832\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:11:41.0897204+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:11:41', '2020-07-31 10:11:41', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288658638331502592, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288658638331502592\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:12:16 +08:00\",\"cap-corr-id\":\"1288658638331502592\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:12:16.1548814+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:12:16', '2020-07-31 10:12:16', 'Succeeded'); -INSERT INTO `cap.published` VALUES (1288658791822057472, 'v1', 'LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData', '{\"Headers\":{\"cap-callback-name\":null,\"cap-msg-id\":\"1288658791822057472\",\"cap-msg-name\":\"LINGYUN.ApiGateway.EventBus.ApigatewayConfigChangeEventData\",\"cap-msg-type\":\"Object\",\"cap-senttime\":\"2020/7/30 10:12:52 +08:00\",\"cap-corr-id\":\"1288658791822057472\",\"cap-corr-seq\":\"0\"},\"Value\":{\"DateTime\":\"2020-07-30T10:12:52.7491793+08:00\",\"AppId\":\"TEST-APP\",\"Method\":\"Create\",\"Object\":\"ReRoute\"}}', 0, '2020-07-30 10:12:53', '2020-07-31 10:12:53', 'Succeeded'); -- ---------------------------- -- Table structure for cap.received diff --git a/aspnet-core/modules/account/LINGYUN.Abp.Account.Domain/LINGYUN/Abp/Account/AbpAccountSettingDefinitionProvider.cs b/aspnet-core/modules/account/LINGYUN.Abp.Account.Domain/LINGYUN/Abp/Account/AbpAccountSettingDefinitionProvider.cs index 5ea113e60..b3a7df3c9 100644 --- a/aspnet-core/modules/account/LINGYUN.Abp.Account.Domain/LINGYUN/Abp/Account/AbpAccountSettingDefinitionProvider.cs +++ b/aspnet-core/modules/account/LINGYUN.Abp.Account.Domain/LINGYUN/Abp/Account/AbpAccountSettingDefinitionProvider.cs @@ -16,14 +16,42 @@ namespace LINGYUN.Abp.Account { return new SettingDefinition[] { - new SettingDefinition(AccountSettingNames.SmsRegisterTemplateCode, - "SMS_190728520", L("DisplayName:SmsRegisterTemplateCode"), L("Description:SmsRegisterTemplateCode")), - new SettingDefinition(AccountSettingNames.SmsSigninTemplateCode, - "SMS_190728516", L("DisplayName:SmsSigninTemplateCode"), L("Description:SmsSigninTemplateCode")), - new SettingDefinition(AccountSettingNames.SmsResetPasswordTemplateCode, - "SMS_192530831", L("DisplayName:SmsResetPasswordTemplateCode"), L("Description:SmsResetPasswordTemplateCode")), - new SettingDefinition(AccountSettingNames.PhoneVerifyCodeExpiration, - "3", L("DisplayName:PhoneVerifyCodeExpiration"), L("Description:PhoneVerifyCodeExpiration")), + new SettingDefinition( + name: AccountSettingNames.SmsRegisterTemplateCode, + defaultValue: "SMS_190728520", + displayName: L("DisplayName:SmsRegisterTemplateCode"), + description: L("Description:SmsRegisterTemplateCode"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), + new SettingDefinition( + name: AccountSettingNames.SmsSigninTemplateCode, + defaultValue: "SMS_190728516", + displayName: L("DisplayName:SmsSigninTemplateCode"), + description: L("Description:SmsSigninTemplateCode"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), + new SettingDefinition( + name: AccountSettingNames.SmsResetPasswordTemplateCode, + defaultValue: "SMS_192530831", + displayName: L("DisplayName:SmsResetPasswordTemplateCode"), + description: L("Description:SmsResetPasswordTemplateCode"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), + new SettingDefinition( + name: AccountSettingNames.PhoneVerifyCodeExpiration, + defaultValue: "3", + displayName: L("DisplayName:PhoneVerifyCodeExpiration"), + description: L("Description:PhoneVerifyCodeExpiration"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), }; } diff --git a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application.Contracts/LINGYUN/ApiGateway/Ocelot/Dto/RouteGroupUpdateDto.cs b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application.Contracts/LINGYUN/ApiGateway/Ocelot/Dto/RouteGroupUpdateDto.cs index cc1b4661b..4a2ccc356 100644 --- a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application.Contracts/LINGYUN/ApiGateway/Ocelot/Dto/RouteGroupUpdateDto.cs +++ b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application.Contracts/LINGYUN/ApiGateway/Ocelot/Dto/RouteGroupUpdateDto.cs @@ -8,6 +8,12 @@ namespace LINGYUN.ApiGateway.Ocelot [StringLength(50)] public string AppId { get; set; } + [StringLength(100)] + public string AppName { get; set; } + + [StringLength(256)] + public string AppIpAddress { get; set; } + [StringLength(50)] public string Name { get; set; } diff --git a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application/LINGYUN/ApiGateway/Ocelot/RouteGroupAppService.cs b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application/LINGYUN/ApiGateway/Ocelot/RouteGroupAppService.cs index 733fbefc8..ba25ac611 100644 --- a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application/LINGYUN/ApiGateway/Ocelot/RouteGroupAppService.cs +++ b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Application/LINGYUN/ApiGateway/Ocelot/RouteGroupAppService.cs @@ -75,6 +75,10 @@ namespace LINGYUN.ApiGateway.Ocelot router.Name = routerUpdateDto.Name; router.IsActive = routerUpdateDto.IsActive; router.Description = routerUpdateDto.Description; + router.SwitchApp(routerUpdateDto.AppName, routerUpdateDto.AppIpAddress); + + await RouterRepository.UpdateAsync(router); + await CurrentUnitOfWork.SaveChangesAsync(); return ObjectMapper.Map(router); } diff --git a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Domain/LINGYUN/ApiGateway/Ocelot/RouteGroup/RouteGroup.cs b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Domain/LINGYUN/ApiGateway/Ocelot/RouteGroup/RouteGroup.cs index d04fcb046..ca3ec11d1 100644 --- a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Domain/LINGYUN/ApiGateway/Ocelot/RouteGroup/RouteGroup.cs +++ b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.Domain/LINGYUN/ApiGateway/Ocelot/RouteGroup/RouteGroup.cs @@ -23,5 +23,11 @@ namespace LINGYUN.ApiGateway.Ocelot AppName = appName; AppIpAddress = appIp; } + + public void SwitchApp(string appName, string appIp) + { + AppName = appName ?? AppName; + AppIpAddress = appIp ?? AppIpAddress; + } } } diff --git a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayDbContext.cs b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayDbContext.cs index cb3f0bfd7..541cc63fd 100644 --- a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayDbContext.cs +++ b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayDbContext.cs @@ -1,6 +1,9 @@ -using LINGYUN.ApiGateway.Ocelot; +using LINGYUN.ApiGateway.Data.Filter; +using LINGYUN.ApiGateway.Ocelot; using LINGYUN.ApiGateway.Settings; using Microsoft.EntityFrameworkCore; +using System; +using System.Linq.Expressions; using Volo.Abp.Data; using Volo.Abp.EntityFrameworkCore; @@ -9,6 +12,7 @@ namespace LINGYUN.ApiGateway.EntityFrameworkCore [ConnectionStringName("Default")] public class ApiGatewayDbContext : AbpDbContext { + protected virtual bool IsActivationFilterEnabled => DataFilter?.IsEnabled() ?? false; public virtual DbSet ReRoutes { get; set; } @@ -48,5 +52,19 @@ namespace LINGYUN.ApiGateway.EntityFrameworkCore options.Schema = ApiGatewaySettingNames.DefaultDbSchema; }); } + + protected override Expression> CreateFilterExpression() + { + var expression = base.CreateFilterExpression(); + + if (typeof(IActivation).IsAssignableFrom(typeof(TEntity))) + { + Expression> expression2 = ((TEntity e) => !IsActivationFilterEnabled || EF.Property(e, "IsActive")); + + expression = ((expression == null) ? expression2 : CombineExpressions(expression, expression2)); + } + + return expression; + } } } diff --git a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayEfCoreRepositoryBase.cs b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayEfCoreRepositoryBase.cs index 687d146d4..fac267fca 100644 --- a/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayEfCoreRepositoryBase.cs +++ b/aspnet-core/modules/apigateway/LINGYUN.ApiGateway.EntityFrameworkCore/LINGYUN/ApiGateway/EntityFrameworkCore/ApiGatewayEfCoreRepositoryBase.cs @@ -1,5 +1,4 @@ -using LINGYUN.ApiGateway.Data.Filter; -using System.Linq; +using System.Linq; using Volo.Abp.Domain.Entities; using Volo.Abp.Domain.Repositories.EntityFrameworkCore; using Volo.Abp.EntityFrameworkCore; @@ -25,28 +24,7 @@ namespace LINGYUN.ApiGateway.EntityFrameworkCore protected override IQueryable GetQueryable() { var query = base.GetQueryable(); - query = ApplyDataFilters(query); - return query; - } - /// - /// 过滤器 - /// - /// - /// - /// - protected override TQueryable ApplyDataFilters(TQueryable query) - { query = base.ApplyDataFilters(query); - - if (typeof(IActivation).IsAssignableFrom(typeof(TEntity))) - { - var enabledActivation = DataFilter.IsEnabled(); - if (enabledActivation) - { - query = (TQueryable)query.Where(e => ((IActivation)e).IsActive); - } - } - return query; } } diff --git a/aspnet-core/modules/platform/LINGYUN.Platform.Domain/LINGYUN/Platform/Settings/PlatformSettingDefinitionProvider.cs b/aspnet-core/modules/platform/LINGYUN.Platform.Domain/LINGYUN/Platform/Settings/PlatformSettingDefinitionProvider.cs index 3108202e2..09fc0b180 100644 --- a/aspnet-core/modules/platform/LINGYUN.Platform.Domain/LINGYUN/Platform/Settings/PlatformSettingDefinitionProvider.cs +++ b/aspnet-core/modules/platform/LINGYUN.Platform.Domain/LINGYUN/Platform/Settings/PlatformSettingDefinitionProvider.cs @@ -16,10 +16,24 @@ namespace LINGYUN.Platform.Settings { return new SettingDefinition[] { - new SettingDefinition(PlatformSettingNames.AppVersion.VersionFileLimitLength, AppVersionConsts.DefaultVersionFileLimitLength.ToString(), - L("DisplayName:VersionFileLimitLength"), L("Description:VersionFileLimitLength"), isVisibleToClients: true), - new SettingDefinition(PlatformSettingNames.AppVersion.AllowVersionFileExtensions, AppVersionConsts.DefaultAllowVersionFileExtensions, - L("DisplayName:AllowVersionFileExtensions"), L("Description:AllowVersionFileExtensions"), isVisibleToClients: true), + new SettingDefinition( + name: PlatformSettingNames.AppVersion.VersionFileLimitLength, + defaultValue: AppVersionConsts.DefaultVersionFileLimitLength.ToString(), + displayName: L("DisplayName:VersionFileLimitLength"), + description: L("Description:VersionFileLimitLength"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), + new SettingDefinition( + name: PlatformSettingNames.AppVersion.AllowVersionFileExtensions, + defaultValue: AppVersionConsts.DefaultAllowVersionFileExtensions, + displayName: L("DisplayName:AllowVersionFileExtensions"), + description: L("Description:AllowVersionFileExtensions"), + isVisibleToClients: true) + .WithProviders( + GlobalSettingValueProvider.ProviderName, + TenantSettingValueProvider.ProviderName), }; } diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissionProvider.cs b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissionProvider.cs index 584c304d5..0a1d00543 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissionProvider.cs +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissionProvider.cs @@ -15,6 +15,7 @@ namespace LINGYUN.Abp.SettingManagement var settingPermissions = settingPermissionGroup.AddPermission(AbpSettingManagementPermissions.Settings.Default, L("Permission:Settings")); settingPermissions.AddChild(AbpSettingManagementPermissions.Settings.Update, L("Permission:Update")); + settingPermissions.AddChild(AbpSettingManagementPermissions.Settings.Manager, L("Permission:Manager")); } private static LocalizableString L(string name) diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissions.cs b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissions.cs index eaa87cf0f..656e1273a 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissions.cs +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/AbpSettingManagementPermissions.cs @@ -1,4 +1,6 @@ -namespace LINGYUN.Abp.SettingManagement +using System; + +namespace LINGYUN.Abp.SettingManagement { public class AbpSettingManagementPermissions { @@ -8,7 +10,10 @@ { public const string Default = GroupName + ".Settings"; + [Obsolete("The best way to do this is to enable the configuration administrator privileges")] public const string Update = GroupName + ".Update"; + + public const string Manager = GroupName + ".Manager"; } } } diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/ISettingAppService.cs b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/ISettingAppService.cs index 8f1d15c70..9752f2b04 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/ISettingAppService.cs +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/ISettingAppService.cs @@ -1,4 +1,6 @@ using JetBrains.Annotations; +using System; +using System.ComponentModel.DataAnnotations; using System.Threading.Tasks; using Volo.Abp.Application.Dtos; using Volo.Abp.Application.Services; @@ -7,6 +9,15 @@ namespace LINGYUN.Abp.SettingManagement { public interface ISettingAppService : IApplicationService { + Task> GetAllGlobalAsync(); + + Task> GetAllForTenantAsync(); + + Task> GetAllForUserAsync([Required] Guid userId); + + Task> GetAllForCurrentUserAsync(); + + [Obsolete("The best way to do this is to separate the individual configurations")] Task> GetAsync([NotNull] string providerName, [NotNull] string providerKey); Task UpdateAsync([NotNull] string providerName, [NotNull] string providerKey, UpdateSettingsDto input); diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/en.json b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/en.json index ec938f4fd..7f4f13bfe 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/en.json +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/en.json @@ -3,6 +3,7 @@ "texts": { "Permission:SettingManagement": "SettingManagement", "Permission:Settings": "Settings", - "Permission:Update": "Update" + "Permission:Update": "Update", + "Permission:Manager": "Manager" } } \ No newline at end of file diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/zh-Hans.json b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/zh-Hans.json index 9312ce80e..f7c019e50 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/zh-Hans.json +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application.Contracts/LINGYUN/Abp/SettingManagement/Localization/ApplicationContracts/zh-Hans.json @@ -3,6 +3,7 @@ "texts": { "Permission:SettingManagement": "系统设置", "Permission:Settings": "配置管理", - "Permission:Update": "变更" + "Permission:Update": "变更", + "Permission:Manager": "管理" } } \ No newline at end of file diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application/LINGYUN/Abp/SettingManagement/SettingAppService.cs b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application/LINGYUN/Abp/SettingManagement/SettingAppService.cs index e63868347..778e4c245 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application/LINGYUN/Abp/SettingManagement/SettingAppService.cs +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.Application/LINGYUN/Abp/SettingManagement/SettingAppService.cs @@ -1,6 +1,8 @@ using JetBrains.Annotations; using Microsoft.AspNetCore.Authorization; +using System; using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; using System.Linq; using System.Threading.Tasks; using Volo.Abp.Application.Dtos; @@ -31,21 +33,69 @@ namespace LINGYUN.Abp.SettingManagement } public virtual async Task> GetAsync([NotNull] string providerName, [NotNull] string providerKey) + { + return await GetAllSettingAsync(providerName, providerKey); + } + + [Authorize(AbpSettingManagementPermissions.Settings.Manager)] + public virtual async Task UpdateAsync([NotNull] string providerName, [NotNull] string providerKey, UpdateSettingsDto input) + { + foreach (var setting in input.Settings) + { + await SettingManager.SetAsync(setting.Name, setting.Value, providerName, providerKey); + // 同步变更缓存配置 + var settingCacheKey = CalculateCacheKey(setting.Name, providerName, providerKey); + var settignCacheItem = new SettingCacheItem(setting.Value); + await Cache.SetAsync(settingCacheKey, settignCacheItem); + } + } + + [AllowAnonymous] + public virtual async Task> GetAllGlobalAsync() + { + var globalSettings = await SettingManager.GetAllGlobalAsync(); + + return GetAllSetting(globalSettings); + } + + public virtual async Task> GetAllForTenantAsync() + { + if (CurrentTenant.IsAvailable) + { + var tenantSettings = await SettingManager.GetAllForTenantAsync(CurrentTenant.Id.Value); + return GetAllSetting(tenantSettings); + } + return new ListResultDto(); + } + + public virtual async Task> GetAllForUserAsync([Required] Guid userId) + { + var userSettings = await SettingManager.GetAllForUserAsync(userId); + return GetAllSetting(userSettings); + } + + public virtual async Task> GetAllForCurrentUserAsync() + { + var userSettings = await SettingManager.GetAllForUserAsync(CurrentUser.Id.Value); + return GetAllSetting(userSettings); + } + + protected virtual async Task> GetAllSettingAsync( + string providerName, string providerKey) { var settingsDto = new List(); var settingDefinitions = SettingDefinitionManager.GetAll(); - foreach(var setting in settingDefinitions) + foreach (var setting in settingDefinitions) { if (setting.Providers.Any() && !setting.Providers.Contains(providerName)) { continue; } - // TODO: 是否遵循框架的限制? - //if (!setting.IsVisibleToClients) - //{ - // continue; - //} + if (!setting.IsVisibleToClients) + { + continue; + } var settingValue = await SettingManager.GetOrNullAsync(setting.Name, providerName, providerKey); var settingInfo = new SettingDto @@ -61,17 +111,30 @@ namespace LINGYUN.Abp.SettingManagement return new ListResultDto(settingsDto); } - [Authorize(AbpSettingManagementPermissions.Settings.Update)] - public virtual async Task UpdateAsync([NotNull] string providerName, [NotNull] string providerKey, UpdateSettingsDto input) + protected virtual ListResultDto GetAllSetting( + List settings) { - foreach (var setting in input.Settings) + var settingsDto = new List(); + + foreach (var setting in settings) { - await SettingManager.SetAsync(setting.Name, setting.Value, providerName, providerKey); - // 同步变更缓存配置 - var settingCacheKey = CalculateCacheKey(setting.Name, providerName, providerKey); - var settignCacheItem = new SettingCacheItem(setting.Value); - await Cache.SetAsync(settingCacheKey, settignCacheItem); + var settingDefinition = SettingDefinitionManager.Get(setting.Name); + + if (!settingDefinition.IsVisibleToClients) + { + continue; + } + var settingInfo = new SettingDto + { + Name = setting.Name, + Value = setting.Value, + DefaultValue = settingDefinition.DefaultValue, + Description = settingDefinition.Description.Localize(StringLocalizerFactory), + DisplayName = settingDefinition.DisplayName.Localize(StringLocalizerFactory) + }; + settingsDto.Add(settingInfo); } + return new ListResultDto(settingsDto); } protected virtual string CalculateCacheKey(string name, string providerName, string providerKey) diff --git a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.HttpApi/LINGYUN/Abp/SettingManagement/SettingController.cs b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.HttpApi/LINGYUN/Abp/SettingManagement/SettingController.cs index 70cbd5240..a6c9c80e8 100644 --- a/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.HttpApi/LINGYUN/Abp/SettingManagement/SettingController.cs +++ b/aspnet-core/modules/settings/LINGYUN.Abp.SettingManagement.HttpApi/LINGYUN/Abp/SettingManagement/SettingController.cs @@ -1,5 +1,7 @@ using JetBrains.Annotations; using Microsoft.AspNetCore.Mvc; +using System; +using System.ComponentModel.DataAnnotations; using System.Threading.Tasks; using Volo.Abp; using Volo.Abp.Application.Dtos; @@ -8,7 +10,8 @@ using Volo.Abp.AspNetCore.Mvc; namespace LINGYUN.Abp.SettingManagement { [RemoteService(Name = AbpSettingManagementRemoteServiceConsts.RemoteServiceName)] - [Area("abp")] + [Area("settings")] + [Route("api/settings")] public class SettingController : AbpController, ISettingAppService { private readonly ISettingAppService _settingAppService; @@ -17,11 +20,41 @@ namespace LINGYUN.Abp.SettingManagement _settingAppService = settingAppService; } + [HttpGet] + [Route("by-current-user")] + public virtual async Task> GetAllForCurrentUserAsync() + { + return await _settingAppService.GetAllForCurrentUserAsync(); + } + + [HttpGet] + [Route("by-tenant")] + public virtual async Task> GetAllForTenantAsync() + { + return await _settingAppService.GetAllForTenantAsync(); + } + + [HttpGet] + [Route("by-user")] + public virtual async Task> GetAllForUserAsync([Required] Guid userId) + { + return await _settingAppService.GetAllForUserAsync(userId); + } + + [HttpGet] + [Route("by-global")] + public virtual async Task> GetAllGlobalAsync() + { + return await _settingAppService.GetAllGlobalAsync(); + } + + [HttpGet] public virtual async Task> GetAsync([NotNull] string providerName, [NotNull] string providerKey) { return await _settingAppService.GetAsync(providerName, providerKey); } + [HttpPut] public virtual async Task UpdateAsync([NotNull] string providerName, [NotNull] string providerKey, UpdateSettingsDto input) { await _settingAppService.UpdateAsync(providerName, providerKey, input); diff --git a/aspnet-core/services/account/AuthServer.Host/AuthServer.Host.csproj b/aspnet-core/services/account/AuthServer.Host/AuthServer.Host.csproj index fdb28789f..fb3b42540 100644 --- a/aspnet-core/services/account/AuthServer.Host/AuthServer.Host.csproj +++ b/aspnet-core/services/account/AuthServer.Host/AuthServer.Host.csproj @@ -39,10 +39,6 @@ - - - - diff --git a/aspnet-core/services/admin/LINGYUN.BackendAdminApp.Host/LINGYUN.BackendAdminApp.Host.csproj b/aspnet-core/services/admin/LINGYUN.BackendAdminApp.Host/LINGYUN.BackendAdminApp.Host.csproj index 274580558..b04ea5122 100644 --- a/aspnet-core/services/admin/LINGYUN.BackendAdminApp.Host/LINGYUN.BackendAdminApp.Host.csproj +++ b/aspnet-core/services/admin/LINGYUN.BackendAdminApp.Host/LINGYUN.BackendAdminApp.Host.csproj @@ -78,6 +78,7 @@ + diff --git a/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/ApiGatewayHttpApiHostModule.cs b/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/ApiGatewayHttpApiHostModule.cs index d51780f0b..6006e0251 100644 --- a/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/ApiGatewayHttpApiHostModule.cs +++ b/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/ApiGatewayHttpApiHostModule.cs @@ -18,6 +18,7 @@ using System.Text; using Volo.Abp; using Volo.Abp.Autofac; using Volo.Abp.AutoMapper; +using Volo.Abp.Data; using Volo.Abp.EntityFrameworkCore; using Volo.Abp.EntityFrameworkCore.MySQL; using Volo.Abp.Localization; @@ -28,6 +29,7 @@ using Volo.Abp.Security.Claims; using Volo.Abp.Security.Encryption; using Volo.Abp.SettingManagement.EntityFrameworkCore; using Volo.Abp.TenantManagement.EntityFrameworkCore; +using Volo.Abp.Threading; namespace LINGYUN.ApiGateway { @@ -164,6 +166,17 @@ namespace LINGYUN.ApiGateway app.UseAuditing(); // 路由 app.UseConfiguredEndpoints(); + + SeedData(context); + } + + private void SeedData(ApplicationInitializationContext context) + { + AsyncHelper.RunSync(async () => + { + using var scope = context.ServiceProvider.CreateScope(); + await scope.ServiceProvider.GetRequiredService().SeedAsync(); + }); } } } diff --git a/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/DataSeeder/ApiGatewayAdminDataSeedContributor.cs b/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/DataSeeder/ApiGatewayAdminDataSeedContributor.cs new file mode 100644 index 000000000..b98cf98e7 --- /dev/null +++ b/aspnet-core/services/apigateway/LINGYUN.ApiGateway.HttpApi.Host/DataSeeder/ApiGatewayAdminDataSeedContributor.cs @@ -0,0 +1,43 @@ +using Microsoft.Extensions.Configuration; +using MySql.Data.MySqlClient; +using System; +using System.IO; +using System.Threading.Tasks; +using Volo.Abp.Data; +using Volo.Abp.DependencyInjection; +using Volo.Abp.IO; + +namespace DataSeeder +{ + public class ApiGatewayAdminDataSeedContributor : IDataSeedContributor, IScopedDependency + { + protected IConfiguration Configuration { get; } + public ApiGatewayAdminDataSeedContributor( + IConfiguration configuration) + { + Configuration = configuration; + } + + public virtual async Task SeedAsync(DataSeedContext context) + { + // Search file: ApiGateway-init.sql + var scriptCommandFilePath = Path.Combine(Directory.GetCurrentDirectory(), "../../../database"); + var scriptCommandFile = Path.Combine(scriptCommandFilePath, "ApiGateway-Init.sql"); + if (File.Exists(scriptCommandFile)) + { + // read all script + var apigatewayInitScript = await FileHelper.ReadAllTextAsync(scriptCommandFile); + if (!apigatewayInitScript.IsNullOrWhiteSpace()) + { + // open connection and excute the apigateway-init script + var connectionString = Configuration.GetConnectionString("ApiGateway"); + using var connection = new MySqlConnection(connectionString); + await connection.OpenAsync(); + var sqlTransaction = connection.BeginTransaction(); + var sqlCommand = new MySqlCommand(apigatewayInitScript, connection, sqlTransaction); + await sqlCommand.ExecuteNonQueryAsync(); + } + } + } + } +} diff --git a/vueJs/src/api/apigateway.ts b/vueJs/src/api/apigateway.ts index 94ebde590..672b0c04a 100644 --- a/vueJs/src/api/apigateway.ts +++ b/vueJs/src/api/apigateway.ts @@ -30,8 +30,8 @@ export default class ApiGateWay { } public static deleteGlobalConfiguration(appId: number) { - let _url = '/api/ApiGateway/Globals/' - _url += appId + let _url = '/api/ApiGateway/Globals' + _url += '?appId=' + appId return ApiService.Delete(_url, serviceUrl) } @@ -66,8 +66,8 @@ export default class ApiGateWay { } public static deleteRouteGroup(appId: string) { - let _url = '/api/ApiGateway/RouteGroups/' - _url += appId + let _url = '/api/ApiGateway/RouteGroups' + _url += '?appId=' + appId return ApiService.Delete(_url, serviceUrl) } @@ -326,7 +326,9 @@ export class RouteGroupCreateDto { export class RouteGroupUpdateDto { name = '' appId = '' + appName = '' isActive = true + appIpAddress?: string = '' description?: string = '' } diff --git a/vueJs/src/api/settings.ts b/vueJs/src/api/settings.ts index ae8a186bc..1e449a206 100644 --- a/vueJs/src/api/settings.ts +++ b/vueJs/src/api/settings.ts @@ -11,12 +11,45 @@ export default class SettingApiService { * @returns 返回类型为 ListResultDto 的配置列表 */ public static getSettings(providerName: string, providerKey: string) { - let _url = '/api/abp/setting' + let _url = '/api/settings' _url += '?providerName=' + providerName _url += '&providerKey=' + providerKey return ApiService.Get>(_url, IdentityService) } + /** + * 获取公共配置 + */ + public static getGlobalSettings() { + const _url = '/api/settings/by-global' + return ApiService.Get>(_url, IdentityService) + } + + /** + * 获取当前租户配置 + */ + public static getCurrentTenantSettings() { + const _url = '/api/settings/by-current-tenant' + return ApiService.Get>(_url, IdentityService) + } + + /** + * 获取当前用户配置 + */ + public static getCurrentUserSettings() { + const _url = '/api/settings/by-current-user' + return ApiService.Get>(_url, IdentityService) + } + + /** + * 获取用户配置 + */ + public static getUserSettings(userId: string) { + let _url = '/api/settings/by-user' + _url += '?userId=' + userId + return ApiService.Get>(_url, IdentityService) + } + /** * 保存配置 * @param providerName 配置提供者名称 @@ -25,7 +58,7 @@ export default class SettingApiService { * @returns Promise对象 */ public static setSettings(providerName: string, providerKey: string, payload: SettingsUpdate) { - let _url = '/api/abp/setting' + let _url = '/api/settings' _url += '?providerName=' + providerName _url += '&providerKey=' + providerKey return ApiService.Put(_url, payload, IdentityService) diff --git a/vueJs/src/views/admin/apigateway/components/RouteGroupCreateOrEditForm.vue b/vueJs/src/views/admin/apigateway/components/RouteGroupCreateOrEditForm.vue index 6e4aa4848..aa5693bf2 100644 --- a/vueJs/src/views/admin/apigateway/components/RouteGroupCreateOrEditForm.vue +++ b/vueJs/src/views/admin/apigateway/components/RouteGroupCreateOrEditForm.vue @@ -20,6 +20,7 @@ > @@ -103,6 +104,10 @@ export default class extends Vue { ] } + get isEditRouteGroup() { + return this.appId !== '' + } + constructor() { super() this.apiGateWayRouteGroup = new RouteGroupDto() @@ -112,6 +117,7 @@ export default class extends Vue { private handleAppIdChange(val: any) { if (val) { ApiGateWayService.getRouteGroupByAppId(val).then(router => { + console.log(router) this.apiGateWayRouteGroup = router }) } @@ -125,7 +131,9 @@ export default class extends Vue { const updateRouterDto = new RouteGroupUpdateDto() updateRouterDto.name = this.apiGateWayRouteGroup.name updateRouterDto.appId = this.apiGateWayRouteGroup.appId + updateRouterDto.appName = this.apiGateWayRouteGroup.appName updateRouterDto.isActive = this.apiGateWayRouteGroup.isActive + updateRouterDto.appIpAddress = this.apiGateWayRouteGroup.appIpAddress updateRouterDto.description = this.apiGateWayRouteGroup.description this.apiGateWayRouteGroup = await ApiGateWayService.updateRouteGroup(updateRouterDto) } else { diff --git a/vueJs/src/views/admin/apigateway/global.vue b/vueJs/src/views/admin/apigateway/global.vue index 19d0d7be4..981449eff 100644 --- a/vueJs/src/views/admin/apigateway/global.vue +++ b/vueJs/src/views/admin/apigateway/global.vue @@ -130,7 +130,7 @@ :disabled="!checkPermission(['ApiGateway.Global.Delete'])" size="mini" type="warning" - @click="handleDeleteGlobalConfiguration(row.itemId)" + @click="handleDeleteGlobalConfiguration(row.appId)" > {{ $t('apiGateWay.deleteGlobal') }} @@ -238,6 +238,7 @@ export default class extends Vue { await ApiGatewayService.deleteGlobalConfiguration(itemId) const successMessage = this.$t('dataHasBeenDeleted', { name: appId }).toString() this.$message.success(successMessage) + this.handledGetGlobalConfigurations() } } }) diff --git a/vueJs/src/views/admin/apigateway/group.vue b/vueJs/src/views/admin/apigateway/group.vue index cc850591b..a299faf77 100644 --- a/vueJs/src/views/admin/apigateway/group.vue +++ b/vueJs/src/views/admin/apigateway/group.vue @@ -264,6 +264,7 @@ export default class extends Vue { await ApiGatewayService.deleteRouteGroup(appId) const successMessage = this.$t('dataHasBeenDeleted', { name: appName }).toString() this.$message.success(successMessage) + this.handleGetRouteGroups() } } }) diff --git a/vueJs/src/views/admin/settings/components/GlobalSettingEditForm.vue b/vueJs/src/views/admin/settings/components/GlobalSettingEditForm.vue index fa3ea44e2..d140aa9e2 100644 --- a/vueJs/src/views/admin/settings/components/GlobalSettingEditForm.vue +++ b/vueJs/src/views/admin/settings/components/GlobalSettingEditForm.vue @@ -1,740 +1,18 @@ diff --git a/vueJs/src/views/admin/settings/components/SettingEditForm.vue b/vueJs/src/views/admin/settings/components/SettingEditForm.vue new file mode 100644 index 000000000..076d5e81b --- /dev/null +++ b/vueJs/src/views/admin/settings/components/SettingEditForm.vue @@ -0,0 +1,717 @@ + + + diff --git a/vueJs/src/views/admin/settings/components/TenantSettingEditForm.vue b/vueJs/src/views/admin/settings/components/TenantSettingEditForm.vue new file mode 100644 index 000000000..298b55975 --- /dev/null +++ b/vueJs/src/views/admin/settings/components/TenantSettingEditForm.vue @@ -0,0 +1,22 @@ + + + diff --git a/vueJs/src/views/admin/settings/components/UserSettingEditForm.vue b/vueJs/src/views/admin/settings/components/UserSettingEditForm.vue new file mode 100644 index 000000000..194cab827 --- /dev/null +++ b/vueJs/src/views/admin/settings/components/UserSettingEditForm.vue @@ -0,0 +1,22 @@ + + + diff --git a/vueJs/src/views/admin/settings/index.vue b/vueJs/src/views/admin/settings/index.vue index 80a9030e0..8de2bba5b 100644 --- a/vueJs/src/views/admin/settings/index.vue +++ b/vueJs/src/views/admin/settings/index.vue @@ -8,30 +8,51 @@ - {{ $t('settings.tenantSetting') }} + - {{ $t('settings.userSetting') }} +