Msphpsql: please adhere to naming scheme for PHP extensions and do separate releases

Created on 23 Apr 2016  Â·  12Comments  Â·  Source: microsoft/msphpsql

Hello :)

It would be very nice of you, if you could change your (a) current naming scheme for released files and (b) do separate releases for the version constraints.

The current pre-release version v4.0.3 has 4 downloads:
pdo_sqlsrv.zip & sqlsrv.zip, which contain source-code.
and x64.zip & x86.zip, which contains several DLL files:

  • php_pdo_sqlsrv_7_nts.dll
  • php_pdo_sqlsrv_7_ts.dll
  • php_sqlsrv_7_nts.dll
  • php_sqlsrv_7_ts.dll

I'd suggest to use the following scheme for the files shipping source:
pdo_sqlsrv_<version>_src.zip & sqlsrv_<version>_src.zip.

The scheme for the zip files is:
php_<extension>-<version>-<phpversion>-<compiler>-<nts>-<bitsize>.zip

The scheme for the DLL files is:
php_<extension>.dll

That means you would need to add some more version constraints to zip files:

  • version, phpversion, compiler, nts , bitsize

And ditch constraints from the dlls.

For example for php_pdo_sqlsrv:

64bit:

  • php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x64.zip
  • php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x64.zip

32bit:

  • php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x86.zip
  • php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x86.zip

Other releases contain the "nts" and "ts" separation with short forms for the bitsize: x64, x86,
for example http://windows.php.net/downloads/pecl/releases/couchbase/2.2.0beta2/

Please do seperate releases for

  • nts and ts builds
  • per bitsize
  • and finally, don't combine two extensions into one release package

    • release php_pdo_sqlsrv and php_sqlsrv separately

The suggested changes will save a lot of time for users who download manually and allow a better integration for download tools (automatic extension detection based on version information).

Looking forward to the next release. Keep up the good work.

Best, Jens

Most helpful comment

we wonder how do users upgrade extensions – do you want to be updating the php.ini configuration file with every new release version

  • (Some users install and upgrade extension using pickle, which installs/upgrades PECL extensions automatically. But this extension isn't listed there, so it wouldn't work.)
  • Well, users would do it in the traditional way: when installing and upgrading PECL extensions they would fetch the zip manually and extract the dll into php\ext thereby replacing the old dll file.
    The zip indicates the exact version, while the dll is simply the extension name: php_pdo_sqlsrv.dll.

Lets say a user installed v1.2.3 and upgrades to v2.0.0:

  • php_pdo_sqlsrv-1.2.3-7.0-vc14-nts-x64.zip - php_pdo_sqlsrv.dll (fetch, extract, php.ini entry)
  • php_pdo_sqlsrv-2.0.0-7.0-vc14-nts-x64.zip - php_pdo_sqlsrv.dll (fetch, extract, replace dll)

So there is no need to rename the dll to a short form or edit php.ini to adjust the version. The extension name stays the same. With the PECL scheme its basically a drop-in-replacement.

All 12 comments

â—¦only indicate nts, leave away if TS

Why? To me it makes much more sense to leave it in. It takes away the guesswork.

This works better for me:

64bit:
• php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x86_64.dll
• php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x86_64.dll

32bit:
• php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x86_32.dll
• php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x86_32.dll

This way the TS/NTS and 32/64 distinction is clear.

It takes away the guesswork.

Thank you for the comment. Yes, you are right.

