drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From paul-rogers <...@git.apache.org>
Subject [GitHub] drill pull request #823: DRILL-5459: Extend physical operator test framework...
Date Fri, 05 May 2017 23:24:37 GMT
Github user paul-rogers commented on a diff in the pull request:

    https://github.com/apache/drill/pull/823#discussion_r115103600
  
    --- Diff: exec/java-exec/src/test/java/org/apache/drill/exec/physical/unit/PhysicalOpUnitTestBase.java
---
    @@ -82,6 +81,8 @@
      * Look! Doesn't extend BaseTestQuery!!
      */
     public class PhysicalOpUnitTestBase extends ExecTest {
    +  public static long INIT_ALLOCATION = 10_000_000l;
    +  public static long MAX_ALLOCATION = 15_000_000L;
    --- End diff --
    
    Should we use the values already defined in `AbstractBase`? To do that, perhaps refactor
the code from:
    
    ```
    public abstract class AbstractBase implements PhysicalOperator{
      ...
      protected long initialAllocation = 1_000_000L;
      protected long maxAllocation = 10_000_000_000L;
    ```
    
    To:
    
    ```
    public abstract class AbstractBase implements PhysicalOperator{
      ...
      public static long INIT_ALLOCATION = 1_000_000L;
      public static long MAX_ALLOCATION = 10_000_000_000L;
      protected long initialAllocation = INIT_ALLOCATION;
      protected long maxAllocation = MAX_ALLOCATION;
    ```
    
    Actually, I think I did that in my much-delayed external sort PR for unit testing...


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message