FireBird/LibreOffice: fb_config/pkg-config, thread-safety, eager caching

Lionel Elie Mamane lionel at
Thu Jul 18 19:40:47 PDT 2013


My "git pull" today brought the firebird work in. Cool!

1) I notice that Debian has neither fb_config, nor fbembed.pc; are
   these part of the upstream build (and then it is a bug in Debian
   that they are not in the packages)? Do other distros have them?

2) This is a bit scary in the Debian package description of

    Contrary to libfbclient, libfbembed is not thread-safe.

   Taking a quick look at e.g. OResultSet::ensureDataAvailable,
   it is mutexed, but (as far as I understand) with a *different*
   mutex for each instance (for each object). So this does not keep
   multiple ResultSets from making parallel calls to non-thread-safe
   libfbembed from different threads.

3) You seem to have duplicated
   in connectivity/source/drivers/firebird/propertyids.[hc]xx?

   With the _same_ include guard?

4) OResultSet::m_sqlData: the driver caches the *whole* resultset? Oh
   my... And not only that, it eagerly fetches the *whole* resultset?

   That will *not* scale.

   Does Firebird 3 support scrollable cursors?

   I'm not actually sure any LibreOffice code really requires
   scrollable cursors; it seems to me that when it detects that the
   driver / database does not support that, it makes a *new* query
   with "WHERE primary_key=VALUE" each time it wants to "go back"
   (this happens in dbaccess/source/core/api/KeySet.cxx and

   If FireBird can't support previous() et al, it could just throw an
   SQLError when they are called?

   If the LibreOffice detection logic is b0rken, we should fix
   *that* rather than inefficiently fake in the driver capabilities
   that the database does not have.

(I'm away until Sunday evening.)


More information about the LibreOffice mailing list