Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Currently, it is necessary for the user to specify the database vendor, database version and driver in order to instantiate a driver definition. Although, it is somewhat desirable to organize the drivers by vendor, it is unnecessarily complicated to organize the drivers on a per version basis especially since the version can be discovered when a connection is made to the server. The purpose of this proposal is to remove the requirement of specifying versions from the driver definition UI and optionally from the driver definition. Note that this change is backward compatible.
1) Database Recognizers
A database recognizer is a class that is registered using the databaseRecognition extension point in the org.eclipse.datatools.connectivity.sqm.core plug-in. The class implements a method that takes a connection and then returns a DatabaseDefinition if it recognizes the server.
2) Connection Factory Modifications
The connection factory will be modified as follows: a) A DatabaseDefinition based on the vendor and version specified in the driver definition will be associated with the connection. (This is the current behavior.) b) If no vendor and version is specified in the driver definition or the DatabaseDefinition specified cannot be instantiated then the generic JDBC database definition will be associated with the connection. c) After connection, the database recognizers will be queried. If they recognize the server then that DatabaseDefinition will used by the connection.
Specifying the vendor and version, even when database recognizers are available is a way to specify the default DatabaseDefinition for when a version is unrecognized such as when a new version of the database is released but the database recognizers have not been updated to recognize it yet. Once database recognizers are available for a specific vendor, then the versions can be removed from the driver definition UI for that specific vendor.