You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2020/10/09 23:52:51 UTC

[GitHub] [incubator-pinot] mcvsubbu opened a new pull request #6129: Issue #4854 Framework for adding compatibility tests

mcvsubbu opened a new pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129


   This PR includes a basic framework for us to build compatibility tests across releases
   The actual tests and a lot of code is yet to be written.
   
   The framekwork is set up so that we can run operations during a cluster upgrade, and
   detect incompatibility across releases. The value of the tests will be in the operations
   we choose to test during upgrades
   
   Configuration is done via YAML, and some sample yaml files and skinny classes have been
   provided.
   
   ## Description
   Add a description of your PR here.
   A good description should include pointers to an issue or design document, etc.
   ## Upgrade Notes
   Does this PR prevent a zero down-time upgrade? (Assume upgrade order: Controller, Broker, Server, Minion)
   * [ ] Yes (Please label as **<code>backward-incompat</code>**, and complete the section below on Release Notes)
   
   Does this PR fix a zero-downtime upgrade introduced earlier?
   * [ ] Yes (Please label this as **<code>backward-incompat</code>**, and complete the section below on Release Notes)
   
   Does this PR otherwise need attention when creating release notes? Things to consider:
   - New configuration options
   - Deprecation of configurations
   - Signature changes to public methods/interfaces
   - New plugins added or old plugins removed
   * [ ] Yes (Please label this PR as **<code>release-notes</code>** and complete the section on Release Notes)
   ## Release Notes
   If you have tagged this as either backward-incompat or release-notes,
   you MUST add text here that you would like to see appear in release notes of the
   next release.
   
   If you have a series of commits adding or enabling a feature, then
   add this section only in final commit that marks the feature completed.
   Refer to earlier release notes to see examples of text
   
   ## Documentation
   If you have introduced a new feature or configuration, please add it to the documentation as well.
   See https://docs.pinot.apache.org/developers/developers-and-contributors/update-document
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] mcvsubbu commented on a change in pull request #6129: Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
mcvsubbu commented on a change in pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#discussion_r508036095



