[jira] [Commented] (SOLR-13664) SolrTestCaseJ4.deleteCore() does not delete/clean dataDir

2019-08-04 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/SOLR-13664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16899695#comment-16899695
 ] 

ASF subversion and git services commented on SOLR-13664:


Commit ab470a6564b1184c2d77892131f56a9912f7d8c6 in lucene-solr's branch 
refs/heads/SOLR-13105-visual from Chris M. Hostetter
[ https://gitbox.apache.org/repos/asf?p=lucene-solr.git;h=ab470a6 ]

SOLR-13664: Fixed SolrTestCaseJ4.deleteCore() to properly reset the dataDir 
used by initCore()


>  SolrTestCaseJ4.deleteCore() does not delete/clean dataDir
> --
>
> Key: SOLR-13664
> URL: https://issues.apache.org/jira/browse/SOLR-13664
> Project: Solr
>  Issue Type: Bug
>  Security Level: Public(Default Security Level. Issues are Public) 
>Reporter: Hoss Man
>Assignee: Hoss Man
>Priority: Major
> Fix For: master (9.0), 8.3
>
> Attachments: SOLR-13664.patch, SOLR-13664.patch, SOLR-13664.patch, 
> SOLR-13664.patch
>
>
> Prior to Solr 8.3, the javadocs for {{SolrTestCaseJ4.deleteCore()}} said that 
> that method would delete the dataDir used by {{initCore()}} in spite of that 
> method not actaully doing anything to clean up the dataDir for a very long 
> time (exactly when the bug was introduced is not known)
> For that reason, in most solr versions up to and including 8.2, tests that 
> called combinations of {{initCore()}} / {{deleteCore()}} within a single test 
> class would see the data from a previous core polluting the data of a newly 
> introduced core.
> As part of this jira, this bug was fixed, by udpating {{deleteCore()}} to 
> "reset" the value of the {{initCoreDataDir}} variable to null, so that it 
> can/will be re-initialized on the next call to either {{initCore()}} or the 
> lower level {{createCore()}}. 
> Existing tests that refer to the {{initCoreDataDir}} directly (either before, 
> or during the lifecycle of an active core managed via {{initCore()}} / 
> {{deleteCore()}} ) may encounter {{NullPointerExceptions}} on upgrading to 
> Solr 8.3 as a result of this bug fix.  These tests are encouraged to use the 
> new helper method {{initAndGetDataDir()}} in place of directly refering to 
> the (now deprecated) {{initCoreDataDir}} variable directly.
> Any existing tests that refer to the {{initCoreDataDir}} directly *after* 
> calling {{deleteCore()}} with the intention of inspecting the index contents 
> after shutdown, will need to be modified to preserved the rsults of calling 
> {{initAndGetDataDir()}} into a new variable for such introspection – the 
> actual contents of the directory will not be removed until the full ifecycle 
> of the test class is complete (see {{LuceneTestCase.createTempDir()}})
>  



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

-
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org



[jira] [Commented] (SOLR-13664) SolrTestCaseJ4.deleteCore() does not delete/clean dataDir

2019-08-01 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/SOLR-13664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16898255#comment-16898255
 ] 

ASF subversion and git services commented on SOLR-13664:


