Today I took the task of updating a .NET application that I’ve had since sometime around 2013.
I created this application with a few people at the time of .NET 4.0 and Solr 4.10, with its corresponding SolrNet.
Today I moved it to Solr 8.4 and with .NET 4.7.
There are a few interesting changes that you need to take into account, which I may expand at some point. But just in case, if you are in the same scenario, here are some upgrade tips for you to consider:
#1 When you move from Solr 4.10 (and older versions) to 8.4, there are some changes to take into account
- The default field is now _text_ and not text
- Some types may have changed
- Default now is managed-schema, not schema.xml
- Some changes are required in solrconfig.xml
So, what I did is downloaded, installed and started a Solr 8.4.
Then I created a core
bin\solr.cmd create -c <name>
Next, I configured Solr so that I do not use schemaless mode. Use this link for more info: Switching from Managed Schema to Manually Edited schema.xml
Don’t forget that besides changing the
ClassicIndexSchemaFactory, you also need to disable schema guessing, which allows unknown fields to be added to the schema during indexing.
Then I indexed some data. This didn’t change much.
Now, a fun one. I have a custom request handler, which wasn’t working. Oh dear, I forgot for a second that the qt parameter no longer works unless you explicitly configure Solr to work.
This is straightforward. Comment out your select request handler, and add the handleSelect attribute to true in the RequestDispatcher node. Like this:
<requestDispatcher handleSelect="false" >
Also, comment out the select requestHandler.
Restart Solr and happy searching!