SlideShare uma empresa Scribd logo
1 de 43
Baixar para ler offline
MySQL Compatible Open
  Source Connectors
  Andrew (LinuxJedi) Hutchings
  Master Software Engineer - HP
Who am I?
●   Worked at Sun/Oracle on MySQL 2008-2010
●   Worked at Rackspace on Drizzle 2010-2011
●   Worked at SkySQL on MySQL/Drizzle 2011
●   Co-author MySQL 5.1 Plugin Development
●   Now work at HP Cloud on an LBaaS
Why this talk?
● I work for HP Cloud
● MySQL and its forks are the database for the
  cloud
● I currently work on a MySQL connector in
  my spare time
Licenses
Notes:
● I am not a lawyer
● These legal views are my own and not
  necessarily HP's
  ○ They may not even be correct, my brain has been
    fried with legalese
GPL v2
●   General Public License
●   Compatible with most Open Source licenses
●   Not compatible with commercial licenses
●   Must include all source (and tracked
    changes to library)
FLOSS Exception
Free/Libre Open Source Software Exceptions

● Allows GPL library to be linked to a non-
  compatible Open Source license without
  relicensing as GPL
● MySQL's built-in client library is covered by
  this
   ○ Except maybe a few 5.1 versions
LGPL v2
● Lesser (or Library) General Public License
● Allows dynamic linking with other licenses
● Doesn't allow static linking
  ○ becomes a derivative work
● Must include library source
BSD Simplified
● AKA BSD New or 3-Clause BSD
● Can link to commercial software
● Very liberal simple license
MIT
● Even more liberal than BSD
● Very simple license
Apache 2.0
● Can link to commercial software
● Includes patent usage grants
● License text is around 5x longer than BSD's
PHP v3.01
● Not compatible with GPL license
● Can link with commercial software
License Compatibility
                                                                            Library


                                                 GPL 2        PHP 3.01   Apache 2.0   LGPL 2.0   BSD/MIT

              GPL (dynamically linked)              ✔            ✘*          ✔           ✔          ✔
Application




              GPL (statically linked)               ✔            ✘*          ✔           ✔          ✔

              Commercial (dynamically linked)       ✘            ✔           ✔          ✔✝          ✔

              Commercial (statically linked)        ✘            ✔           ✔           ✘          ✔




              *    Workaround possible with FLOSS exception
              ✝    Need to provide lib source to end user
Frameworks
● Only linking to framework
  ○ So connector license not a problem
  ○ Connector is loaded on-demand by the framework
  ○ Should be good as long as you don't distribute the
    connector with your application
● Examples include
  ○ ODBC (Open DataBase Connectivity)
  ○ JDBC (Java DataBase Connectivity)
  ○ SQLAlchemy (Python)
● Most are MIT licensed
Licensing Resources
TL;DR Legal
http://www.tldrlegal.com/

GPL Compatibility Chart
http://www.gnu.org/licenses/license-list.html

Ask Monty Licensing FAQ
https://kb.askmonty.org/en/licensing-faq/
C/C++/C# Connectors
C
libmysqlclient
●   Developed by Oracle
●   Bundled with MySQL
●   LGPL licensed up until 3.23.58
●   GPL licensed onwards
    ○ Also commercial licensed
    ○ Has FLOSS Exception
C
Connector/C
● Developed by Sun
● An attempt to separate out the connector
● GPL licensed
  ○ Also has commercial license
  ○ Has FLOSS Exception
● No release since 2009-08-10 (6.0.2)
C
MariaDB Client Library
● Developed by Monty Program Ab and
  SkySQL Ab
● A fork of MySQL's 3.23 client library
  ○ Also contains some parts of MySQLnd
● LGPL licensed
● Features added to catch up with current API
C/C++
Libdrizzle
● Developed by Open Source community
    ○ Companies such as Sun and Rackspace have been
      involved
●   C API (some C++ in 2.0)
●   BSD licensed
●   Part of the main Drizzle project
●   Speaks both client and server MySQL
    protocol
C
Libdrizzle Redux
● Developed by me
● A heavily modified version of Libdrizzle
● Still under the Drizzle umbrella
    ○ But different tree
