This is an automated email from the ASF dual-hosted git repository. elsloo pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-trafficcontrol.git
commit a165aaa35e429562d204865030d15bf3a5817b43 Author: Jesse Rivas <jesse_ri...@comcast.com> AuthorDate: Tue May 1 08:35:05 2018 -0600 changed anonymous_blocking_enabled field to boolean --- .../app/db/migrations/20180430000000_add_anonymous_blocking.sql | 2 +- .../app/lib/Schema/Result/DeliveryServiceInfoForDomainList.pm | 2 +- .../app/lib/Schema/Result/DeliveryServiceInfoForServerList.pm | 2 +- traffic_ops/app/lib/Schema/Result/Deliveryservice.pm | 8 ++++---- traffic_ops/app/lib/UI/Topology.pm | 3 +++ 5 files changed, 10 insertions(+), 7 deletions(-) diff --git a/traffic_ops/app/db/migrations/20180430000000_add_anonymous_blocking.sql b/traffic_ops/app/db/migrations/20180430000000_add_anonymous_blocking.sql index 4aab170..afabe9d 100644 --- a/traffic_ops/app/db/migrations/20180430000000_add_anonymous_blocking.sql +++ b/traffic_ops/app/db/migrations/20180430000000_add_anonymous_blocking.sql @@ -12,7 +12,7 @@ -- +goose Up -- SQL in section 'Up' is executed when this migration is applied -alter table deliveryservice add column anonymous_blocking_enabled int default 0; +alter table deliveryservice add column anonymous_blocking_enabled boolean NOT NULL default FALSE; -- +goose Down -- SQL section 'Down' is executed when this migration is rolled back diff --git a/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForDomainList.pm b/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForDomainList.pm index e8d5ce9..bb0f231 100644 --- a/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForDomainList.pm +++ b/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForDomainList.pm @@ -107,7 +107,7 @@ __PACKAGE__->add_columns( "fq_pacing_rate", { data_type => "bigint", is_nullable => 0 }, "origin_shield", { data_type => "varchar", is_nullable => 0, size => 1024 }, "profile", { data_type => "integer", is_nullable => 1}, - "anonymous_blocking_enabled", { data_type => "tinyint", is_nullable => 1, size => 1 }, + "anonymous_blocking_enabled", { data_type => "boolean", is_nullable => 0 }, ); 1; diff --git a/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForServerList.pm b/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForServerList.pm index 97c441f..f190d33 100644 --- a/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForServerList.pm +++ b/traffic_ops/app/lib/Schema/Result/DeliveryServiceInfoForServerList.pm @@ -100,7 +100,7 @@ __PACKAGE__->add_columns( "fq_pacing_rate", { data_type => "bigint", is_nullable => 0}, "origin_shield", { data_type => "varchar", is_nullable => 0, size => 1024 }, "profile", { data_type => "integer", is_nullable => 1}, - "anonymous_blocking_enabled", { data_type => "tinyint", is_nullable => 1, size => 1 }, + "anonymous_blocking_enabled", { data_type => "boolean", is_nullable => 0 }, ); 1; diff --git a/traffic_ops/app/lib/Schema/Result/Deliveryservice.pm b/traffic_ops/app/lib/Schema/Result/Deliveryservice.pm index 5eca585..dab1cce 100644 --- a/traffic_ops/app/lib/Schema/Result/Deliveryservice.pm +++ b/traffic_ops/app/lib/Schema/Result/Deliveryservice.pm @@ -42,9 +42,9 @@ __PACKAGE__->table("deliveryservice"); is_nullable: 0 =head2 anonymous_blocking_enabled - data_type: 'integer' - default_value: 0 - is_nullable: 1 + data_type: 'boolean' + default_value: false + is_nullable: 0 =head2 dscp @@ -332,7 +332,7 @@ __PACKAGE__->add_columns( "active", { data_type => "boolean", default_value => \"false", is_nullable => 0 }, "anonymous_blocking_enabled", - { data_type => "integer", default_value => 0, is_nullable => 1 }, + { data_type => "boolean", default_value => \"false", is_nullable => 0 }, "dscp", { data_type => "bigint", is_nullable => 0 }, "signing_algorithm", diff --git a/traffic_ops/app/lib/UI/Topology.pm b/traffic_ops/app/lib/UI/Topology.pm index be96d09..7f19f32 100644 --- a/traffic_ops/app/lib/UI/Topology.pm +++ b/traffic_ops/app/lib/UI/Topology.pm @@ -776,6 +776,9 @@ sub stringify_ds { if ( defined( $ds->{'regionalGeoBlocking'} ) ) { $string .= "|Regional_Geoblocking:" . $ds->{'regionalGeoBlocking'}; } + if ( defined( $ds->{'anonymousBlockingEnabled'} ) ) { + $string .= "|Anonymous_Blocking:" . $ds->{'anonymousBlockingEnabled'}; + } if ( defined( $ds->{'geoLimitRedirectURL'}) ) { $string .= "|Geolimit_Redirect_URL:" . $ds->{'geoLimitRedirectURL'}; } -- To stop receiving notification emails like this one, please contact els...@apache.org.