mirror of https://github.com/apache/lucene.git
SOLR-6897: Throw fatal error if nrtMode is present in solrconfig on 6.0. Added note to upgrade section.
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1649816 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
258f3b152e
commit
75f6dd52e4
|
@ -40,6 +40,9 @@ Upgrading from Solr 5.x
|
|||
* The deprecated SolrServer and subclasses have been removed, use SolrClient
|
||||
instead.
|
||||
|
||||
* The deprecated <nrtMode> configuration in solrconfig.xml has been removed.
|
||||
Please remove it from solrconfig.xml.
|
||||
|
||||
Detailed Change List
|
||||
----------------------
|
||||
|
||||
|
|
|
@ -195,7 +195,7 @@ public class SolrConfig extends Config implements MapSerializable{
|
|||
}
|
||||
assertWarnOrFail("The <nrtMode> config has been discontinued and NRT mode is always used by Solr." +
|
||||
" This config will be removed in future versions.", getNode(indexConfigPrefix + "/nrtMode", false) == null,
|
||||
false
|
||||
true
|
||||
);
|
||||
|
||||
// Parse indexConfig section, using mainIndex as backup in case old config is used
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
<?xml version="1.0" ?>
|
||||
|
||||
<!--
|
||||
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.
|
||||
-->
|
||||
|
||||
<config>
|
||||
|
||||
<luceneMatchVersion>${tests.luceneMatchVersion:LATEST}</luceneMatchVersion>
|
||||
|
||||
<xi:include href="solrconfig.snippet.randomindexconfig.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
|
||||
|
||||
<directoryFactory name="DirectoryFactory" class="NRTCachingDirectoryFactory"/>
|
||||
|
||||
<!-- BEGIN: BAD -->
|
||||
<indexConfig>
|
||||
<nrtMode>false</nrtMode>
|
||||
</indexConfig>
|
||||
<!-- END: BAD -->
|
||||
|
||||
|
||||
</config>
|
|
@ -27,6 +27,10 @@ public class TestBadConfig extends AbstractBadConfigTestBase {
|
|||
assertConfigs("bad_solrconfig.xml","schema.xml","unset.sys.property");
|
||||
}
|
||||
|
||||
public void testNRTModeProperty() throws Exception {
|
||||
assertConfigs("bad-solrconfig-nrtmode.xml","schema.xml", "nrtMode");
|
||||
}
|
||||
|
||||
public void testMultipleDirectoryFactories() throws Exception {
|
||||
assertConfigs("bad-solrconfig-multiple-dirfactory.xml", "schema12.xml",
|
||||
"directoryFactory");
|
||||
|
|
Loading…
Reference in New Issue