●   Still BSD licensed
●   Server API removed
●   More simplified client API
●   New features
    ○   Binlog retrieval API
    ○   Compression Protocol (coming in 2013)
    ○   Prepared Statements (coming in 2013)
    ○   libmysqlclient compatible API (coming in 2013)
C API Example
Setup
MySQL API
conn = mysql_init(NULL);
mysql_real_connect(conn, "localhost", "user", "passwd",
"testdb", 0, NULL, 0);



Drizzle API
drizzle = drizzle_create();
con = drizzle_con_add_tcp(drizzle, "localhost", 3306, "user",
"passwd", "testdb", 0);
ret = drizzle_con_connect(con);
C API Example
Query
MySQL API
mysql_query(conn, "SELECT * FROM t1");
result = mysql_store_result(conn);
num_fields = mysql_num_fields(result);
while ((row = mysql_fetch_row(result)))
...



Drizzle API
result = drizzle_query_str(con, "select * from t1", &ret);
ret = drizzle_result_buffer(result);
num_fields = drizzle_result_column_count(result);
while ((row = drizzle_row_next(result)))
...
C++
Connector/C++
● Developed by Oracle
● JDBC 4.0 API compatible
  ○ Although only about 80% implemented
● GPL licensed
  ○ Commercial also available
  ○ Has FLOSS Exception
C
Connector/ODBC
● Developed by Oracle
● GPL Licensed
  ○ With FLOSS Exception
  ○ Commercial available
● Is a plugin for the ODBC framework, so good
  for commercial
C#
Connector/NET
● Developed by Oracle
● GPL Licensed
  ○ With FLOSS Exception
  ○ Commercial available
● Implements ADO.NET interfaces
PHP Connectors
PHP
● Three different connectors
   ○ mysql
   ○ mysqli
   ○ pdo_mysql
● All three use either libmysqlclient or
  MySQLnd
PHP
libmysqlclient based
● PHP can't link to GPL
● PHP 3 dual licensed PHP/GPL
● PHP 4 onwards licensed PHP only
  ○ So couldn't link to libmysqlclient
  ○ But libmysqlclient has FLOSS Exception
● MySQLnd instead!
PHP
MySQLnd
● Developed by Oracle
● C based MySQL client library for PHP
● Licensed under PHP license
Python Connectors
Python
MySQLdb
●   Independently developed
●   GPL licensed
●   Wraps around libmysqlclient
●   Supports Python DB-API 2.0
Python
Connector/Python
● Developed by Oracle
● GPL licensed
  ○ With FLOSS exception
  ○ Commercial also available
● Native driver
● Supports Python DB-API 2.0
Python Framework
SQLAlchemy
● MIT licensed
● Gets around linking problem
● Uses DB-API 2.0 connectors
Java Connectors
Java
Connector/J
● Developed by Oracle
● GPL Licensed
  ○ Also has commercial license
  ○ With FLOSS exception
● JDBC Type 4 driver
  ○ So no linking with app required
Java
Drizzle JDBC
● Developed by Open Source community
  ○ Companies such as Sun and Rackspace have been
    involved
● BSD Licensed
● JDBC Type 4.0 driver
Java
MariaDB Client Library for Java
● Developed by Monty Program Ab and
  SkySQL Ab
● A fork of Drizzle JDBC
● LGPL Licensed
● JDBC Type 4.0 driver
Other Interfaces
Node.js
● Many available!
  ○ Around 10 projects
● node-mysql appears to be most prominent
  ○ MIT licensed
  ○ Appears to be a Native driver
NoSQL Interface
● Developed by Oracle
● Included in MySQL 5.6
● GPL Licensed
  ○ With a commercial version
  ○ Unsure about FLOSS Exception
● Based on Memcache API
● Direct access to InnoDB tables
MySQL Cluster
● NDBAPI & MGMAPI
  ○ NoSQL interface
● Memcache based NoSQL interface
● Java APIs
Plugins
Possible to create things like
● UDP
● HTTP / REST