##########
File path: pinot-tools/src/main/java/org/apache/pinot/tools/compat/SegmentOp.java
##########
@@ -0,0 +1,95 @@
+/**
+ * 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.pinot.tools.compat;
+
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+
+
+/**
+ * Segment Operations:
+ * UPLOAD:
+ *   Generates a segment for a table from the data in the input file.
+ *   Uploads the segment, and verifies that the segments appear in externalview
+ * DELETE:
+ *   Deletes the segment from the table.
+ *
+ * TODO:
+ *  - Maybe segment names can be auto-generated if the name is "AUTO".
+ *  - We can add segmentGeneration config file as an option also
+ *  - We can consider supporting different readers, starting with csv. Will help in easily scanning the data.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+public class SegmentOp extends BaseOp {
+  public enum Op {
+    UPLOAD,
+    DELETE
+  }
+
+  private Op _op;
+  private String _inputDataFileName;
+  private String _segmentName;
+  private String _tableConfigFileName;
+
+  public SegmentOp() {
+    super(OpType.SEGMENT_OP);
+  }
+
+  public Op getOp() {
+    return _op;
+  }
+
+  public void setOp(Op op) {
+    _op = op;
+  }
+
+  public String getInputDataFileName() {
+    return _inputDataFileName;
+  }
+
+  public void setInputDataFileName(String inputDataFileName) {
+    _inputDataFileName = inputDataFileName;
+  }
+
+  public String getSegmentName() {
+    return _segmentName;
+  }
+
+  public void setSegmentName(String segmentName) {
+    _segmentName = segmentName;
+  }
+
+  public String getTableConfigFileName() {
+    return _tableConfigFileName;
+  }
+
+  public void setTableConfigFileName(String tableConfigFileName) {
+    _tableConfigFileName = tableConfigFileName;
+  }
+
+  @Override
+  boolean runOp() {
+    switch(_op) {
+      case UPLOAD:
+        System.out.println("Generating segment " + _segmentName + " from " + _inputDataFileName + " and uploading to " +

Review comment:
       We will not need it. I put it there so we can see what is being run.  Once we add more logic here, we can remove these things




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] codecov-io commented on pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#issuecomment-706455576


   # [Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=h1) Report
   > Merging [#6129](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=desc) into [master](https://codecov.io/gh/apache/incubator-pinot/commit/1beaab59b73f26c4e35f3b9bc856b03806cddf5a?el=desc) will **decrease** coverage by `2.43%`.
   > The diff coverage is `37.80%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-pinot/pull/6129/graphs/tree.svg?width=650&height=150&src=pr&token=4ibza2ugkz)](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master    #6129      +/-   ##
   ==========================================
   - Coverage   66.44%   64.01%   -2.44%     
   ==========================================
     Files        1075     1223     +148     
     Lines       54773    57744    +2971     
     Branches     8168     8522     +354     
   ==========================================
   + Hits        36396    36962     +566     
   - Misses      15700    18098    +2398     
   - Partials     2677     2684       +7     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | #unittests | `64.01% <37.80%> (?)` | |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [...e/pinot/broker/api/resources/PinotBrokerDebug.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtYnJva2VyL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9icm9rZXIvYXBpL3Jlc291cmNlcy9QaW5vdEJyb2tlckRlYnVnLmphdmE=) | `0.00% <0.00%> (-79.32%)` | :arrow_down: |
   | [...ot/broker/broker/AllowAllAccessControlFactory.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtYnJva2VyL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9icm9rZXIvYnJva2VyL0FsbG93QWxsQWNjZXNzQ29udHJvbEZhY3RvcnkuamF2YQ==) | `71.42% <ø> (-28.58%)` | :arrow_down: |
   | [.../helix/BrokerUserDefinedMessageHandlerFactory.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtYnJva2VyL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9icm9rZXIvYnJva2VyL2hlbGl4L0Jyb2tlclVzZXJEZWZpbmVkTWVzc2FnZUhhbmRsZXJGYWN0b3J5LmphdmE=) | `33.96% <0.00%> (-32.71%)` | :arrow_down: |
   | [...ava/org/apache/pinot/client/AbstractResultSet.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L0Fic3RyYWN0UmVzdWx0U2V0LmphdmE=) | `53.33% <0.00%> (-3.81%)` | :arrow_down: |
   | [.../main/java/org/apache/pinot/client/Connection.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L0Nvbm5lY3Rpb24uamF2YQ==) | `35.55% <0.00%> (-13.29%)` | :arrow_down: |
   | [...inot/client/JsonAsyncHttpPinotClientTransport.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L0pzb25Bc3luY0h0dHBQaW5vdENsaWVudFRyYW5zcG9ydC5qYXZh) | `10.90% <0.00%> (-51.10%)` | :arrow_down: |
   | [.../org/apache/pinot/client/ResultTableResultSet.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L1Jlc3VsdFRhYmxlUmVzdWx0U2V0LmphdmE=) | `0.00% <0.00%> (-34.29%)` | :arrow_down: |
   | [...not/common/assignment/InstancePartitionsUtils.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vYXNzaWdubWVudC9JbnN0YW5jZVBhcnRpdGlvbnNVdGlscy5qYXZh) | `73.80% <ø> (+0.63%)` | :arrow_up: |
   | [.../apache/pinot/common/exception/QueryException.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZXhjZXB0aW9uL1F1ZXJ5RXhjZXB0aW9uLmphdmE=) | `90.27% <ø> (+5.55%)` | :arrow_up: |
   | [...pinot/common/function/AggregationFunctionType.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZnVuY3Rpb24vQWdncmVnYXRpb25GdW5jdGlvblR5cGUuamF2YQ==) | `98.27% <ø> (-1.73%)` | :arrow_down: |
   | ... and [1044 more](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=footer). Last update [2379791...a251ee7](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] mcvsubbu commented on pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
mcvsubbu commented on pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#issuecomment-708066401


   we should remove all sleeps. They were added by the earlier committer. I will do that. 
   We also need to check the status of each compat-tester callout.
   Lastly, I think this whole thing needs to move into pinot-integration-tests, so that we can re-use all the code in there in the compat test operations. What do you say?


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] codecov-io edited a comment on pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#issuecomment-706455576


   # [Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=h1) Report
   > Merging [#6129](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=desc) into [master](https://codecov.io/gh/apache/incubator-pinot/commit/1beaab59b73f26c4e35f3b9bc856b03806cddf5a?el=desc) will **increase** coverage by `6.41%`.
   > The diff coverage is `60.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-pinot/pull/6129/graphs/tree.svg?width=650&height=150&src=pr&token=4ibza2ugkz)](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master    #6129      +/-   ##
   ==========================================
   + Coverage   66.44%   72.86%   +6.41%     
   ==========================================
     Files        1075     1223     +148     
     Lines       54773    57744    +2971     
     Branches     8168     8522     +354     
   ==========================================
   + Hits        36396    42075    +5679     
   + Misses      15700    12912    -2788     
   - Partials     2677     2757      +80     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | #integration | `45.44% <48.40%> (?)` | |
   | #unittests | `64.01% <37.80%> (?)` | |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [...ot/broker/broker/AllowAllAccessControlFactory.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtYnJva2VyL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9icm9rZXIvYnJva2VyL0FsbG93QWxsQWNjZXNzQ29udHJvbEZhY3RvcnkuamF2YQ==) | `100.00% <ø> (ø)` | |
   | [.../helix/BrokerUserDefinedMessageHandlerFactory.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtYnJva2VyL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9icm9rZXIvYnJva2VyL2hlbGl4L0Jyb2tlclVzZXJEZWZpbmVkTWVzc2FnZUhhbmRsZXJGYWN0b3J5LmphdmE=) | `52.83% <0.00%> (-13.84%)` | :arrow_down: |
   | [...ava/org/apache/pinot/client/AbstractResultSet.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L0Fic3RyYWN0UmVzdWx0U2V0LmphdmE=) | `53.33% <0.00%> (-3.81%)` | :arrow_down: |
   | [.../main/java/org/apache/pinot/client/Connection.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L0Nvbm5lY3Rpb24uamF2YQ==) | `44.44% <0.00%> (-4.40%)` | :arrow_down: |
   | [.../org/apache/pinot/client/ResultTableResultSet.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY2xpZW50cy9waW5vdC1qYXZhLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY2xpZW50L1Jlc3VsdFRhYmxlUmVzdWx0U2V0LmphdmE=) | `24.00% <0.00%> (-10.29%)` | :arrow_down: |
   | [...not/common/assignment/InstancePartitionsUtils.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vYXNzaWdubWVudC9JbnN0YW5jZVBhcnRpdGlvbnNVdGlscy5qYXZh) | `78.57% <ø> (+5.40%)` | :arrow_up: |
   | [.../apache/pinot/common/exception/QueryException.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZXhjZXB0aW9uL1F1ZXJ5RXhjZXB0aW9uLmphdmE=) | `90.27% <ø> (+5.55%)` | :arrow_up: |
   | [...pinot/common/function/AggregationFunctionType.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZnVuY3Rpb24vQWdncmVnYXRpb25GdW5jdGlvblR5cGUuamF2YQ==) | `98.27% <ø> (-1.73%)` | :arrow_down: |
   | [.../pinot/common/function/DateTimePatternHandler.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZnVuY3Rpb24vRGF0ZVRpbWVQYXR0ZXJuSGFuZGxlci5qYXZh) | `83.33% <ø> (ø)` | |
   | [...ot/common/function/FunctionDefinitionRegistry.java](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vZnVuY3Rpb24vRnVuY3Rpb25EZWZpbml0aW9uUmVnaXN0cnkuamF2YQ==) | `88.88% <ø> (+44.44%)` | :arrow_up: |
   | ... and [970 more](https://codecov.io/gh/apache/incubator-pinot/pull/6129/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=footer). Last update [2379791...a251ee7](https://codecov.io/gh/apache/incubator-pinot/pull/6129?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] mcvsubbu merged pull request #6129: Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
mcvsubbu merged pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] sajjad-moradi commented on a change in pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
sajjad-moradi commented on a change in pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#discussion_r503462097



##########
File path: compatibility-verifier/compCheck.sh
##########
@@ -157,20 +181,27 @@ fi
 
 # Setup initial cluster with olderCommit and do rolling upgrade
 startServices "$oldTargetDir"
-sleep 20
+#$COMPAT_TESTER pre-controller-upgrade.yaml
 stopService controller "$oldTargetDir"
 startService controller "$newTargetDir"
+#$COMPAT_TESTER pre-broker-upgrade.yaml
 stopService broker "$oldTargetDir"
 startService broker "$newTargetDir"
+#$COMPAT_TESTER pre-server-upgrade.yaml
 stopService server "$oldTargetDir"
 startService server "$newTargetDir"
-sleep 20
+#$COMPAT_TESTER post-server-upgrade.yaml
+
+# Upgrade complated, now do a rollback
 stopService controller "$newTargetDir"
 startService controller "$oldTargetDir"
+#$COMPAT_TESTER post-server-rollback.yaml
 stopService broker "$newTargetDir"
 startService broker "$oldTargetDir"
+#$COMPAT_TESTER post-broker-rollback.yaml
 stopService server "$newTargetDir"
 startService server "$oldTargetDir"
+#$COMPAT_TESTER post-controller-rollback.yaml
 sleep 20

Review comment:
       If you decide to have(or remove) previous `sleep`s, please do the same for this one as well?




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] mcvsubbu commented on a change in pull request #6129: Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
mcvsubbu commented on a change in pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#discussion_r508034672



##########
File path: compatibility-verifier/compCheck.sh
##########
@@ -157,20 +181,27 @@ fi
 
 # Setup initial cluster with olderCommit and do rolling upgrade
 startServices "$oldTargetDir"
-sleep 20
+#$COMPAT_TESTER pre-controller-upgrade.yaml

Review comment:
       Removed the sleep. It should not be needed.
   Replacing with a function call may be fine, but we still have to check the return from that function. I have added the status check now. Let it be like this for now, until we add more meat to it




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] sajjad-moradi commented on a change in pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
sajjad-moradi commented on a change in pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#discussion_r503461466



##########
File path: compatibility-verifier/compCheck.sh
##########
@@ -157,20 +181,27 @@ fi
 
 # Setup initial cluster with olderCommit and do rolling upgrade
 startServices "$oldTargetDir"
-sleep 20
+#$COMPAT_TESTER pre-controller-upgrade.yaml

Review comment:
       I'm not sure why 20 seconds sleep was chosen in the first place, but does replacing it with running compat_tester mean the tests are going to take 20 seconds?
   Also maybe it reads better if $COMPAT_TESTER is replaced with a function call, something like runCompatiblityTests, which is more consistent with startService, startService, ... here.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


[GitHub] [incubator-pinot] jackjlli commented on a change in pull request #6129: Issue #4854 Framework for adding compatibility tests

Posted by GitBox <gi...@apache.org>.
jackjlli commented on a change in pull request #6129:
URL: https://github.com/apache/incubator-pinot/pull/6129#discussion_r504300900



##########
File path: pinot-tools/src/main/java/org/apache/pinot/tools/compat/SegmentOp.java
##########
@@ -0,0 +1,95 @@
+/**
+ * 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.pinot.tools.compat;
+
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+
+
+/**
+ * Segment Operations:
+ * UPLOAD:
+ *   Generates a segment for a table from the data in the input file.
+ *   Uploads the segment, and verifies that the segments appear in externalview
+ * DELETE:
+ *   Deletes the segment from the table.
+ *
+ * TODO:
+ *  - Maybe segment names can be auto-generated if the name is "AUTO".
+ *  - We can add segmentGeneration config file as an option also
+ *  - We can consider supporting different readers, starting with csv. Will help in easily scanning the data.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+public class SegmentOp extends BaseOp {
+  public enum Op {
+    UPLOAD,
+    DELETE
+  }
+
+  private Op _op;
+  private String _inputDataFileName;
+  private String _segmentName;
+  private String _tableConfigFileName;
+
+  public SegmentOp() {
+    super(OpType.SEGMENT_OP);
+  }
+
+  public Op getOp() {
+    return _op;
+  }
+
+  public void setOp(Op op) {
+    _op = op;
+  }
+
+  public String getInputDataFileName() {
+    return _inputDataFileName;
+  }
+
+  public void setInputDataFileName(String inputDataFileName) {
+    _inputDataFileName = inputDataFileName;
+  }
+
+  public String getSegmentName() {
+    return _segmentName;
+  }
+
+  public void setSegmentName(String segmentName) {
+    _segmentName = segmentName;
+  }
+
+  public String getTableConfigFileName() {
+    return _tableConfigFileName;
+  }
+
+  public void setTableConfigFileName(String tableConfigFileName) {
+    _tableConfigFileName = tableConfigFileName;
+  }
+
+  @Override
+  boolean runOp() {
+    switch(_op) {
+      case UPLOAD:
+        System.out.println("Generating segment " + _segmentName + " from " + _inputDataFileName + " and uploading to " +

Review comment:
       We may not need to print it out in the console?




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org