Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Manage utPLSQL core compatiblity explicitely #46

Closed
PhilippSalvisberg opened this issue Oct 25, 2018 · 2 comments
Closed

Manage utPLSQL core compatiblity explicitely #46

PhilippSalvisberg opened this issue Oct 25, 2018 · 2 comments
Assignees

Comments

@PhilippSalvisberg
Copy link
Member

PhilippSalvisberg commented Oct 25, 2018

In version v0.6 a part of the extension depends on functionality introduced with utPLSQL version 3.0.4.

It is expected that an official API will be introduced in a future utPLSQL version (>3.1.2) to replace the functionality provided by the UT_ANNOTATION_MANAGER package.

The following version numbers are used in released versions of utPLSQL:

Date Name Value of UT.VERSION
2017-01-18 v3.0.0.0-Alpha1
2017-05-15 v3.0.0-beta utPLSQL - Version v3.0.0.708-beta
2017-05-18 utPLSQL v3.0.0 utPLSQL - Version v3.0.0
2017-06-14 utPLSQL v3.0.1 utPLSQL - Version v3.0.1.798
2017-07-18 utPLSQL v3.0.2 utPLSQL - Version v3.0.2.938
2017-08-30 utPLSQL v3.0.3 v3.0.3.1266
2017-11-03 utPLSQL v3.0.4 v3.0.4.1372
2018-04-25 utPLSQL v3.1.0 v3.1.0.1849-develop
2018-04-29 utPLSQL v3.1.1 v3.1.1.1868
2018-07-22 utPLSQL v3.1.2 v3.1.2.2134
... ... ...

Instead of querying for the existence of UT_ANNOTATION_MANAGER the return value of the function UT.VERSION should be used to determine if a certain feature is available or not. Versions of utPLSQL without a UT.VERSION function are not supported (e.g. v3.0.0.0-Alpha1).

Features are disabled if not available in a version (context menus, oddgen generators) and a error message is written to the error log (visible in the logging pane). If not feasible an error message is shown when executing an enabled but not supported feature.

@pesse
Copy link
Member

pesse commented Oct 26, 2018

We already have a solution for "Optional Features" in java-API:
https://github.com/utPLSQL/utPLSQL-java-api/blob/develop/src/main/java/org/utplsql/api/compatibility/OptionalFeatures.java

Would be easy to add ANNOTATION_MANAGER which requires 3.0.4.1372 or higher.
You can also use the Version-Object (https://github.com/utPLSQL/utPLSQL-java-api/blob/develop/src/main/java/org/utplsql/api/Version.java) for easier Version comparison/handling.
They can either be instantiated with a String or you can use DatabaseInformation.getUtPlsqlFrameworkVersion() to get the Version-Object from given Connection.

@PhilippSalvisberg
Copy link
Member Author

I think we should provide make a wrapper of UT_ANNOTATION_MANAGER part of the the core API first. Providing internals should not become part of the Java API.

I'd like to get rid of the use of UT_ANNOTATION_MANAGER a.s.a.p. Once an adequate functionality is available in the core, I will adapt this extension accordingly. Then I will decide if I base the solution on the Java API (additional dependency) or the PL/SQL API.

However, the getUtplsqlFrameworkVersion() is nice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants