MODE-2287: Replace BASE64 decoder
Merge pull request #1247 from okulikov/MODE-2287

MODE-2287: Replace BASE64 decoder
MODE-2294: Prevent unnecessary serialization
Merge pull request #1248 from okulikov/MODE-2294

MODE-2294: Make server side classes serializable
MODE-2297 Corrected query engine to properly report mismatched set operation columns
MODE-2297 Additional fix for 'jcr:mixinTypes' index, plus more tests
MODE-2200 Corrected NPE

Corrected an NPE that occurs when attempting to determine if a binary value is no longer used, when the document store no longer has an entry for the binary's reference count document.
Merge pull request #1250 from rhauch/mode-2200

MODE-2200 Corrected NPE
Merge pull request #1249 from rhauch/mode-2297

MODE-2297 Corrected query engine to properly report mismatched set operation columns
MODE-2307 Corrected how subselects are used in dependent joins
MODE-2307 Indexes are now used when join conditions can be applied

Previously, index applicability only took into account constraints. So when an access query did not have any constraints (other than on jcr:primaryType or jcr:mixinTypes) then indexes were not considered, even though an index might apply to one of the selectors & properties on one side of the join condition.

With this change, it is now possible for the repository to try to apply indexes based upon constraints and/or join conditions. For example, an index on 'jcr:uuid' might apply to a SameNodeJoinCondition. Or, a property index might apply when an EquiJoinCondition involves that property.

Note that in these cases, join conditions have no literal values on which the index can filter its results, but it still can be used by returning all nodes in the index. This still might be significantly better than scanning the index.

It's even possible now that indexes might be applied based upon join constraints (additional constraints that apply to the join, and that cannot be pushed down to either side of the join).
Merge pull request #1251 from rhauch/mode-2307

MODE-2307 Corrected subqueries and variable substitution, and indexes may now be applied based on join conditions and join constraints
MODE-2297 Using pseudocolumns no longer is a warning

Using a pseudocolumn in a select used to result in a warning, but that is no longer the case. Also cleaned up the places that used pseudocolumns  by encapsulating all pseudocolumn info into a single class.
MODE-2297 Added test case that shows the functionality does work for query that was reported as a problem.
Merge pull request #1252 from rhauch/mode-2297

MODE-2297 Improved handling of warnings involving pseudocolumns, and added test to verify functionality
MODE-2297 Minor correction to previous change on pseudocolumns.
Merge pull request #1253 from rhauch/mode-2297

MODE-2297 Minor correction to previous change on pseudocolumns.
MODE-2297 Corrected getNodes() functionality

Changed the tests to always check the query via rows and, if there's only one selector in the query, also by nodes. Fix a problem when getting the nodes on some queries.
Merge pull request #1254 from rhauch/mode-2297

MODE-2297 Corrected getNodes() functionality
MODE-2309 Corrected reading and writing JSON files when escaped characters are used.

This fixes the backup and restore issue. Note that ModeShape uses BSON when storing nodes in Infinispan, so this
should not affect persistent storage in a cache store. ModeShape uses JSON for the file connector (extra properties)
and for the REST service; neither of these should be impacted negatively by this change, though like the backup
and restore this change should fix any as-of-yet unseen issues related to escaped characters.

Note that it is not possible to just update the Restore functionality, so with this change new backups will have
to be created. This change does need to be applied to the 3.x branch as well.