If you are already using Solr 6.5, Solr 6.6 should not present any major problems. However, you should review the CHANGES.txt
file found in your Solr package for changes and updates that may effect your existing implementation. Detailed steps for upgrading a Solr cluster can be found in the appendix: Upgrading a Solr Cluster.
Upgrading from 6.5.x
-
Solr contribs map-reduce, morphlines-core and morphlines-cell have been removed.
-
JSON Facet API now uses hyper-log-log for numBuckets cardinality calculation and calculates cardinality before filtering buckets by any mincount greater than 1.
-
ZooKeeper dependency has been upgraded from 3.4.6 to 3.4.10.
Upgrading from earlier 6.x versions
-
If you use historical dates, specifically on or before the year 1582, you should re-index after upgrading to this version.
-
If you use the JSON Facet API (json.facet) with
method=stream
, you must now setsort='index asc'
to get the streaming behavior; otherwise it won’t stream. Reminder: "method" is a hint that doesn’t change defaults of other parameters. -
If you use the JSON Facet API (json.facet) to facet on a numeric field and if you use
mincount=0
or if you set the prefix, then you will now get an error as these options are incompatible with numeric faceting. -
Solr’s logging verbosity at the INFO level has been greatly reduced, and you may need to update the log configs to use the DEBUG level to see all the logging messages you used to see at INFO level before.
-
We are no longer backing up
solr.log
andsolr_gc.log
files in date-stamped copies forever. If you relied on thesolr_log_<date>
orsolr_gc_log_<date>
being in the logs folder that will no longer be the case. See the section Configuring Logging for details on how log rotation works as of Solr 6.3. -
The create/deleteCollection methods on MiniSolrCloudCluster have been deprecated. Clients should instead use the CollectionAdminRequest API. In addition,
MiniSolrCloudCluster#uploadConfigDir(File, String)
has been deprecated in favour of#uploadConfigSet(Path, String)
. -
The
bin/solr.in.sh
(bin/solr.in.cmd
on Windows) is now completely commented by default. Previously, this wasn’t so, which had the effect of masking existing environment variables. -
The
_version_
field is no longer indexed and is now defined withindexed=false
by default, because the field has DocValues enabled. -
The
/export
handler has been changed so it no longer returns zero (0) for numeric fields that are not in the original document. One consequence of this change is that you must be aware that some tuples will not have values if there were none in the original document. -
Metrics-related classes in
org.apache.solr.util.stats
have been removed in favor of the Dropwizard metrics library. Any custom plugins using these classes should be changed to use the equivalent classes from the metrics library. As part of this, the following changes were made to the output of Overseer Status API:-
The "totalTime" metric has been removed because it is no longer supported.
-
The metrics "75thPctlRequestTime", "95thPctlRequestTime", "99thPctlRequestTime" and "999thPctlRequestTime" in Overseer Status API have been renamed to "75thPcRequestTime", "95thPcRequestTime" and so on for consistency with stats output in other parts of Solr.
-
The metrics "avgRequestsPerMinute", "5minRateRequestsPerMinute" and "15minRateRequestsPerMinute" have been replaced by corresponding per-second rates viz. "avgRequestsPerSecond", "5minRateRequestsPerSecond" and "15minRateRequestsPerSecond" for consistency with stats output in other parts of Solr.
-
-
A new highlighter named UnifiedHighlighter has been added. You are encouraged to try out the UnifiedHighlighter by setting
hl.method=unified
and report feedback. It might become the default in 7.0. It’s more efficient/faster than the other highlighters, especially compared to the original Highlighter. That said, some options aren’t supported yet. It will get more features in time, especially with your input. See HighlightParams.java for a listing of highlight parameters annotated with which highlighters use them.hl.useFastVectorHighlighter
is now considered deprecated in lieu ofhl.method=fastVector
. -
The
maxWarmingSearchers
parameter now defaults to 1, and more importantly commits will now block if this limit is exceeded instead of throwing an exception (a good thing). Consequently there is no longer a risk in overlapping commits. Nonetheless users should continue to avoid excessive committing. Users are advised to remove any pre-existing maxWarmingSearchers entries from their solrconfig.xml files. -
The Complex Phrase query parser now supports leading wildcards. Beware of its possible heaviness, users are encouraged to use ReversedWildcardFilter in index time analysis.
-
The JMX metric "avgTimePerRequest" (and the corresponding metric in the metrics API for each handler) used to be a simple non-decaying average based on total cumulative time and the number of requests. New Codahale Metrics implementation applies exponential decay to this value, which heavily biases the average towards the last 5 minutes.
-
Index-time boosts are now deprecated. As a replacement, index-time scoring factors should be indexed in a separate field and combined with the query score using a function query. These boosts will be removed in Solr 7.0.
-
Parallel SQL now uses Apache Calcite as its SQL framework. As part of this change the default aggregation mode has been changed to facet rather than map_reduce. There have also been changes to the SQL aggregate response and some SQL syntax changes. Consult the Parallel SQL Interface documentation for full details.
Upgrading from 5.5.x
-
The deprecated
SolrServer
and subclasses have been removed, useSolrClient
instead. -
The deprecated
<nrtMode>
configuration insolrconfig.xml
has been removed. Please remove it fromsolrconfig.xml
. -
SolrClient.shutdown()
has been removed, useSolrClient.close()
instead. -
The deprecated
zkCredientialsProvider
element insolrcloud
section ofsolr.xml
is now removed. Use the correct spelling (zkCredentialsProvider
) instead. -
Internal/expert -
ResultContext
was significantly changed and expanded to allow for multiple full query results (DocLists
) per Solr request.TransformContext
was rendered redundant and was removed. See SOLR-7957 for details. -
Several changes have been made regarding the "
Similarity
" used in Solr, in order to provide better default behavior for new users. There are 3 key impacts of these changes on existing users who upgrade:-
DefaultSimilarityFactory
has been removed. If you currently haveDefaultSimilarityFactory
explicitly referenced in yourschema.xml
, edit your config to use the functionally identicalClassicSimilarityFactory
. See SOLR-8239 for more details. -
The implicit default Similarity used when no
<similarity/>
is configured inschema.xml
has been changed toSchemaSimilarityFactory
. Users who wish to preserve back-compatible behavior should either explicitly configureClassicSimilarityFactory
, or ensure that theluceneMatchVersion
for the collection is less then 6.0. See SOLR-8270 + SOLR-8271 for details. -
SchemaSimilarityFactory
has been modified to useBM25Similarity
as the default forfieldTypes
that do not explicitly declare a Similarity. The legacy behavior of usingClassicSimilarity
as the default will occur if theluceneMatchVersion
for the collection is less then 6.0, or the ‘defaultSimFromFieldType’ configuration option may be used to specify any default of your choosing. See SOLR-8261 + SOLR-8329 for more details.
-
-
If your
solrconfig.xml
file doesn’t explicitly mention theschemaFactory
to use then Solr will choose theManagedIndexSchemaFactory
by default. Previously it would have chosenClassicIndexSchemaFactory
. This means that the Schema APIs (/<collection>/schema
) are enabled and the schema is mutable. When Solr starts yourschema.xml
file will be renamed tomanaged-schema
. If you want to retain the old behaviour then please ensure that thesolrconfig.xml
explicitly uses theClassicIndexSchemaFactory
or yourluceneMatchVersion
in thesolrconfig.xml
is less than 6.0. See the Schema Factory Definition in SolrConfig section for more details -
SolrIndexSearcher.QueryCommand
andQueryResult
were moved to their own classes. If you reference them in your code, you should import them under o.a.s.search (or use your IDE’s "Organize Imports"). -
The '
useParams
' attribute specified in request handler cannot be overridden from request params. See SOLR-8698 for more details. -
When requesting stats in date fields, "sum" is now returned as a double value instead of a date. See SOLR-8671 for more details.
-
The deprecated GET methods for schema are now accessible through the bulk API. These methods now accept fewer request parameters, and output less information. See SOLR-8736 for more details. Some of the removed functionality will likely be restored in a future version of Solr - see SOLR-8992.
-
In the past, Solr guaranteed that retrieval of multi-valued fields would preserve the order of values. Because values may now be retrieved from column-stored fields (
docValues="true"
), in conjunction with the fact that DocValues do not currently preserve order, means that users should setuseDocValuesAsStored="false"
to prevent future optimizations from using the column-stored values over the row-stored values when fields have bothstored="true"
anddocValues="true"
. -
Formatted date-times from Solr have some differences. If the year is more than 4 digits, there is a leading '+'. When there is a non-zero number of milliseconds, it is padded with zeros to 3 digits. Negative year (BC) dates are now possible. Parsing: It is now an error to supply a portion of the date out of its, range, like 67 seconds.
-
SolrJ no longer includes
DateUtil
. If for some reason you need to format or parse dates, simply useInstant.format()
andInstant.parse()
. -
If you are using spatial4j, please upgrade to 0.6 and edit your
spatialContextFactory
to replacecom.spatial4j.core
withorg.locationtech.spatial4j
.
Upgrading from Older Versions of Solr
Users upgrading from older versions are strongly encouraged to consult CHANGES.txt
for the details of all changes since the version they are upgrading from.
A summary of the significant changes between Solr 5.x and Solr 6.0 can be found in the Major Changes from Solr 5 to Solr 6 section.