Skip to content

Support for Data Change Notification Callbacks (sqlite3_update_hook) #711

@vlasky

Description

@vlasky

Hi,

It would be really great if we could have node-sqlite3 support Data Change Notification Callbacks, which are implemented in the SQLite C interface by the sqlite3_update_hook() function.

This would provide the ability to register a callback function in NodeJS that will be called whenever a row is updated, inserted or deleted in a SQLite rowid table.

My intention is for this exposed functionality to be used to implement a reactive SQLite database driver for Meteor, to be used in real-time applications that use Meteor's publication & subscription functionality. That is, a change to a row in the SQLite database will generate an event that will make the server publish the modified data to a connected client.

At the moment, such drivers have been written for MongoDB, MySQL and PostgreSQL. SQLite would be a relatively easy and perfect addition once the Data Change Notification Callback is exposed in NodeJS.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions