It is not a memory leak. UCanAccess is consuming memory as part of its normal operation.
UCanAccess uses an HSQLDB "mirror" of the Access database to support SQL operations, and by default that mirror database is created in memory. Therefore if you connect to an Access database that has tables containing 30 MB of data then UCanAccess will use ~30 MB of memory to store the mirror database.
Appending ;memory=false
to the connection URL will tell UCanAccess to create the HSQLDB mirror database on disk instead of in memory. That will will reduce the memory requirements significantly but it will also take longer to establish the connection (i.e., create the mirror database).
UCanAccess also "mirrors" all of the tables that it finds in the specified database. So, if you are only interested in working with one particular table in a database named "main.accdb" then you can
- create a new Access database, e.g., "link.accdb"
- create a Linked Table in "link.accdb" that points to the actual table in "main.accdb", and then
- use UCanAccess to open "link.accdb".
Using the above procedure, UCanAccess only mirrors the one table.
There are several other options to control the mirroring behaviour of UCanAccess; see the UCanAccess website for details.