Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions core/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ RUN \
mkdir -p /tmp/overlay/usr/libexec/ && \
touch /tmp/overlay/usr/libexec/grepconf.sh && \
chmod +x /tmp/overlay/usr/libexec/grepconf.sh && \
yum update -y && \
yum install --installroot /tmp/overlay --setopt install_weak_deps=false --nodocs -y \
dnf update -y && \
dnf install --installroot /tmp/overlay --setopt install_weak_deps=false --nodocs -y \
less \
libstdc++ `# required by snappy and duckdb` \
curl-minimal grep `# required by health-check` \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public class InternalResourceGroup
@GuardedBy("root")
private ResourceUsage cachedResourceUsage = new ResourceUsage(0, 0, 0);
@GuardedBy("root")
private long lastStartMillis;
private long lastStartNanos;
private final CounterStat timeBetweenStartsSec = new CounterStat();
private final CounterStat startedQueries = new CounterStat();

Expand Down Expand Up @@ -776,7 +776,7 @@ private void updateEligibility()
}
else {
parent.get().eligibleSubGroups.remove(this);
lastStartMillis = 0;
lastStartNanos = 0;
}
parent.get().updateEligibility();
}
Expand Down Expand Up @@ -970,11 +970,11 @@ private boolean internalStartNext()
boolean started = subGroup.internalStartNext();
checkState(started, "Eligible sub group had no queries to run");

long currentTime = System.currentTimeMillis();
if (lastStartMillis != 0) {
timeBetweenStartsSec.update(Math.max(0, (currentTime - lastStartMillis) / 1000));
long currentTime = System.nanoTime();
if (lastStartNanos != 0) {
timeBetweenStartsSec.update(Math.max(0, (currentTime - lastStartNanos) / 1_000_000));
}
lastStartMillis = currentTime;
lastStartNanos = currentTime;

descendantQueuedQueries--;
// Don't call updateEligibility here, as we're in a recursive call, and don't want to repeatedly update our ancestors.
Expand Down
Loading