(I've updated my post and removed that. I followed the scheme from xdebug while writing the issue, see https://xdebug.org/download.php)

It might be better to follow the scheme on PECL, where releases contain the nts and ts separation with short forms for the bitsize: x64, x86, e.g. http://windows.php.net/downloads/pecl/releases/couchbase/2.2.0beta2/

@jakoch and @luisdev : Point taken about renaming the zip files. We will do that from our next release.

With regards to the dll's, the team brainstormed this and here are our options with regards to renaming:

Option 1
64bit
• php_pdo_sqlsrv_7_nts-x64.dll
• php_pdo_sqlsrv_7_nts-x64.dll

32bit
• php_pdo_sqlsrv_7_nts-x86.dll
• php_pdo_sqlsrv_7_nts-x86.dll

Option 2 (your recommendation)
64bit:
• php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x86_64.dll
• php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x86_64.dll

32bit:
• php_pdo_sqlsrv-4.0.3-7.0-vc14-nts-x86_32.dll
• php_pdo_sqlsrv-4.0.3-7.0-vc14-ts-x86_32.dll

What are your thoughts on Option 1? With Option 2, we wonder how do users upgrade extensions – do you want to be updating the php.ini configuration file with every new release version?

Cheers,
Meet

without a doubt, option 1...

I'm responsible for 6 Web Servers and I would prefer not to be updating the php.ini on each of those when an extension is updated. In light of the feedback, direct communications with the dev team and testing done by the participants of this repository - I'm thinking the updates are going to be frequent...

@camrada tbh, you can simply rename the dll and then spread it. imo option 2 would help for more clarity.

we wonder how do users upgrade extensions – do you want to be updating the php.ini configuration file with every new release version

  • (Some users install and upgrade extension using pickle, which installs/upgrades PECL extensions automatically. But this extension isn't listed there, so it wouldn't work.)
  • Well, users would do it in the traditional way: when installing and upgrading PECL extensions they would fetch the zip manually and extract the dll into php\ext thereby replacing the old dll file.
    The zip indicates the exact version, while the dll is simply the extension name: php_pdo_sqlsrv.dll.

Lets say a user installed v1.2.3 and upgrades to v2.0.0:

  • php_pdo_sqlsrv-1.2.3-7.0-vc14-nts-x64.zip - php_pdo_sqlsrv.dll (fetch, extract, php.ini entry)
  • php_pdo_sqlsrv-2.0.0-7.0-vc14-nts-x64.zip - php_pdo_sqlsrv.dll (fetch, extract, replace dll)

So there is no need to rename the dll to a short form or edit php.ini to adjust the version. The extension name stays the same. With the PECL scheme its basically a drop-in-replacement.

We do not name the DLLs using this scheme but only the archive. Doing so will work smoothly with the pickle installer (https://github.com/FriendsOfPHP/pickle/ composer based installer) and other tools to ease the install process, as @jakoch said.

It will also help to work smoothly with the pickle site (packagist.org for php extension).

By the way, it would be nice to have releases too on https://pecl.php.net/package/sqlsrv. @welting can help you here (ping on lync). Binaries can be linked or simply mirrored there. You can ping me as well for nay question in this regard or for pickle support.

@pierrejoye We would love to update the pickle packages. A few members of my team and myself have requested access to pickle. The current owner of the pickle packages has moved on. It has been ~1 week and we have not heard back. Can you help us connect with @welting?

@jakoch, @camrada, @luisdev and rest: While we update our pickle packages, we have aimed to improve the naming scheme with the following with our latest release:

  • php_pdo_sqlsrv_4.0.4_x64.zip
  • php_pdo_sqlsrv_4.0.4_x86.zip
  • php_sqlrv_4.0.4_x64.zip
  • php_sqlrv_4.0.4_x86.zip

We kept the dll's names the same for now but are more than happy to change based on the feedback we receive.

Let us know what your feedback is and we can incorporate it in the future releases.

Cheers,
Meet

I will drop you a mail and let sort it out. I will already approve your account asap.

Here is my feedback:

Thanks for considering and resolving these issue in future releases.

Regards, Jens

Hi @jakoch, please check our recent release (note the Windows binaries for PHP7 and PHP7.1 are now up on PECL)
https://github.com/Microsoft/msphpsql/releases/tag/v4.1.6

Let us know if we can close this issue. Thanks!

Hi @yitam + team!
Thank you for resolving this issue. Keep up the good work.
Best, Jens

Was this page helpful?
0 / 5 - 0 ratings