[bugfix](mergeprofile) ignore null profile to avoid bug (#27860)
--------- Co-authored-by: yiguolei <yiguolei@gmail.com>
This commit is contained in:
@ -61,10 +61,8 @@ public:
|
||||
RETURN_IF_ERROR(DataSink::prepare(state));
|
||||
// Prepare the exprs to run.
|
||||
RETURN_IF_ERROR(VExpr::prepare(_output_vexpr_ctxs, state, _row_desc));
|
||||
std::stringstream title;
|
||||
title << _name << " (frag_id=" << state->fragment_instance_id() << ")";
|
||||
// create profile
|
||||
_profile = state->obj_pool()->add(new RuntimeProfile(title.str()));
|
||||
_profile = state->obj_pool()->add(new RuntimeProfile(_name));
|
||||
init_sink_common_profile();
|
||||
return Status::OK();
|
||||
}
|
||||
|
||||
@ -448,7 +448,12 @@ public class RuntimeProfile {
|
||||
private static List<RuntimeProfile> getChildListFromLists(String profileName, List<RuntimeProfile> profiles) {
|
||||
List<RuntimeProfile> ret = new ArrayList<RuntimeProfile>();
|
||||
for (RuntimeProfile profile : profiles) {
|
||||
ret.add(profile.getChildMap().get(profileName));
|
||||
RuntimeProfile tmp = profile.getChildMap().get(profileName);
|
||||
if (tmp != null) {
|
||||
ret.add(profile.getChildMap().get(profileName));
|
||||
} else {
|
||||
LOG.debug("could not find {} from {}", profileName, profile.toString());
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user