Skip to content

Releases: overextended/oxmysql

v2.9.1

06 Mar 03:00
Compare
Choose a tag to compare

(Experimental) New transaction usage

This function is not yet fully supported and will receive breaking changes in future updates - this export and information is provided only for feedback and testing purposes.

Sample usage of the new transaction export.

CreateThread(function()
    local success = exports.oxmysql:experimentalTransaction(function(query)
        local a = query('INSERT INTO users (identifier) VALUES (?)', { 'someid' })
        
        if not a then return false end -- if a is undefined, return false and rollback
        
        -- local b = query('SELEC * FROM users WHERE id = ? LIMIT 1', { a.insertId }) -- syntax error leads to rollback

        -- Wait(30000) -- connection will timeout and rollback transaction

        -- error('sad') -- any errors will rollback

        -- no return, or any truthy value, will commit the transaction and release the connection
    end)

    print(success)
end)

Bug Fixes

  • db: incorrect error handling when no callback is defined (Linden)

Code Refactoring

  • db/startTransaction: remove execute from cb (Linden)
  • db/startTransaction: add 30s timeout to transactions (Linden)
  • db/startTransaction: include query and values in errors (Linden)

Commits

v2.9.0

29 Feb 22:20
Compare
Choose a tag to compare

Features

  • db: experimental transaction export (Linden)

Bug Fixes

  • logger: strip lua scheduler errors (Linden)
  • logger: potential error on error handling (Linden)

Code Refactoring

  • db/connection: set and get active connections (Linden)
  • db/startTransaction: use internal query functions (Linden)

Continuous Integration

  • release: update checkout action (Linden)
  • release: push updates to repo (Linden)
  • release: set repo ref to main (Linden)

Commits

  • 0ede55d: Create FUNDING.yml (Linden)

v2.8.0

02 Feb 06:04
Compare
Choose a tag to compare

Features

  • provide additional compatibility exports (Linden)
  • logger: add logStorage size limit (Linden)

Code Refactoring

  • logger: handle error event in error logger (Linden)
  • logger: non-debug query profiling (Linden)
  • update esbuild and build process (Linden)

Continuous Integration

  • release: update commit action (Linden)
  • release: correct commit message (Linden)

v2.7.7

04 Dec 23:30
Compare
Choose a tag to compare

Bug Fixes

  • db/connection: don't establish connection from getPoolConnection (Linden)

Code Refactoring

  • db/connection: tweak waitForConnection logic (Linden)
  • db: loop createConnectionPool until success (Linden)

v2.7.6

15 Nov 14:46
Compare
Choose a tag to compare

Bug Fixes

Code Refactoring

  • database: move pool and connection variables (Linden)

v2.7.5

13 Sep 06:42
Compare
Choose a tag to compare

Bug Fixes

  • update: leftover console.log (Linden)
  • rename printError function (Linden)
  • lib/lua: show stacktrace when safeArgs throws error (Linden)
  • db/rawExecute: don't unpack responses for rawExecute (Linden)
  • utils/parseTransaction: parse arguments for query array (Linden)
  • ci: remove Lua definitions (Linden)
  • ci: update lib path (Linden)

Code Refactoring

  • lib: remove Lua type definitions (Linden)

Chores

v2.7.4

08 Aug 18:36
Compare
Choose a tag to compare

Bug Fixes

  • database/rawTransaction: don't error on transaction failure (Linden)

Chores

v2.7.3

28 Jul 07:50
Compare
Choose a tag to compare

Bug Fixes

  • config: don't set connection info with falsey key (Linden)
  • config: respect connection-string flags (Linden)
  • logger: check player ace when fetching resource data (Linden)
  • database: handle profiles for >100 statements in batch queries (Linden)
  • config: export convertNamedPlaceholders (Linden)
  • utils/parseTransaction: properly handle arrays of queries (Linden)

Code Refactoring

  • database: use mysql2/promise (Linden)
  • database: query profiling (Linden)
  • minor tweaks and cleanup (Linden)
  • update: improve version checking (Linden)
  • web: increase query time precision (Linden)
  • database/rawTransaction: per-query profiling (Linden)
  • database/rawExecute: split batched query logs (Linden)
  • logger: add profileBatchStatements (Linden)
  • logger: only enable profiling with debugging (Linden)
  • database: output db version in connection message (Linden)
  • logger: output db version in debug/warning logs (Linden)
  • database: general code review/cleanup (Linden)
  • type improvements (Linden)
  • logger: more consistent error output (Linden)
  • utils: setCallback (Linden)
  • database: use setCallback (Linden)
  • improve error handling (Linden)

Chores

v2.7.2

06 Jul 02:57
Compare
Choose a tag to compare

Bug Fixes

  • utils/parseExecute: only set undefined parameters to null (Linden)

Code Refactoring

  • utils/parseExecute: allow other methods through prepare calls (Linden)

v2.7.1

20 Jun 22:03
Compare
Choose a tag to compare

Bug Fixes

  • lib/lua: missing rawExecute.await (Linden)