1
0
mirror of https://github.com/node-red/node-red-nodes.git synced 2023-10-10 13:36:58 +02:00
Commit Graph

42 Commits

Author SHA1 Message Date
Dave Conway-Jones
a7b9380f25
fix mysql node error scope 2022-07-22 10:18:37 +01:00
Dave Conway-Jones
0b3b918528
mysql faster/tidier closing of pool if never connected. 2022-07-11 14:39:16 +01:00
Ben Hardill
87e50f2b76
Mysql fix (#886)
* Check if there is a connection before release

Fixes #885
2022-02-21 20:08:33 +00:00
Dave Conway-Jones
fea47843d7
Change mysql library to mysql2 as it is more maintained and support latest mysql authention (#862)
* Use mysql2 lib

* fix pool on acquire event cause MaxListenersExceededWarning (#854)

before: every query need to register pool on acquire event to specify queryFormat based on payload type
will cause MaxListenersExceededWarning

after:
from https://www.npmjs.com/package/mysql#pooling-connections

pool.query is a shortcut for pool.getConnection() -> connection.query() -> connection.release()

so use pool.getConnection and then
set queryFormat before query method be called

Co-authored-by: Dave Conway-Jones <dceejay@users.noreply.github.com>

* fix mysql require

* Add decimalNumbers flag true to mysql beta

* mysql remove old Timeout option, clarify timezone options

* add mysqlConnectionLimit settings option.

Co-authored-by: saknarak <saknarak@gmail.com>
2022-01-05 10:56:14 +00:00
Wataru Sato
b95ae5dc63
Add Japanese translations for mysql Node (#841) 2021-10-27 13:42:27 +01:00
Nicolas Glassey
b18c32f037
Fix #811 (#847) 2021-10-21 15:08:23 +01:00
Dave Conway-Jones
799eee3873
Mysql - Only call done if it exists. 2021-06-19 14:47:44 +01:00
Eric Dum
d8ba11ccdf
query by pool instead of using the connection directly (#806) 2021-05-18 09:09:33 +01:00
Dave Conway-Jones
b37d215659
mysql - revert trying to fixup RowDataPackets introduced in 0.1.8 2021-05-10 08:53:08 +01:00
Dave Conway-Jones
fdfdbb17b7
Fix mysql multiple return queries type
to close #797
2021-04-23 22:23:16 +01:00
Dave Conway-Jones
2c5cc5f70c
Fixup mysql node done calls 2021-04-08 17:07:23 +01:00
Daniele
040bf24c4b
node-red-node-mysq add done() callback (#793)
This fix adds the done() callback when the query has been executed.
2021-04-08 09:11:59 +01:00
Dave Conway-Jones
c1c82a623e
mysql, actually make the if else do something sensible... 2021-03-21 17:30:14 +00:00
Dave Conway-Jones
a194c56acb
refix copy results array 2021-03-21 10:10:45 +00:00
Dave Conway-Jones
868d641064
Update 68-mysql.js 2021-03-16 08:24:06 +00:00
Dave Conway-Jones
fabd3753b4
undo mysql change again 2021-03-14 17:54:31 +00:00
Dave Conway-Jones
c2613cfeb0
mysql test before releasing connection 2021-03-14 09:05:23 +00:00
Dave Conway-Jones
9e7701dc33
Update 68-mysql.js 2021-03-13 13:59:00 +00:00
Dave Conway-Jones
6095723308
fix mysql array handling 2021-03-12 21:01:54 +00:00
Dave Conway-Jones
4641d10beb
mysql: add charset option (defaults as-is to old UTF8) 2020-04-18 18:03:59 +01:00
Marco
0351441075
MySQL allows to pass named parameters as object (#565)
* add check isobj

* added example to readme.md

* edit if Syntax

* add Documentation link to readme.md

* fixed Syntax and edit readme.md
2020-04-10 22:53:17 +01:00
Dave Conway-Jones
fa8e174d0b
mysql - slightly overzealous closing of connections - causes crash. backed off slightly 2020-04-05 12:35:15 +01:00
Dave Conway-Jones
705dd1ffc1
mysql - ensure connection released back to pool more often
and try to ensure status is shown more correctly on error.
2020-04-05 11:44:27 +01:00
Dave Conway-Jones
f2e28e715f
fix mysql node OkPacket handling
to close #583
2019-10-16 11:24:33 +01:00
Dave Conway-Jones
d153034232
slow down status updates from mysql to better handle fast updates
to close #515
2019-02-01 22:15:22 +00:00
Dave Conway-Jones
5a07f29ebd remove invalid error parameter from mysql callback 2017-03-17 13:45:47 +00:00
Dave Conway-Jones
c6d214fcfe mysql set to try to keep server connection alive 2017-02-26 10:18:07 +00:00
Dave Conway-Jones
fe1a96d67d tidy up mysql some more
remove listeners on close and update status on partial deploy
2016-11-27 19:21:57 +00:00
Dave Conway-Jones
738eada16b Update Mysql Node status reporting 2016-11-27 17:03:03 +00:00
Dave Conway-Jones
a7247e898a Update licenses and packages for all nodes 2016-11-06 20:26:19 +00:00
Dave Conway-Jones
afec508980 Catch "not connected" to database in Mysql node
also to close #172 - as multiple statements now also supported
2016-09-14 22:44:53 +01:00
Dave Conway-Jones
69b471b0f1 let mysql node allow multiple statements 2016-07-20 20:11:50 +01:00
Dave Conway-Jones
e1b02c90dd let mysql report errors to catch node 2015-11-01 15:04:42 +00:00
dceejay
5982da8495 Add bind capability to sqlite and mysql nodes
Thanks to Scott Penrose for the patch.
2015-01-26 10:57:13 +00:00
Nick O'Leary
b7a1193d32 Update mysql to use credentials system
Fixes #86
2015-01-19 09:46:29 +00:00
Dave C-J
dac2c7e778 Update MySQL node - fa icons, add timezone, make npm installable 2014-07-04 17:26:20 +01:00
Dave C-J
ebf950d818 Update node-red-nodes sample, analysis, storage and time nodes to use strict and pass jshint scan 2014-06-28 23:37:19 +01:00
Dave C-J
3d78a93958 update mysql node to use RED.httpAdmin 2014-02-23 18:32:49 +00:00
Nicholas O'Leary
34b3c635f3 Lazily connect mysql node
If there is a mysqldatabase config node, but no actual users of it,
we don't need to connect to the database.
2013-11-22 20:49:31 +00:00
Nicholas O'Leary
39b849ded8 Move Mysql node credentials to credentials file
We must not store passwords in the regular flows file as this gets exchanged with the browser regularly and would leave things vulnerable.

The credentials mechanism is there to all a write-once-don't-need-to-read approach that allows the runtime access to the credentials without exposing them to the browser.
2013-11-22 20:34:57 +00:00
Dave C-J
39da31eaaa Added proper database reconnects... and more error handling, that should help address Issue #87 in main node-red Issue list. 2013-11-22 10:24:08 +00:00
Dave C-J
5e67f41114 Add rawserial, mpd, mysql and swearfilter nodes. 2013-11-03 21:29:20 +00:00