You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2022/11/08 20:52:00 UTC

[jira] [Commented] (NIFI-10744) Tests in TestScanHBase use non-deterministic HashMap

    [ https://issues.apache.org/jira/browse/NIFI-10744?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17630616#comment-17630616 ] 

ASF subversion and git services commented on NIFI-10744:
--------------------------------------------------------

Commit 889254a9dce63e189388c9921c0edcf605a2dadd in nifi's branch refs/heads/main from sopan98
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=889254a9dc ]

NIFI-10744 Used LinkedHashMap in TestScanHBase methods

This closes #6633

Signed-off-by: David Handermann <ex...@apache.org>


> Tests in TestScanHBase use non-deterministic HashMap 
> -----------------------------------------------------
>
>                 Key: NIFI-10744
>                 URL: https://issues.apache.org/jira/browse/NIFI-10744
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Extensions
>         Environment: Apache Maven 3.6.0;
> openjdk version "1.8.0_342";
> OpenJDK Runtime Environment (build 1.8.0_342-8u342-b07-0ubuntu1~20.04-b07);
> OpenJDK 64-Bit Server VM (build 25.342-b07, mixed mode);
>            Reporter: Sopan Phaltankar
>            Priority: Trivial
>             Fix For: 1.19.0
>
>         Attachments: org.apache.nifi.hbase.TestScanHBase.txt
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> {code:java}
> 1. org.apache.nifi.hbase.TestScanHBase#testScanToContentWithStringValues
> 2. org.apache.nifi.hbase.TestScanHBase#testScanToContentWithQualifierAndValueJSON{code}
> This is a flaky test, it can pass mvn test while but when run using the tool [NonDex|https://github.com/TestingResearchIllinois/NonDex], it fails. NonDex is a tool that will introduce non-determinism in certain java collections.
> The test shows below:
> {code:java}
> 1. org.apache.nifi.hbase.TestScanHBase.testScanToContentWithStringValues  
> Time elapsed: 0.267 s  <<< FAILURE!
> org.opentest4j.AssertionFailedError: 
> expected: <[{"row":"row1", "cells": [{"fam":"nifi","qual":"cq1","val":"val1","ts":123456789}, {"fam":"nifi","qual":"cq2","val":"val2","ts":123456789}]},
> {"row":"row2", "cells": [{"fam":"nifi","qual":"cq1","val":"val1","ts":123456789}, {"fam":"nifi","qual":"cq2","val":"val2","ts":123456789}]}]> but was: <[{"row":"row1", "cells": [{"fam":"nifi","qual":"cq2","val":"val2","ts":123456789}, {"fam":"nifi","qual":"cq1","val":"val1","ts":123456789}]},
> {"row":"row2", "cells": [{"fam":"nifi","qual":"cq1","val":"val1","ts":123456789}, {"fam":"nifi","qual":"cq2","val":"val2","ts":123456789}]}]>
> 2. org.apache.nifi.hbase.TestScanHBase#testScanToContentWithQualifierAndValueJSON
> Time elapsed: 0.019 s  <<< FAILURE!
> org.opentest4j.AssertionFailedError: expected: <[{"cq1":"val1", "cq2":"val2"}]> but was: <[{"cq2":"val2", "cq1":"val1"}]>{code}
> *Steps to reproduce the failure:*
>  # Run the following command in nifi:
>  # First, build the module:
> {noformat}
> mvn install -pl nifi-nar-bundles/nifi-hbase-bundle/nifi-hbase-processors -DskipTests -Drat.skip -am{noformat}
>  # Then run the test using [NonDex|https://github.com/TestingResearchIllinois/NonDex]
> {noformat}
> 1. mvn -pl nifi-nar-bundles/nifi-hbase-bundle/nifi-hbase-processors edu.illinois:nondex-maven-plugin:1.1.2:nondex -Dtest=org.apache.nifi.hbase.TestScanHBase#testScanToContentWithStringValues
> 2. mvn -pl nifi-nar-bundles/nifi-hbase-bundle/nifi-hbase-processors edu.illinois:nondex-maven-plugin:1.1.2:nondex -Dtest=org.apache.nifi.hbase.TestScanHBase#testScanToContentWithQualifierAndValueJSON{noformat}
>  
> The result will be saved under the module folder in .nondex



--
This message was sent by Atlassian Jira
(v8.20.10#820010)