On 9/24/2018 9:28 AM, Michael Joyner wrote:
Is there an easy way to compare schemas?
When upgrading nodes, we are wanting to compare the "core" and
"automatically mapped" data types between our existing schema and the
new manage-schema available as part of the upgraded distrubtion.
There is no difference in the format between schema.xml with the Classic
schema factory and managed-schema with the new factory. The difference
is that managed-schema can be changed by Solr, and schema.xml could only
be changed externally to Solr.
And for the most part, the format for new versions is the same as the
format for old versions. At some point the <fields> and <types> tags
became optional - they are no longer required.
Because the basic format hasn't changed, if the two files are mostly
similar, you can simply diff the schema.xml in your older version with
the managed-schema in the newer version. It might be a good idea to use
the option for diff that ignores differences in whitespace. If the
files are substantially different in how they are laid out, then you
might need to manually compare them.
Thanks,
Shawn