impala-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lars Volker (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (IMPALA-5487) Race in runtime-profile.cc::toThrift() can lead to corrupt profiles being generated while query is running
Date Tue, 13 Jun 2017 15:42:00 GMT

     [ https://issues.apache.org/jira/browse/IMPALA-5487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Lars Volker resolved IMPALA-5487.
---------------------------------
    Resolution: Fixed

IMPALA-5487: Fix race in RuntimeProfile::toThrift()

node.num_children got initialized before children_ was locked. This
could lead to node.num_children < children_.size(), which made the node
tree in the resulting thrift profiles not deserialize properly.

To fix this, node.num_children needs to be initialized after children_
has been locked.

I tested this by running queries on a private cluster for a while,
making sure that the thrift profiles of running queries could be parsed
correctly.

Change-Id: I7fad4ee2eee1f73e387c1e90a3db265b19b3a0c6
Reviewed-on: http://gerrit.cloudera.org:8080/7154
Reviewed-by: Dan Hecht <dhecht@cloudera.com>
Reviewed-by: Tim Armstrong <tarmstrong@cloudera.com>
Reviewed-by: Sailesh Mukil <sailesh@cloudera.com>
Tested-by: Impala Public Jenkins

> Race in runtime-profile.cc::toThrift() can lead to corrupt profiles being generated while
query is running
> ----------------------------------------------------------------------------------------------------------
>
>                 Key: IMPALA-5487
>                 URL: https://issues.apache.org/jira/browse/IMPALA-5487
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Backend
>    Affects Versions: Impala 2.9.0
>            Reporter: Lars Volker
>            Assignee: Lars Volker
>            Priority: Blocker
>             Fix For: Impala 2.10.0
>
>
> {{node.num_children}} is initialized before {{children_}} gets locked and if the latter
changes in the meantime, the thrift profiles cannot be deconstructed properly.



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

Mime
View raw message