Skip to content

Conversation

9EOR9
Copy link

@9EOR9 9EOR9 commented Feb 16, 2016

Since MariaDB hacked the version number and prefixes the MariaDB version with 5.5.5- the version string is not correct when connecting to MariaDB
server..
(For discussion see [Joomla discussion|https://github.com/joomla/joomla-cms/issues/9062#issuecomment-182969806])

This fix skips the first 7 bytes of version string, if the version string in greeting package is prefixed with
5.5.5- Neither MariaDB nor Oracle released a 5.5.5 version, so it will not have any side affect with
older versions of MySQL, Percona or MariaDB.

with 5.5.5- the version string is not correct when connecting to MariaDB
server..
(For discussion see joomla/joomla-cms#9062 (comment))

This fix skips the first 7 bytes of version string, if the version string in greeting package is prefixed with
5.5.5- Neither MariaDB nor Oracle  released a 5.5.5 version, so it will not have any side affect with
older versions of MySQL, Percona or MariaDB.
@photodude
Copy link

@9EOR9

  • How are you sure that in every instance, and in every case, that the prefix is always going to be "7 bytes" (or more specifically to your change is always going to be 5.5.5-)?
  • How are you sure that there are not other instances when the prefix needs to be reported?
  • How are you sure that there are not other types of prefixes that might be included with the version or need to be excluded from the version?

@9EOR9
Copy link
Author

9EOR9 commented Feb 16, 2016

Hi,

  • ow are you sure that in every instance, and in every case, that the
    prefix is always going to be "7 bytes" (or more specifically to your change
    is always going to be 5.5.5-)?

it was 7 bytes in commit message - but in code it's actual sizeof(#define)
-1

  • How are you sure that there are not other instances when the prefix
    needs to be reported?

Very good question - I wonder how Oracle will handle backwards
compatibility in replication when switching to a 2 digit number in major
version string.

  • How are you sure that there are not other types of prefixes that
    might be included with the version or need to be excluded from the version

I'm not aware of any prefixes, as mentioned in commit message, 5.5.5 never
existed (or will exist) .

I was away long time away fron php (I once wrote mysqli in 2003), so I
wasn't sure what is the best way? Pushing directly (quite not sure if I
have permissions for) or send a pull request. - I thought a pull request
will be the best solution - Btwm In the meanwhile I discussed patch with
Andrey Hristov- we will continue discussion tomorrow

/Georg


Reply to this email directly or view it on GitHub
#1767 (comment).

Georg Richter, Senior Software Engineer
MariaDB Corporation Ab

@smalyshev smalyshev added the Bug label Nov 27, 2016
@krakjoe
Copy link
Member

krakjoe commented Jan 1, 2017

@9EOR9 can we know the current status of this patch and or link to/excerpt from conversation mentioned ?

@krakjoe
Copy link
Member

krakjoe commented Feb 22, 2017

Having waited more than a month for feedback, and having received nothing, I'm closing this PR as it would appear abandoned.

Please take this action as encouragement to open a clean PR with issues raised here resolved.

@krakjoe krakjoe closed this Feb 22, 2017
@vuvova
Copy link

vuvova commented Aug 28, 2017

I can answer these question.

  • Very sure. It's hard-coded into the MariaDB server code and isn't going to change
  • No other instances. It's only reported in the first protocol packet, nowhere else.
  • No other types of prefixes exist or ever existed.

@amin007
Copy link

amin007 commented Aug 24, 2018

are php want to build library php_maria to replace php_mysqli?

@petk
Copy link
Member

petk commented Aug 24, 2018

@amin007 nothing has been discussed about that anywhere I think. The mysqli and PDO_MySQL extensions work also for MariaDB...

@amin007
Copy link

amin007 commented Sep 30, 2018

@petk, i know mysqli and pdo_mysql work for mariadb.

but using maria's name is very interesting if used in the php library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants