[ 
https://issues.apache.org/jira/browse/TC-497?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16112994#comment-16112994
 ] 

Dylan Volz commented on TC-497:
-------------------------------

https://github.com/apache/incubator-trafficcontrol/pull/763 created

> delivery service updates taking >20 secs
> ----------------------------------------
>
>                 Key: TC-497
>                 URL: https://issues.apache.org/jira/browse/TC-497
>             Project: Traffic Control
>          Issue Type: Bug
>          Components: Traffic Ops
>            Reporter: Dylan Volz
>            Assignee: Dylan Volz
>
> delivery service updates have begun taking about 25 seconds to finish. 
> I have tracked this down to this call:
> my $rs = $self->db->resultset('DeliveryserviceRegex')->search(undef, 
> {prefetch => [
> {regex => undef}
> ,
> {deliveryservice => undef}
> ]} );
> in the find_existing_host_regex helper defined in 
> MojoPlugins/DeliveryService.pm
> The worker is selected for graceful shutdown due to no heartbeat each time an 
> update is made, but usually completes before the shutdown allowing the update 
> to go through.
> If you add a second host regex to the delivery service the update will always 
> fail because it makes that db call twice and thus the worker is killed before 
> the request finishes, and the request is sent to a new worker, continuing the 
> process until the browser cancels the request.
> Note: delivery service updates via the API do not have this problem because 
> it appears that code path does not check for conflicting regexes.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to