Reduce redundant utPLSQL API calls
PhilippSalvisberg opened this issue · 2 comments
Example of the Problem
When the “Check availability of menu option” in the “Run utPLSQL test” tab of the preferences is checked, then the following statements are executed twice on a right-click of a schema/user node in the Database Navigator window:
BEGIN
? := ut.version;
END;
DECLARE
l_return VARCHAR2(1) := '0';
BEGIN
IF ut_runner.has_suites(?) THEN
l_return := '1';
END IF;
? := l_return;
END;
The reason is, that there are two menu options:
- Run utPLSQL test
- Code coverage...
Each menu item needs to be enabled or disabled. Therefore the SQL Developer framework calls update per menu item (action). This cannot be changed by this extension. However, the extension can control the executions of the SQL statements.
Enhancement Request
Provide a SQL result caching mechanism. Via a DIY-implementation or via some standard functionality like the JDBC client-side result cache.
Using the JDBC client-side result cache is the preferred way, even if it requires some database configuration and certain driver versions. If the configuration does not support client-side result cache, then it will still work, just without caching, which is acceptable.
- Client-Side Result Cache works with JDBC OCI driver since version 11.1 and with JDBC Thin driver since version 18.1 Feature List
- SQL Developer 19.2 comes with a version 18.3.0.0.0 of ojdbc8.jar
- See Client-Side Result Set Cache for configuration details
It's really nice to have. The overhead is small and not worth to increase complexity. Closing issue.