Skip to content

Commit

Permalink
Retire the EasyOutOfMemory test category now that we have swap space.
Browse files Browse the repository at this point in the history
The EasyOutOfMemory test category is a clever workaround to run Drill in the memory constrained CI
environment provided by Github Actions that has served us well but it is no longer needed now that
we set up swap space in the CI workflow. We can now retire it for simpler and faster CI testing.
  • Loading branch information
jnturton committed Dec 31, 2023
1 parent 75b1f2a commit 1a4b050
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 48 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,24 +54,21 @@ jobs:
# added to the Runner and memory hungry tests are run separately.
run: |
sudo sh -c "
fallocate -l 2G /tmp/swapfile
fallocate -l 4G /tmp/swapfile
chmod 0600 /tmp/swapfile
mkswap /tmp/swapfile
swapon /tmp/swapfile
"
- name: Build and test
run: |
mvn -P${{ matrix.profile }} install --batch-mode --no-transfer-progress \
-DexcludedGroups=org.apache.drill.categories.EasyOutOfMemory \
-Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
- name: Test Specific Categories # EasyOutOfMemory
run: |
mvn -P${{ matrix.profile }} test -pl org.apache.drill.exec:drill-java-exec \
-Dgroups=org.apache.drill.categories.EasyOutOfMemory \
-Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.httpconnectionManager.ttlSeconds=120
- name: Remove swap space
run : |
sudo swapoff /tmp/swapfile
sudo sh -c "
swapoff /tmp/swapfile
rm /tmp/swapfile
"
checkstyle_protobuf:
name: Run checkstyle and generate protobufs
runs-on: ubuntu-latest
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
* <li>{@link org.apache.drill.categories.UnlikelyTest}: These tests represent corner cases, specific bug fixes, or tests for pieces of code that are unlikely to be changed.
* These are disabled by default</li>
* <li>{@link org.apache.drill.categories.FlakyTest}: A category for tests that intermittently fail.</li>
* <li>{@link org.apache.drill.categories.EasyOutOfMemory}: Inherited class FlakyTest and allow the CI tool uses a new JVM to test the unit.</li>
* </ul>
* </p>
* <p>
Expand Down Expand Up @@ -65,4 +64,3 @@
* </p>
*/
package org.apache.drill.categories;

Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
import java.util.Map;

import org.apache.drill.PlanTestBase;
import org.apache.drill.categories.EasyOutOfMemory;
import org.apache.drill.categories.HiveStorageTest;
import org.apache.drill.categories.SlowTest;
import org.apache.drill.common.exceptions.UserRemoteException;
Expand All @@ -41,7 +40,7 @@
import org.junit.experimental.categories.Category;
import org.junit.rules.ExpectedException;

@Category({SlowTest.class, HiveStorageTest.class, EasyOutOfMemory.class})
@Category({SlowTest.class, HiveStorageTest.class})
public class TestHiveDrillNativeParquetReader extends HiveTestBase {

@BeforeClass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
import java.util.Set;
import java.util.concurrent.Semaphore;

import org.apache.drill.categories.EasyOutOfMemory;
import org.apache.drill.categories.SlowTest;
import org.apache.drill.common.exceptions.UserException;
import org.apache.drill.exec.ExecConstants;
Expand Down Expand Up @@ -56,7 +55,7 @@
* unstable from running a lot of queries concurrently -- it's not about
* any particular order of execution. We ignore the results.
*/
@Category({SlowTest.class, EasyOutOfMemory.class})
@Category({SlowTest.class})
public class TestTpchDistributedConcurrent extends ClusterTest {
private static final Logger logger = LoggerFactory.getLogger(TestTpchDistributedConcurrent.class);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import org.apache.drill.exec.record.RecordBatchLoader;
import org.apache.drill.exec.record.VectorWrapper;
import org.apache.drill.exec.util.Text;
import org.apache.drill.categories.EasyOutOfMemory;
import org.apache.drill.categories.OperatorTest;
import org.apache.drill.categories.PlannerTest;
import org.apache.drill.categories.SqlFunctionTest;
Expand Down Expand Up @@ -69,7 +68,7 @@
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;

@Category({ SqlFunctionTest.class, OperatorTest.class, PlannerTest.class, EasyOutOfMemory.class })
@Category({ SqlFunctionTest.class, OperatorTest.class, PlannerTest.class })
public class TestAggregateFunctions extends ClusterTest {

@Rule
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@

import ch.qos.logback.classic.Level;
import org.apache.commons.math3.util.Pair;
import org.apache.drill.categories.EasyOutOfMemory;
import org.apache.drill.categories.FlakyTest;
import org.apache.drill.exec.client.DrillClient;
import org.apache.drill.exec.physical.impl.partitionsender.PartitionSenderRootExec;
Expand Down Expand Up @@ -106,7 +105,7 @@
* <li>specify Level.DEBUG for CURRENT_LOG_LEVEL</li>
* <li>compare trace output for successful test case and failed</li>
*/
@Category({ SlowTest.class, FlakyTest.class, EasyOutOfMemory.class })
@Category({ SlowTest.class, FlakyTest.class })
public class TestDrillbitResilience extends ClusterTest {
private static final Logger logger = org.slf4j.LoggerFactory.getLogger(TestDrillbitResilience.class);
protected static LogFixture logFixture;
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,8 @@
<javax.validation.api>2.0.1.Final</javax.validation.api>
<asm.version>9.5</asm.version>
<excludedGroups />
<memoryMb>2560</memoryMb>
<directMemoryMb>2560</directMemoryMb>
<memoryMb>3072</memoryMb>
<directMemoryMb>3072</directMemoryMb>
<rat.skip>true</rat.skip>
<license.skip>true</license.skip>
<docker.repository>apache/drill</docker.repository>
Expand Down

0 comments on commit 1a4b050

Please sign in to comment.