Sent from my iPhone
On 23/04/2024 10:25, Stephen Reay wrote:
The argument that "Client" is meaningless becomes pretty moot when you realise that you can import a namespace and use it relatively, if you so wish:
import MyLib\HTTP; $a = new HTTP\Client(...);
Hi Stephen,
Granted, but I also believe the user can and should have the reasonable expectation that they can work comfortably (without conflicts or aliases) using leaf (class) names exclusively.
Kind regards,
Bilge
I'm sorry but I think you've missed the entire point of namespaces if you want class names to all be universally unique without their namespace component.
The referenced RFC gives clear examples of how a class with a prefix would be converted to a namespace and class.
A thought crossed my mind, considering that MariaDB and MySQL are drifting
more and more apart with features and nuances of how they work, would it be
a good idea to create an alias to MySQL PDO driver under MariaDB name so we
can create a MariaDB specific implementation down the road and so people
can use DB specific features right away and not be confused why there are
errors between those 2 if someone swaps one for the other.
--
Arvīds Godjuks
+371 26 851 664
arvids.godjuks@gmail.com
Telegram: @psihius https://t.me/psihius
A thought crossed my mind, considering that MariaDB and MySQL are drifting more and more apart with features and nuances of how they work, would it be a good idea to create an alias to MySQL PDO driver under MariaDB name so we can create a MariaDB specific implementation down the road and so people can use DB specific features right away and not be confused why there are errors between those 2 if someone swaps one for the other.
IMHO, this is out of scope for this proposal.
If MariaDB wants to maintain a specific PDO Driver they can do so themselves and publish it on PECL, same as how CUBRID (and others) does currently.
Best regards,
Gina P. Banyard
Hi,
Il 29/04/2024 15:10, Gina P. Banyard ha scritto:
On Tuesday, 23 April 2024 at 15:59, Arvids Godjuks
arvids.godjuks@gmail.com wrote:A thought crossed my mind, considering that MariaDB and MySQL are
drifting more and more apart with features and nuances of how they
work, would it be a good idea to create an alias to MySQL PDO driver
under MariaDB name so we can create a MariaDB specific implementation
down the road and so people can use DB specific features right away
and not be confused why there are errors between those 2 if someone
swaps one for the other.IMHO, this is out of scope for this proposal.
Yes, indeed.
If MariaDB wants to maintain a specific PDO Driver they can do so
themselves and publish it on PECL, same as how CUBRID (and others) does
currently.
That is true, however it's mysqlnd the part that deals with the network
protocol, which they wouldn't be able to modify from PECL. That said,
I'm not an expert on mysql/maria, but I also doubt the changes are
significant enough that they need a separate driver.
Cheers
Matteo Beccati
Development & Consulting - http://www.beccati.com/
Hi,
If MariaDB wants to maintain a specific PDO Driver they can do so
themselves and publish it on PECL, same as how CUBRID (and others) does
currently.That is true, however it's mysqlnd the part that deals with the network
protocol, which they wouldn't be able to modify from PECL. That said,
I'm not an expert on mysql/maria, but I also doubt the changes are
significant enough that they need a separate driver.
I wasn't proposing rolling a separate driver or anything like that, just
an alias that would reserve a namespace for MariaDB and if there's ever a
need to actually roll the driver, that alias be replaced with actual driver.
The thing is at this point MySQL and MariaDB have a different set of
additional capabilities that are not compatible between the two. Doctrine,
at this point, actually makes a distinction between MariaDB and MySQL -
those are considered different databases.
This would allow people to use MariaDB and MySQL-specific functionality by
using the respective driver namespace and remove any confusion about if
this works with both or only one of them.
I know it seems to be out of scope, but this deals with PDO subclass names
and this seems to be a thing to consider here. Sure, we can have a separate
RFC about it, but I think this is the right moment to handle this question.
--
Arvīds Godjuks
+371 26 851 664
arvids.godjuks@gmail.com
Telegram: @psihius https://t.me/psihius
Hi Arvīds,
I wasn't proposing rolling a separate driver or anything like that, just an alias that would reserve a namespace for MariaDB and if there's ever a need to actually roll the driver, that alias be replaced with actual driver.
The thing is at this point MySQL and MariaDB have a different set of additional capabilities that are not compatible between the two. Doctrine, at this point, actually makes a distinction between MariaDB and MySQL - those are considered different databases.
This would allow people to use MariaDB and MySQL-specific functionality by using the respective driver namespace and remove any confusion about if this works with both or only one of them.I know it seems to be out of scope, but this deals with PDO subclass names and this seems to be a thing to consider here. Sure, we can have a separate RFC about it, but I think this is the right moment to handle this question.
It's a very interesting subject, but off-topic for this thread. The purpose of this thread is to make a correction based on the Namespace RFC, since the RFC regarding namespaces and the RFC regarding PDO subclasses are in conflict with each other.
That is, the PDO subclass RFC was passed in violation of the namespace RFC, and we are proposing the appropriate fix for it.
(However, this is a very grey area. The Namespaces RFC "recommends" the use of namespaces, rather than mandating it.)
Personally, I believe this fix does not require a new RFC.
Regards,
Saki
Hi,
If MariaDB wants to maintain a specific PDO Driver they can do so
themselves and publish it on PECL, same as how CUBRID (and others) does
currently.That is true, however it's mysqlnd the part that deals with the network
protocol, which they wouldn't be able to modify from PECL. That said,
I'm not an expert on mysql/maria, but I also doubt the changes are
significant enough that they need a separate driver.I wasn't proposing rolling a separate driver or anything like that, just an alias that would reserve a namespace for MariaDB and if there's ever a need to actually roll the driver, that alias be replaced with actual driver.
The thing is at this point MySQL and MariaDB have a different set of additional capabilities that are not compatible between the two. Doctrine, at this point, actually makes a distinction between MariaDB and MySQL - those are considered different databases.
This would allow people to use MariaDB and MySQL-specific functionality by using the respective driver namespace and remove any confusion about if this works with both or only one of them.I know it seems to be out of scope, but this deals with PDO subclass names and this seems to be a thing to consider here. Sure, we can have a separate RFC about it, but I think this is the right moment to handle this question.
Has the network protocol diverged much? I know storage engines, query language, etc. might change, but the underlying protocol might be similar.
This would allow people to use MariaDB and MySQL-specific functionality by
using the respective driver namespace and remove any confusion about if this
works with both or only one of them.I know it seems to be out of scope, but this deals with PDO subclass names
and this seems to be a thing to consider here. Sure, we can have a separate
RFC about it, but I think this is the right moment to handle this question.Has the network protocol diverged much? I know storage engines, query
language, etc. might change, but the underlying protocol might be similar.
Saw this on a Jira ticket for MaxScale: "The MariaDB and MySQL protocols are mostly identical and the differences are of opt-in character."