Commit 89af2ec30428c37e4a5ec6d30b9e32968b686bee in lucene-solr's branch 
refs/heads/branch_8x from Chris M. Hostetter
[ https://gitbox.apache.org/repos/asf?p=lucene-solr.git;h=89af2ec ]

SOLR-13664: Fixed SolrTestCaseJ4.deleteCore() to properly reset the dataDir 
used by initCore()

(cherry picked from commit ab470a6564b1184c2d77892131f56a9912f7d8c6)


>  SolrTestCaseJ4.deleteCore() does not delete/clean dataDir
> --
>
> Key: SOLR-13664
> URL: https://issues.apache.org/jira/browse/SOLR-13664
> Project: Solr
>  Issue Type: Bug
>  Security Level: Public(Default Security Level. Issues are Public) 
>Reporter: Hoss Man
>Assignee: Hoss Man
>Priority: Major
> Attachments: SOLR-13664.patch, SOLR-13664.patch, SOLR-13664.patch, 
> SOLR-13664.patch
>
>
> In spite of what it's javadocs say, {{SolrTestCaseJ4.deleteCore()}} does 
> nothing to delete the dataDir used by the TestHarness
> The git history is a bit murky, so i'm not entirely certain when this stoped 
> working, but I suspect it happened as part of the overall cleanup regarding 
> test temp dirs and the use of {{LuceneTestCase.createTempDir(...) -> 
> TestRuleTemporaryFilesCleanup}}
> While this is not problematic in many test classes, where a single 
> {{initCore(...) is called in a {{@BeforeClass}} and the test then re-uses 
> that SolrCore for all test methods and relies on {{@AfterClass 
> SolrTestCaseJ4.teardownTestCases()}} to call {{deleteCore()}}, it's 
> problematic in test classes where {{deleteCore()}} is explicitly called in an 
> {{@After}} method to ensure a unique core (w/unique dataDir) is used for each 
> test method.
> (there are currently about 61 tests that call {{deleteCore()}} directly)



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

-
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org



[jira] [Commented] (SOLR-13664) SolrTestCaseJ4.deleteCore() does not delete/clean dataDir

2019-08-01 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/SOLR-13664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16898180#comment-16898180
 ] 

ASF subversion and git services commented on SOLR-13664:


Commit ab470a6564b1184c2d77892131f56a9912f7d8c6 in lucene-solr's branch 
refs/heads/master from Chris M. Hostetter
[ https://gitbox.apache.org/repos/asf?p=lucene-solr.git;h=ab470a6 ]

SOLR-13664: Fixed SolrTestCaseJ4.deleteCore() to properly reset the dataDir 
used by initCore()


>  SolrTestCaseJ4.deleteCore() does not delete/clean dataDir
> --
>
> Key: SOLR-13664
> URL: https://issues.apache.org/jira/browse/SOLR-13664
> Project: Solr
>  Issue Type: Bug
>  Security Level: Public(Default Security Level. Issues are Public) 
>Reporter: Hoss Man
>Assignee: Hoss Man
>Priority: Major
> Attachments: SOLR-13664.patch, SOLR-13664.patch, SOLR-13664.patch, 
> SOLR-13664.patch
>
>
> In spite of what it's javadocs say, {{SolrTestCaseJ4.deleteCore()}} does 
> nothing to delete the dataDir used by the TestHarness
> The git history is a bit murky, so i'm not entirely certain when this stoped 
> working, but I suspect it happened as part of the overall cleanup regarding 
> test temp dirs and the use of {{LuceneTestCase.createTempDir(...) -> 
> TestRuleTemporaryFilesCleanup}}
> While this is not problematic in many test classes, where a single 
> {{initCore(...) is called in a {{@BeforeClass}} and the test then re-uses 
> that SolrCore for all test methods and relies on {{@AfterClass 
> SolrTestCaseJ4.teardownTestCases()}} to call {{deleteCore()}}, it's 
> problematic in test classes where {{deleteCore()}} is explicitly called in an 
> {{@After}} method to ensure a unique core (w/unique dataDir) is used for each 
> test method.
> (there are currently about 61 tests that call {{deleteCore()}} directly)



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

-
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org



[jira] [Commented] (SOLR-13664) SolrTestCaseJ4.deleteCore() does not delete/clean dataDir

2019-07-31 Thread Lucene/Solr QA (JIRA)


[ 
https://issues.apache.org/jira/browse/SOLR-13664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16897756#comment-16897756
 ] 

Lucene/Solr QA commented on SOLR-13664:
---

| (/) *{color:green}+1 overall{color}* |
\\
\\
|| Vote || Subsystem || Runtime || Comment ||
|| || || || {color:brown} Prechecks {color} ||
| {color:green}+1{color} | {color:green} test4tests {color} | {color:green}  0m 
 0s{color} | {color:green} The patch appears to include 14 new or modified test 
files. {color} |
|| || || || {color:brown} master Compile Tests {color} ||
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  2m 
48s{color} | {color:green} master passed {color} |
|| || || || {color:brown} Patch Compile Tests {color} ||
| {color:green}+1{color} | {color:green} compile {color} | {color:green}  2m 
38s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} javac {color} | {color:green}  2m 
38s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} Release audit (RAT) {color} | 
{color:green}  1m 44s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} Check forbidden APIs {color} | 
{color:green}  1m 31s{color} | {color:green} the patch passed {color} |
| {color:green}+1{color} | {color:green} Validate source patterns {color} | 
{color:green}  1m 31s{color} | {color:green} the patch passed {color} |
|| || || || {color:brown} Other Tests {color} ||
| {color:green}+1{color} | {color:green} unit {color} | {color:green}  0m 
54s{color} | {color:green} dataimporthandler in the patch passed. {color} |
| {color:green}+1{color} | {color:green} unit {color} | {color:green} 31m  
6s{color} | {color:green} core in the patch passed. {color} |
| {color:green}+1{color} | {color:green} unit {color} | {color:green}  0m 
29s{color} | {color:green} test-framework in the patch passed. {color} |
| {color:black}{color} | {color:black} {color} | {color:black} 41m 15s{color} | 
{color:black} {color} |
\\
\\
|| Subsystem || Report/Notes ||
| JIRA Issue | SOLR-13664 |
| JIRA Patch URL | 
https://issues.apache.org/jira/secure/attachment/12976377/SOLR-13664.patch |
| Optional Tests |  compile  javac  unit  ratsources  checkforbiddenapis  
validatesourcepatterns  |
| uname | Linux lucene1-us-west 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 
10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | ant |
| Personality | 
/home/jenkins/jenkins-slave/workspace/PreCommit-SOLR-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
 |
| git revision | master / 15c2fd673a |
| ant | version: Apache Ant(TM) version 1.10.5 compiled on March 28 2019 |
| Default Java | LTS |
|  Test Results | 
https://builds.apache.org/job/PreCommit-SOLR-Build/518/testReport/ |
| modules | C: solr/contrib/dataimporthandler solr/core solr/test-framework U: 
solr |
| Console output | 
https://builds.apache.org/job/PreCommit-SOLR-Build/518/console |
| Powered by | Apache Yetus 0.7.0   http://yetus.apache.org |


This message was automatically generated.



>  SolrTestCaseJ4.deleteCore() does not delete/clean dataDir
> --
>
> Key: SOLR-13664
> URL: https://issues.apache.org/jira/browse/SOLR-13664
> Project: Solr
>  Issue Type: Bug
>  Security Level: Public(Default Security Level. Issues are Public) 
>Reporter: Hoss Man
>Assignee: Hoss Man
>Priority: Major
> Attachments: SOLR-13664.patch, SOLR-13664.patch, SOLR-13664.patch, 
> SOLR-13664.patch
>
>
> In spite of what it's javadocs say, {{SolrTestCaseJ4.deleteCore()}} does 
> nothing to delete the dataDir used by the TestHarness
> The git history is a bit murky, so i'm not entirely certain when this stoped 
> working, but I suspect it happened as part of the overall cleanup regarding 
> test temp dirs and the use of {{LuceneTestCase.createTempDir(...) -> 
> TestRuleTemporaryFilesCleanup}}
> While this is not problematic in many test classes, where a single 
> {{initCore(...) is called in a {{@BeforeClass}} and the test then re-uses 
> that SolrCore for all test methods and relies on {{@AfterClass 
> SolrTestCaseJ4.teardownTestCases()}} to call {{deleteCore()}}, it's 
> problematic in test classes where {{deleteCore()}} is explicitly called in an 
> {{@After}} method to ensure a unique core (w/unique dataDir) is used for each 
> test method.
> (there are currently about 61 tests that call {{deleteCore()}} directly)



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

-
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org