FrankChen021 commented on code in PR #19592: URL: https://github.com/apache/druid/pull/19592#discussion_r3427982104
########## extensions-contrib/druid-deltalake-extensions/src/test/java/org/apache/druid/delta/input/LargeRowGroupDeltaTable.java: ########## @@ -0,0 +1,54 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.druid.delta.input; + +import com.google.common.collect.ImmutableList; +import org.apache.druid.data.input.ColumnsFilter; +import org.apache.druid.data.input.InputRowSchema; +import org.apache.druid.data.input.impl.DimensionsSpec; +import org.apache.druid.data.input.impl.LongDimensionSchema; +import org.apache.druid.data.input.impl.StringDimensionSchema; +import org.apache.druid.data.input.impl.TimestampSpec; + +/** + * Descriptor for a Delta table with 2 Parquet files × 2000 rows = 4000 rows total. + * + * Each file has more than 1024 rows, ensuring the Delta kernel reads more than one + * batch per file. Used as a regression test for GH-18606 where + * {@link DeltaInputSourceReader} only returned the first 1024 rows per file. + * + * Generated by src/test/resources/create_delta_table.py (large-row-group-table). + */ +public class LargeRowGroupDeltaTable +{ + public static final String DELTA_TABLE_PATH = + "src/test/resources/large-row-group-table"; + + public static final int EXPECTED_ROW_COUNT = 4000; + + public static final InputRowSchema SCHEMA = new InputRowSchema( + new TimestampSpec("id", "posix", null), + new DimensionsSpec(ImmutableList.of( + new LongDimensionSchema("id"), + new StringDimensionSchema("name") + )), + ColumnsFilter.all() + ); +} Review Comment: [P1] Add the missing final newline This new Java file does not end with a newline; its last byte is the closing brace. Druid's Checkstyle configuration enables `NewlineAtEndOfFile`, so this should fail style/CI until a trailing newline is added. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