Read my book to find out more:
Thank you!
My work (we're hiring!):
http://hpcloud.com/

Twitter / Freenode IRC nick:
LinuxJedi

Email:
andrew@linuxjedi.co.uk / linuxjedi@hp.com

Mais conteúdo relacionado

Mais procurados

Як РНР розробник пише код на Kotlin
Як РНР розробник пише код на KotlinЯк РНР розробник пише код на Kotlin
Як РНР розробник пише код на Kotlinphpfriendsclub
 
Dev + DevOps для PHP розробника
Dev + DevOps для PHP розробникаDev + DevOps для PHP розробника
Dev + DevOps для PHP розробникаphpfriendsclub
 
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & Chromium
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & ChromiumHKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & Chromium
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & ChromiumLinaro
 
Extensible web
Extensible webExtensible web
Extensible webJxck Jxck
 
Last Month in PHP - June 2016
Last Month in PHP - June 2016Last Month in PHP - June 2016
Last Month in PHP - June 2016Eric Poe
 
GDG Algiers DevFest 2013 Cool AndroidLibs
GDG Algiers DevFest 2013 Cool AndroidLibsGDG Algiers DevFest 2013 Cool AndroidLibs
GDG Algiers DevFest 2013 Cool AndroidLibsnhachicha
 
Python Static Site Generator in Pelican
Python Static Site Generator in  PelicanPython Static Site Generator in  Pelican
Python Static Site Generator in PelicanGaurav Sehrawat
 
Introduction to gRPC
Introduction to gRPCIntroduction to gRPC
Introduction to gRPCPrakash Divy
 
Opensource pnp container based waf
Opensource pnp container based wafOpensource pnp container based waf
Opensource pnp container based wafVarun konadagadapa
 
Extensible web #html5j
Extensible web #html5jExtensible web #html5j
Extensible web #html5jJxck Jxck
 
PHP QA Tools
PHP QA ToolsPHP QA Tools
PHP QA Toolsrjsmelo
 
PHP & MySQL: PDO x MySQLi
PHP & MySQL: PDO x MySQLiPHP & MySQL: PDO x MySQLi
PHP & MySQL: PDO x MySQLiMarcos Marcolin
 
Docker & PHP - Practical use case
Docker & PHP - Practical use caseDocker & PHP - Practical use case
Docker & PHP - Practical use caserjsmelo
 
Local Community for Debian (2013 Taiwan miniDebConf)
Local Community for Debian (2013 Taiwan miniDebConf)Local Community for Debian (2013 Taiwan miniDebConf)
Local Community for Debian (2013 Taiwan miniDebConf)Hideki Yamane
 
An introduction to Node.js application development
An introduction to Node.js application developmentAn introduction to Node.js application development
An introduction to Node.js application developmentshelloidhq
 
A Real ADF Experience Part II
A Real ADF Experience Part IIA Real ADF Experience Part II
A Real ADF Experience Part IIMano Swerts
 
ORTC SVC SimulCast
ORTC SVC SimulCastORTC SVC SimulCast
ORTC SVC SimulCastJxck Jxck
 
Neoito — Software licensing
Neoito — Software licensingNeoito — Software licensing
Neoito — Software licensingNeoito
 

Mais procurados (20)

Як РНР розробник пише код на Kotlin
Як РНР розробник пише код на KotlinЯк РНР розробник пише код на Kotlin
Як РНР розробник пише код на Kotlin
 
Dev + DevOps для PHP розробника
Dev + DevOps для PHP розробникаDev + DevOps для PHP розробника
Dev + DevOps для PHP розробника
 
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & Chromium
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & ChromiumHKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & Chromium
HKG18-217 - OpenCDM/CDMi (Multi DRM) work with WPE & Chromium
 
Extensible web
Extensible webExtensible web
Extensible web
 
Last Month in PHP - June 2016
Last Month in PHP - June 2016Last Month in PHP - June 2016
Last Month in PHP - June 2016
 
GDG Algiers DevFest 2013 Cool AndroidLibs
GDG Algiers DevFest 2013 Cool AndroidLibsGDG Algiers DevFest 2013 Cool AndroidLibs
GDG Algiers DevFest 2013 Cool AndroidLibs
 
Python Static Site Generator in Pelican
Python Static Site Generator in  PelicanPython Static Site Generator in  Pelican
Python Static Site Generator in Pelican
 
Introduction to gRPC
Introduction to gRPCIntroduction to gRPC
Introduction to gRPC
 
gRPC Overview
gRPC OverviewgRPC Overview
gRPC Overview
 
Opensource pnp container based waf
Opensource pnp container based wafOpensource pnp container based waf
Opensource pnp container based waf
 
Extensible web #html5j
Extensible web #html5jExtensible web #html5j
Extensible web #html5j
 
PHP QA Tools
PHP QA ToolsPHP QA Tools
PHP QA Tools
 
PHP & MySQL: PDO x MySQLi
PHP & MySQL: PDO x MySQLiPHP & MySQL: PDO x MySQLi
PHP & MySQL: PDO x MySQLi
 
Comparing C and Go
Comparing C and GoComparing C and Go
Comparing C and Go
 
Docker & PHP - Practical use case
Docker & PHP - Practical use caseDocker & PHP - Practical use case
Docker & PHP - Practical use case
 
Local Community for Debian (2013 Taiwan miniDebConf)
Local Community for Debian (2013 Taiwan miniDebConf)Local Community for Debian (2013 Taiwan miniDebConf)
Local Community for Debian (2013 Taiwan miniDebConf)
 
An introduction to Node.js application development
An introduction to Node.js application developmentAn introduction to Node.js application development
An introduction to Node.js application development
 
A Real ADF Experience Part II
A Real ADF Experience Part IIA Real ADF Experience Part II
A Real ADF Experience Part II
 
ORTC SVC SimulCast
ORTC SVC SimulCastORTC SVC SimulCast
ORTC SVC SimulCast
 
Neoito — Software licensing
Neoito — Software licensingNeoito — Software licensing
Neoito — Software licensing
 

Semelhante a MySQL Compatible Open Source Connectors

Volunteering at YouSee on Technology Support
Volunteering at YouSee on Technology SupportVolunteering at YouSee on Technology Support
Volunteering at YouSee on Technology SupportYouSee
 
Plugin Development for Beginners
Plugin Development for BeginnersPlugin Development for Beginners
Plugin Development for BeginnersJoe Cartonia
 
Beginning with Composer - Dependency manager in php
Beginning with Composer  - Dependency manager in php Beginning with Composer  - Dependency manager in php
Beginning with Composer - Dependency manager in php Yogesh Salvi
 
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdf
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdfManaging Software Dependencies and the Supply Chain_ MIT EM.S20.pdf
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdfAndrew Lamb
 
Node.js vs PHP, What should SMBs prefer for web development.pdf
Node.js vs PHP, What should SMBs prefer for web development.pdfNode.js vs PHP, What should SMBs prefer for web development.pdf
Node.js vs PHP, What should SMBs prefer for web development.pdfMindfire LLC
 
Using PHP with IBM Bluemix
Using PHP with IBM BluemixUsing PHP with IBM Bluemix
Using PHP with IBM Bluemixvvaswani
 
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.SoftInstigate
 
Intermediate git
Intermediate gitIntermediate git
Intermediate gitDan Shrader
 
Full Steam Ahead, R2DBC!
Full Steam Ahead, R2DBC!Full Steam Ahead, R2DBC!
Full Steam Ahead, R2DBC!VMware Tanzu
 
Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Clark Everetts
 
What's New in OpenLDAP
What's New in OpenLDAPWhat's New in OpenLDAP
What's New in OpenLDAPLDAPCon
 
Glauber Costa on OSv as NoSQL platform
Glauber Costa on OSv as NoSQL platformGlauber Costa on OSv as NoSQL platform
Glauber Costa on OSv as NoSQL platformDon Marti
 
Mumbai MuleSoft Meetup #17 - GraphQL
Mumbai MuleSoft Meetup #17 - GraphQLMumbai MuleSoft Meetup #17 - GraphQL
Mumbai MuleSoft Meetup #17 - GraphQLAkshata Sawant
 
Libmysqld Introduction
Libmysqld IntroductionLibmysqld Introduction
Libmysqld Introductionpapablues
 
MongoDB Jump Start
MongoDB Jump StartMongoDB Jump Start
MongoDB Jump StartHaim Michael
 
Plugin Development for Beginners v.2019
Plugin Development for Beginners v.2019Plugin Development for Beginners v.2019
Plugin Development for Beginners v.2019Joe Cartonia
 
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)Pierre Mavro
 
