impala-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Marcel Kornacker (Code Review)" <>
Subject [Impala-ASF-CR] IMPALA-5137: Support Kudu UNIXTIME MICROS as Impala TIMESTAMP
Date Sat, 06 May 2017 17:47:40 GMT
Marcel Kornacker has posted comments on this change.

Change subject: IMPALA-5137: Support Kudu UNIXTIME_MICROS as Impala TIMESTAMP

Patch Set 6:

File be/src/exec/

Line 150:   row_format_flags |= kudu::client::KuduScanner::PAD_UNIXTIME_MICROS_TO_16_BYTES;
why start with no_flags instead of setting this directly in l149?

Line 201:       if (slot->type().type != TYPE_TIMESTAMP) continue;
pull out timestamp slots into a separate vector (which you set up in prepare), no need to
check every column on every row whether it's a timestamp.
File be/src/exec/

Line 111: Status WriteKuduRowValue(kudu::KuduPartialRow* row, int col, PrimitiveType type,
fix signature (output params go at end).

also, is "row value" a kudu term (that means a column value)? to me this sounds like it's
writing a whole row, which isn't the case.
File be/src/runtime/

Line 19: #include "runtime/timestamp-value.inline.h"
remove this, unless you're calling these functions here (which doesn't appear to be the case).
by including this you avoided linker errors, which would have forced you to include the .inline.h
in the referencing .cc files.

Line 98:     if (UNLIKELY(nullptr == localtime_r(&utc, &temp))) {
fix order
File be/src/runtime/timestamp-value.h:

Line 193:   /// Interpret 'this' as a timestamp in UTC and convert to unix time in microseconds.
> I'd prefer to keep this consistent with the ToUnixTime() code (see l224), i
i don't know when that's going to happen. at least leave a todo in the implementation to revisit.
File be/src/runtime/timestamp-value.h:

Line 25
are there other includes you can remove?
File be/src/runtime/timestamp-value.inline.h:

Line 34: bool TimestampValue::UtcToUnixTime(time_t* unix_time) const {
you need to prefix all of these with inline.

what you have right now removes the inlining and potentially degrades performance. (you need
to include the .inline.h file in every .cc file that includes the .h file right now and calls
the inlined functions.)
File testdata/workloads/functional-query/queries/QueryTest/kudu_insert.test:

Line 6:    ts timestamp)
> Done

To view, visit
To unsubscribe, visit

Gerrit-MessageType: comment
Gerrit-Change-Id: Iae6ccfffb79118a9036fb2227dba3a55356c896d
Gerrit-PatchSet: 6
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-Owner: Matthew Jacobs <>
Gerrit-Reviewer: Dan Hecht <>
Gerrit-Reviewer: David Ribeiro Alves <>
Gerrit-Reviewer: Lars Volker <>
Gerrit-Reviewer: Marcel Kornacker <>
Gerrit-Reviewer: Matthew Jacobs <>
Gerrit-Reviewer: Thomas Tauber-Marshall <>
Gerrit-HasComments: Yes

View raw message