Skip to content

Commit

Permalink
Fixing KafkaInputFormat build failures.
Browse files Browse the repository at this point in the history
  • Loading branch information
harinirajendran committed Feb 23, 2022
1 parent 75c15a2 commit 5aa897e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public boolean isSplittable()
public InputEntityReader createReader(InputRowSchema inputRowSchema, InputEntity source, File temporaryDirectory)
{
KafkaRecordEntity record = (KafkaRecordEntity) source;
InputRowSchema newInputRowSchema = new InputRowSchema(dummyTimestampSpec, inputRowSchema.getDimensionsSpec(), inputRowSchema.getMetricNames());
InputRowSchema newInputRowSchema = new InputRowSchema(dummyTimestampSpec, inputRowSchema.getDimensionsSpec(), inputRowSchema.getColumnsFilter());
return new KafkaInputReader(
inputRowSchema,
record,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import com.fasterxml.jackson.databind.ObjectMapper;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Iterables;
import org.apache.druid.data.input.ColumnsFilter;
import org.apache.druid.data.input.InputEntityReader;
import org.apache.druid.data.input.InputRow;
import org.apache.druid.data.input.InputRowSchema;
Expand All @@ -48,7 +49,6 @@
import java.io.IOException;
import java.nio.charset.StandardCharsets;
import java.util.Arrays;
import java.util.Collections;

public class KafkaInputFormatTest
{
Expand Down Expand Up @@ -178,7 +178,7 @@ public void testWithHeaderKeyAndValue() throws IOException
"kafka.newheader.kafkapkc",
"kafka.newts.timestamp"
))),
Collections.emptyList()
ColumnsFilter.all()
),
inputEntity,
null
Expand Down Expand Up @@ -251,7 +251,7 @@ public void testWithOutKey() throws IOException
"kafka.newheader.kafkapkc",
"kafka.newts.timestamp"
))),
Collections.emptyList()
ColumnsFilter.all()
),
inputEntity,
null
Expand Down Expand Up @@ -323,7 +323,7 @@ public byte[] value()
"kafka.newheader.encoding",
"kafka.newheader.kafkapkc"
))),
Collections.emptyList()
ColumnsFilter.all()
),
inputEntity,
null
Expand Down Expand Up @@ -416,7 +416,7 @@ public void testWithOutKeyAndHeaderSpecs() throws IOException
"bar", "foo",
"kafka.newts.timestamp"
))),
Collections.emptyList()
ColumnsFilter.all()
),
inputEntity,
null
Expand Down

0 comments on commit 5aa897e

Please sign in to comment.