One year solving infrastructure management with FusionDirectory and OpenLDAP,...
One year solving infrastructure management with FusionDirectory and OpenLDAP,...One year solving infrastructure management with FusionDirectory and OpenLDAP,...
One year solving infrastructure management with FusionDirectory and OpenLDAP,...OW2
 
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud RunDesigning flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Runwesley chun
 

Semelhante a MySQL Compatible Open Source Connectors (20)

Volunteering at YouSee on Technology Support
Volunteering at YouSee on Technology SupportVolunteering at YouSee on Technology Support
Volunteering at YouSee on Technology Support
 
Plugin Development for Beginners
Plugin Development for BeginnersPlugin Development for Beginners
Plugin Development for Beginners
 
Beginning with Composer - Dependency manager in php
Beginning with Composer  - Dependency manager in php Beginning with Composer  - Dependency manager in php
Beginning with Composer - Dependency manager in php
 
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdf
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdfManaging Software Dependencies and the Supply Chain_ MIT EM.S20.pdf
Managing Software Dependencies and the Supply Chain_ MIT EM.S20.pdf
 
Wc13
Wc13Wc13
Wc13
 
Node.js vs PHP, What should SMBs prefer for web development.pdf
Node.js vs PHP, What should SMBs prefer for web development.pdfNode.js vs PHP, What should SMBs prefer for web development.pdf
Node.js vs PHP, What should SMBs prefer for web development.pdf
 
