trafficcontrol-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mitchell...@apache.org
Subject [trafficcontrol] 08/13: cleaned up unused insert funcs
Date Wed, 11 Jul 2018 01:19:55 GMT
This is an automated email from the ASF dual-hosted git repository.

mitchell852 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficcontrol.git

commit c2f3ac4a29e44f9eee525e0e0525ae80af3505f6
Author: Dewayne Richardson <dewrich@apache.org>
AuthorDate: Thu May 31 08:31:03 2018 -0600

    cleaned up unused insert funcs
---
 traffic_ops/testing/api/v13/todb.go | 111 ------------------------------------
 1 file changed, 111 deletions(-)

diff --git a/traffic_ops/testing/api/v13/todb.go b/traffic_ops/testing/api/v13/todb.go
index 7f97673..6936194 100644
--- a/traffic_ops/testing/api/v13/todb.go
+++ b/traffic_ops/testing/api/v13/todb.go
@@ -166,95 +166,6 @@ INSERT INTO tenant (name, active, parent_id, last_updated) VALUES ('badtenant',
 	return nil
 }
 
-// SetupDeliveryServices ...
-func SetupDeliveryServices(db *sql.DB) error {
-
-	sqlStmt := `
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-INSERT INTO deliveryservice (id, xml_id, active, dscp, signing_algorithm, qstring_ignore,
geo_limit, http_bypass_fqdn, dns_bypass_ip, dns_bypass_ip6, dns_bypass_ttl, org_server_fqdn,
type, profile, cdn_id, ccr_dns_ttl, global_max_mbps, global_max_tps, long_desc, long_desc_1,
long_desc_2, max_dns_answers, info_url, miss_lat, miss_long, check_path, last_updated, protocol,
ssl_key_version, ipv6_routing_enabled, range_request_handling, edge_header_rewrite, origin_shield,
mid_header_rewrite,  [...]
-`
-	err := execSQL(db, sqlStmt, "deliveryservice")
-	if err != nil {
-		return fmt.Errorf("exec failed %v", err)
-	}
-	return nil
-}
-
-// SetupRegexes ...
-func SetupRegexes(db *sql.DB) error {
-
-	sqlStmt := `
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (100, '.*\.omg-01\..*', 19, '2018-01-19
21:58:36.120746');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1000, '.*\.target-ds1\..*', 19,
'2018-01-19 21:58:36.125624');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1100, '.*\.target-ds2\..*', 19,
'2018-01-19 21:58:36.128372');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1200, '.*\.target-ds3\..*', 19,
'2018-01-19 21:58:36.130749');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1300, '.*\.target-ds4\..*', 19,
'2018-01-19 21:58:36.133992');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1400, '.*\.target-ds5\..*', 19,
'2018-01-19 21:58:36.136503');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1500, '.*\.target-ds6\..*', 19,
'2018-01-19 21:58:36.138890');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1600, '.*\.target-ds7\..*', 19,
'2018-01-19 21:58:36.140495');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1700, '.*\.target-ds8\..*', 19,
'2018-01-19 21:58:36.142473');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1800, '.*\.target-ds9\..*', 19,
'2018-01-19 21:58:36.144087');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (1900, '.*\.target-ds10\..*',
19, '2018-01-19 21:58:36.145505');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (200, '.*\.foo\..*', 19, '2018-01-19
21:58:36.146953');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (300, '.*/force-to-one/.*', 20,
'2018-01-19 21:58:36.149052');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (400, '.*/force-to-one-also/.*',
20, '2018-01-19 21:58:36.150904');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (500, '.*/go-to-four/.*', 20,
'2018-01-19 21:58:36.152416');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (600, '.*/use-three/.*', 20, '2018-01-19
21:58:36.153884');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (700, '.*\.new-steering-ds\..*',
19, '2018-01-19 21:58:36.155352');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (800, '.*\.steering-ds1\..*',
19, '2018-01-19 21:58:36.156867');
-INSERT INTO regex (id, pattern, type, last_updated) VALUES (900, '.*\.steering-ds2\..*',
19, '2018-01-19 21:58:36.158999');
-`
-	err := execSQL(db, sqlStmt, "regex")
-	if err != nil {
-		return fmt.Errorf("exec failed %v", err)
-	}
-	return nil
-}
-
-// SetupDeliveryServiceRegexes ...
-func SetupDeliveryServiceRegexes(db *sql.DB) error {
-
-	sqlStmt := `
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (200, 100,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (400, 100,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (400, 1000,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (500, 1100,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (600, 1200,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (700, 1300,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (800, 1400,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (900, 1500,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (1000, 1600,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (1100, 1700,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (1200, 1800,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (1300, 1900,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (100, 200,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (400, 200,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (700, 300,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (600, 400,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (300, 600,
0);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (100, 800,
1);
-INSERT INTO deliveryservice_regex (deliveryservice, regex, set_number) VALUES (200, 900,
0);
-`
-	err := execSQL(db, sqlStmt, "deliveryservice_regex")
-	if err != nil {
-		return fmt.Errorf("exec failed %v", err)
-	}
-	return nil
-}
-
 // SetupDeliveryServiceTmUsers ...
 func SetupDeliveryServiceTmUsers(db *sql.DB) error {
 
@@ -268,28 +179,6 @@ INSERT INTO deliveryservice_tmuser (deliveryservice, tm_user_id, last_updated)
V
 	return nil
 }
 
-// SetupDeliveryServiceServers ...
-func SetupDeliveryServiceServers(db *sql.DB) error {
-
-	sqlStmt := `
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (100, 300,
'2018-01-19 21:19:32.396609');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (100, 1300,
'2018-01-19 21:19:32.408819');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (100, 100,
'2018-01-19 21:19:32.414612');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (200, 800,
'2018-01-19 21:19:32.420745');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (200, 700,
'2018-01-19 21:19:32.426505');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (500, 1500,
'2018-01-19 21:19:32.434097');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (500, 1400,
'2018-01-19 21:19:32.439622');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (600, 1400,
'2018-01-19 21:19:32.440831');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (600, 1500,
'2018-01-19 21:19:32.442121');
-INSERT INTO deliveryservice_server (deliveryservice, server, last_updated) VALUES (700, 900,
'2018-01-19 21:19:32.443372');
-`
-	err := execSQL(db, sqlStmt, "deliveryservice_server")
-	if err != nil {
-		return fmt.Errorf("exec failed %v", err)
-	}
-	return nil
-}
-
 // SetupJobStatuses ...
 func SetupJobStatuses(db *sql.DB) error {
 


Mime
View raw message