Skip to content

gkodinov/mysql_httpd_table_access

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

A sample MySQLD component implementing a http server using libmicrohttpd.

ATTENTION! THIS IS NOT PRODUCTION CODE! USE AT YOUR OWN RISK! IT DOESN'T DO ANY AUTHENTICATION!

To compile:

  1. fetch the mysql-8.0 source code: git clone https://github.com/mysql/mysql-server mysql-server
  2. put the component source in components/httpd_table: cd mysql-server/components; git clone https://github.com/gkodinov/mysql_httpd_table_access.git httpd_table
  3. procure libmicrohttpd and compile it or download the binaries from https://www.gnu.org/software/libmicrohttpd/
  4. compile the server and the component, e.g. cmake -DWITH_MICROHTTPD= ..
  5. start mysqld with the right --plugin-dir containing the component binary
  6. create the httpd.replies SQL table by running init.sql against the server
  7. INSTALL COMPONENT "file:https://component_httpd_table";
  8. Access the HTTP server at port 18080, e.g. http:https://localhost:18080?id=1

About

A sample MySQLD component implementing an HTTP server serving data from a table

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published