Using PHP with IBM Bluemix
Using PHP with IBM BluemixUsing PHP with IBM Bluemix
Using PHP with IBM Bluemix
 
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.
RESTHeart - Modern runtime for microservices with instant Data API on MongoDB.
 
Intermediate git
Intermediate gitIntermediate git
Intermediate git
 
Full Steam Ahead, R2DBC!
Full Steam Ahead, R2DBC!Full Steam Ahead, R2DBC!
Full Steam Ahead, R2DBC!
 
Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017
 
What's New in OpenLDAP
What's New in OpenLDAPWhat's New in OpenLDAP
What's New in OpenLDAP
 
Glauber Costa on OSv as NoSQL platform
Glauber Costa on OSv as NoSQL platformGlauber Costa on OSv as NoSQL platform
Glauber Costa on OSv as NoSQL platform
 
Mumbai MuleSoft Meetup #17 - GraphQL
Mumbai MuleSoft Meetup #17 - GraphQLMumbai MuleSoft Meetup #17 - GraphQL
Mumbai MuleSoft Meetup #17 - GraphQL
 
Libmysqld Introduction
Libmysqld IntroductionLibmysqld Introduction
Libmysqld Introduction
 
MongoDB Jump Start
MongoDB Jump StartMongoDB Jump Start
MongoDB Jump Start
 
Plugin Development for Beginners v.2019
Plugin Development for Beginners v.2019Plugin Development for Beginners v.2019
Plugin Development for Beginners v.2019
 
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)
Traefik on Kubernetes at MySocialApp (CNCF Paris Meetup)
 
One year solving infrastructure management with FusionDirectory and OpenLDAP,...
One year solving infrastructure management with FusionDirectory and OpenLDAP,...One year solving infrastructure management with FusionDirectory and OpenLDAP,...
One year solving infrastructure management with FusionDirectory and OpenLDAP,...
 
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud RunDesigning flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
Designing flexible apps deployable to App Engine, Cloud Functions, or Cloud Run
 

Último

Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...gurkirankumar98700
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 

Último (20)

Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
Kalyanpur ) Call Girls in Lucknow Finest Escorts Service 🍸 8923113531 🎰 Avail...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 

