-
-
Notifications
You must be signed in to change notification settings - Fork 623
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add "interpreting" parser #2099
base: master
Are you sure you want to change the base?
Conversation
Coverage reportThe coverage rate is The branch rate is
|
const Types = require('../constants/types.js'); | ||
const Charsets = require('../constants/charsets.js'); | ||
const helpers = require('../helpers'); | ||
const genFunc = require('generate-function'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const genFunc = require('generate-function'); |
const Charsets = require('../constants/charsets.js'); | ||
const helpers = require('../helpers'); | ||
const genFunc = require('generate-function'); | ||
const parserCache = require('./parser_cache.js'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const parserCache = require('./parser_cache.js'); |
return packet.parseLengthCodedFloat(); | ||
case Types.NULL: | ||
// case Types.BIT: | ||
// return 'packet.readBuffer(2)[1]'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Delete the useless code?
@@ -212,7 +213,11 @@ class Query extends Command { | |||
if (this._receivedFieldsCount === this._fieldCount) { | |||
const fields = this._fields[this._resultIndex]; | |||
this.emit('fields', fields); | |||
this._rowParser = new (getTextParser(fields, this.options, connection.config))(fields); | |||
if (this.options.useStaticParser) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add this option to connection.config.js
node-mysql2/lib/connection_config.js
Line 68 in 15f1669
waitForConnections: 1 |
WIP, work related to
#2090