MySQL Compatible Open Source Connectors

  • 1. MySQL Compatible Open Source Connectors Andrew (LinuxJedi) Hutchings Master Software Engineer - HP
  • 2. Who am I? ● Worked at Sun/Oracle on MySQL 2008-2010 ● Worked at Rackspace on Drizzle 2010-2011 ● Worked at SkySQL on MySQL/Drizzle 2011 ● Co-author MySQL 5.1 Plugin Development ● Now work at HP Cloud on an LBaaS
  • 3. Why this talk? ● I work for HP Cloud ● MySQL and its forks are the database for the cloud ● I currently work on a MySQL connector in my spare time
  • 4. Licenses Notes: ● I am not a lawyer ● These legal views are my own and not necessarily HP's ○ They may not even be correct, my brain has been fried with legalese
  • 5. GPL v2 ● General Public License ● Compatible with most Open Source licenses ● Not compatible with commercial licenses ● Must include all source (and tracked changes to library)
  • 6. FLOSS Exception Free/Libre Open Source Software Exceptions ● Allows GPL library to be linked to a non- compatible Open Source license without relicensing as GPL ● MySQL's built-in client library is covered by this ○ Except maybe a few 5.1 versions
  • 7. LGPL v2 ● Lesser (or Library) General Public License ● Allows dynamic linking with other licenses ● Doesn't allow static linking ○ becomes a derivative work ● Must include library source
  • 8. BSD Simplified ● AKA BSD New or 3-Clause BSD ● Can link to commercial software ● Very liberal simple license
  • 9. MIT ● Even more liberal than BSD ● Very simple license
  • 10. Apache 2.0 ● Can link to commercial software ● Includes patent usage grants ● License text is around 5x longer than BSD's
  • 11. PHP v3.01 ● Not compatible with GPL license ● Can link with commercial software
  • 12. License Compatibility Library GPL 2 PHP 3.01 Apache 2.0 LGPL 2.0 BSD/MIT GPL (dynamically linked) ✔ ✘* ✔ ✔ ✔ Application GPL (statically linked) ✔ ✘* ✔ ✔ ✔ Commercial (dynamically linked) ✘ ✔ ✔ ✔✝ ✔ Commercial (statically linked) ✘ ✔ ✔ ✘ ✔ * Workaround possible with FLOSS exception ✝ Need to provide lib source to end user
  • 13. Frameworks ● Only linking to framework ○ So connector license not a problem ○ Connector is loaded on-demand by the framework ○ Should be good as long as you don't distribute the connector with your application ● Examples include ○ ODBC (Open DataBase Connectivity) ○ JDBC (Java DataBase Connectivity) ○ SQLAlchemy (Python) ● Most are MIT licensed
  • 14. Licensing Resources TL;DR Legal http://www.tldrlegal.com/ GPL Compatibility Chart http://www.gnu.org/licenses/license-list.html Ask Monty Licensing FAQ https://kb.askmonty.org/en/licensing-faq/
  • 16. C libmysqlclient ● Developed by Oracle ● Bundled with MySQL ● LGPL licensed up until 3.23.58 ● GPL licensed onwards ○ Also commercial licensed ○ Has FLOSS Exception
  • 17. C Connector/C ● Developed by Sun ● An attempt to separate out the connector ● GPL licensed ○ Also has commercial license ○ Has FLOSS Exception ● No release since 2009-08-10 (6.0.2)
  • 18. C MariaDB Client Library ● Developed by Monty Program Ab and SkySQL Ab ● A fork of MySQL's 3.23 client library ○ Also contains some parts of MySQLnd ● LGPL licensed ● Features added to catch up with current API
  • 19. C/C++ Libdrizzle ● Developed by Open Source community ○ Companies such as Sun and Rackspace have been involved ● C API (some C++ in 2.0) ● BSD licensed ● Part of the main Drizzle project ● Speaks both client and server MySQL protocol
  • 20. C Libdrizzle Redux ● Developed by me ● A heavily modified version of Libdrizzle ● Still under the Drizzle umbrella ○ But different tree ● Still BSD licensed ● Server API removed ● More simplified client API ● New features ○ Binlog retrieval API ○ Compression Protocol (coming in 2013) ○ Prepared Statements (coming in 2013) ○ libmysqlclient compatible API (coming in 2013)
  • 21. C API Example Setup MySQL API conn = mysql_init(NULL); mysql_real_connect(conn, "localhost", "user", "passwd", "testdb", 0, NULL, 0); Drizzle API drizzle = drizzle_create(); con = drizzle_con_add_tcp(drizzle, "localhost", 3306, "user", "passwd", "testdb", 0); ret = drizzle_con_connect(con);
  • 22. C API Example Query MySQL API mysql_query(conn, "SELECT * FROM t1"); result = mysql_store_result(conn); num_fields = mysql_num_fields(result); while ((row = mysql_fetch_row(result))) ... Drizzle API result = drizzle_query_str(con, "select * from t1", &ret); ret = drizzle_result_buffer(result); num_fields = drizzle_result_column_count(result); while ((row = drizzle_row_next(result))) ...
  • 23. C++ Connector/C++ ● Developed by Oracle ● JDBC 4.0 API compatible ○ Although only about 80% implemented ● GPL licensed ○ Commercial also available ○ Has FLOSS Exception
  • 24. C Connector/ODBC ● Developed by Oracle ● GPL Licensed ○ With FLOSS Exception ○ Commercial available ● Is a plugin for the ODBC framework, so good for commercial
  • 25. C# Connector/NET ● Developed by Oracle ● GPL Licensed ○ With FLOSS Exception ○ Commercial available ● Implements ADO.NET interfaces
  • 27. PHP ● Three different connectors ○ mysql ○ mysqli ○ pdo_mysql ● All three use either libmysqlclient or MySQLnd
  • 28. PHP libmysqlclient based ● PHP can't link to GPL ● PHP 3 dual licensed PHP/GPL ● PHP 4 onwards licensed PHP only ○ So couldn't link to libmysqlclient ○ But libmysqlclient has FLOSS Exception ● MySQLnd instead!
  • 29. PHP MySQLnd ● Developed by Oracle ● C based MySQL client library for PHP ● Licensed under PHP license
  • 31. Python MySQLdb ● Independently developed ● GPL licensed ● Wraps around libmysqlclient ● Supports Python DB-API 2.0
  • 32. Python Connector/Python ● Developed by Oracle ● GPL licensed ○ With FLOSS exception ○ Commercial also available ● Native driver ● Supports Python DB-API 2.0
  • 33. Python Framework SQLAlchemy ● MIT licensed ● Gets around linking problem ● Uses DB-API 2.0 connectors
  • 35. Java Connector/J ● Developed by Oracle ● GPL Licensed ○ Also has commercial license ○ With FLOSS exception ● JDBC Type 4 driver ○ So no linking with app required
  • 36. Java Drizzle JDBC ● Developed by Open Source community ○ Companies such as Sun and Rackspace have been involved ● BSD Licensed ● JDBC Type 4.0 driver
  • 37. Java MariaDB Client Library for Java ● Developed by Monty Program Ab and SkySQL Ab ● A fork of Drizzle JDBC ● LGPL Licensed ● JDBC Type 4.0 driver
  • 39. Node.js ● Many available! ○ Around 10 projects ● node-mysql appears to be most prominent ○ MIT licensed ○ Appears to be a Native driver
  • 40. NoSQL Interface ● Developed by Oracle ● Included in MySQL 5.6 ● GPL Licensed ○ With a commercial version ○ Unsure about FLOSS Exception ● Based on Memcache API ● Direct access to InnoDB tables
  • 41. MySQL Cluster ● NDBAPI & MGMAPI ○ NoSQL interface ● Memcache based NoSQL interface ● Java APIs
  • 42. Plugins Possible to create things like ● UDP ● HTTP / REST Read my book to find out more:
  • 43. Thank you! My work (we're hiring!): http://hpcloud.com/ Twitter / Freenode IRC nick: LinuxJedi Email: andrew@linuxjedi.co.uk / linuxjedi@hp.com