diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2018-12-10 14:25:55 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2018-12-10 14:25:55 +0200 |
commit | 1f2122af3af26803267ca8c84b0f1050333240c9 (patch) | |
tree | 06974df6fe265e03d8cb7b8f78ad271238730e58 | |
parent | 0700401f26aa83e68bf0a8e071fa891ee57bde30 (diff) | |
download | vmod-sql-1f2122af3af26803267ca8c84b0f1050333240c9.tar.gz vmod-sql-1f2122af3af26803267ca8c84b0f1050333240c9.tar.bz2 |
Version 1.3release-1.3
Supports Varnish 6.0.2
Includes improved version of wordsplit routines.
-rw-r--r-- | NEWS | 10 | ||||
m--------- | acvmod | 0 | ||||
-rwxr-xr-x | bootstrap | 2 | ||||
-rw-r--r-- | configure.ac | 8 | ||||
-rw-r--r-- | doc/vmod-sql.3 | 8 | ||||
-rw-r--r-- | src/mysql.c | 5 | ||||
-rw-r--r-- | src/pgsql.c | 5 | ||||
-rw-r--r-- | src/sql.c | 2 | ||||
-rw-r--r-- | src/vmod-sql.c | 19 | ||||
-rw-r--r-- | src/vmod-sql.h | 2 | ||||
-rw-r--r-- | src/wordsplit.c | 1646 | ||||
-rw-r--r-- | src/wordsplit.h | 214 |
12 files changed, 1485 insertions, 436 deletions
@@ -1,9 +1,13 @@ | |||
1 | vmod-sql -- history of user-visible changes. 2017-08-10 | 1 | vmod-sql -- history of user-visible changes. 2018-12-10 |
2 | Copyright (C) 2013-2017 Sergey Poznyakoff | ||
3 | See the end of file for copying conditions. | 2 | See the end of file for copying conditions. |
4 | 3 | ||
5 | Please send vmod-sql bug reports to <gray@gnu.org> | 4 | Please send vmod-sql bug reports to <gray@gnu.org> |
6 | 5 | ||
6 | Version 1.3, 2018-12-10 | ||
7 | |||
8 | * Support for Varnish 6.0.2 | ||
9 | |||
10 | |||
7 | Version 1.2, 2017-08-10 | 11 | Version 1.2, 2017-08-10 |
8 | 12 | ||
9 | * Support for Varnish 5.1 | 13 | * Support for Varnish 5.1 |
@@ -26,7 +30,7 @@ Initial release | |||
26 | ========================================================================= | 30 | ========================================================================= |
27 | Copyright information: | 31 | Copyright information: |
28 | 32 | ||
29 | Copyright (C) 2017 Sergey Poznyakoff | 33 | Copyright (C) 2013-2018 Sergey Poznyakoff |
30 | 34 | ||
31 | Permission is granted to anyone to make or distribute verbatim copies | 35 | Permission is granted to anyone to make or distribute verbatim copies |
32 | of this document as received, in any medium, provided that the | 36 | of this document as received, in any medium, provided that the |
diff --git a/acvmod b/acvmod | |||
Subproject 5f6dce2f7dd35a154333bb42d134a018b981f81 | Subproject 5b214e3d72f9e261a37cf31deb41e7f8a61a181 | ||
@@ -3,5 +3,7 @@ for dir in m4 build-aux | |||
3 | do | 3 | do |
4 | test -d $dir || mkdir $dir | 4 | test -d $dir || mkdir $dir |
5 | done | 5 | done |
6 | git submodule init | ||
7 | git submodule update | ||
6 | test -f ChangeLog || touch ChangeLog | 8 | test -f ChangeLog || touch ChangeLog |
7 | autoreconf -f -i -s | 9 | autoreconf -f -i -s |
diff --git a/configure.ac b/configure.ac index 324794f..8eae691 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1,5 +1,5 @@ | |||
1 | # This file is part of vmod-sql -*- autoconf -*- | 1 | # This file is part of vmod-sql -*- autoconf -*- |
2 | # Copyright (C) 2013-2017 Sergey Poznyakoff | 2 | # Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | # | 3 | # |
4 | # Vmod-sql is free software; you can redistribute it and/or modify | 4 | # Vmod-sql is free software; you can redistribute it and/or modify |
5 | # it under the terms of the GNU General Public License as published by | 5 | # it under the terms of the GNU General Public License as published by |
@@ -14,7 +14,7 @@ | |||
14 | # You should have received a copy of the GNU General Public License | 14 | # You should have received a copy of the GNU General Public License |
15 | # along with vmod-sql. If not, see <http://www.gnu.org/licenses/>. | 15 | # along with vmod-sql. If not, see <http://www.gnu.org/licenses/>. |
16 | AC_PREREQ(2.69) | 16 | AC_PREREQ(2.69) |
17 | AC_INIT([vmod-sql], 1.2, [gray@gnu.org]) | 17 | AC_INIT([vmod-sql], 1.3, [gray@gnu.org]) |
18 | AC_CONFIG_AUX_DIR([build-aux]) | 18 | AC_CONFIG_AUX_DIR([build-aux]) |
19 | AC_CONFIG_MACRO_DIR([m4]) | 19 | AC_CONFIG_MACRO_DIR([m4]) |
20 | AC_CONFIG_SRCDIR(src/vmod-sql.c) | 20 | AC_CONFIG_SRCDIR(src/vmod-sql.c) |
@@ -43,7 +43,9 @@ AC_PROG_MAKE_SET | |||
43 | AC_HEADER_STDC | 43 | AC_HEADER_STDC |
44 | AC_CHECK_HEADERS([sys/stdlib.h]) | 44 | AC_CHECK_HEADERS([sys/stdlib.h]) |
45 | 45 | ||
46 | AM_VARNISHAPI([4.1],[5.1]) | 46 | AM_VARNISHAPI([4.1],[6.0.2]) |
47 | AC_DEFINE_UNQUOTED([VARNISHAPI_MAJOR],[$VARNISHAPI_MAJOR], | ||
48 | [Varnish API major version number]) | ||
47 | 49 | ||
48 | ########### | 50 | ########### |
49 | # Check for SQL support | 51 | # Check for SQL support |
diff --git a/doc/vmod-sql.3 b/doc/vmod-sql.3 index 446cfbc..ad46771 100644 --- a/doc/vmod-sql.3 +++ b/doc/vmod-sql.3 | |||
@@ -1,5 +1,5 @@ | |||
1 | .\" This file is part of Vmod-sql -*- nroff -*- | 1 | .\" This file is part of Vmod-sql -*- nroff -*- |
2 | .\" Copyright (C) 2013-2014 Sergey Poznyakoff | 2 | .\" Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | .\" | 3 | .\" |
4 | .\" Vmod-sql is free software; you can redistribute it and/or modify | 4 | .\" Vmod-sql is free software; you can redistribute it and/or modify |
5 | .\" it under the terms of the GNU General Public License as published by | 5 | .\" it under the terms of the GNU General Public License as published by |
@@ -13,7 +13,7 @@ | |||
13 | .\" | 13 | .\" |
14 | .\" You should have received a copy of the GNU General Public License | 14 | .\" You should have received a copy of the GNU General Public License |
15 | .\" along with vmod-sql. If not, see <http://www.gnu.org/licenses/>. | 15 | .\" along with vmod-sql. If not, see <http://www.gnu.org/licenses/>. |
16 | .TH VMOD-SQL 1 "November 1, 2014" "VMOD-SQL" "User Reference" | 16 | .TH VMOD-SQL 3 "December 10, 2018" "VMOD-SQL" "User Reference" |
17 | .SH NAME | 17 | .SH NAME |
18 | vmod-sql \- SQL access for Varnish Cache | 18 | vmod-sql \- SQL access for Varnish Cache |
19 | .SH SYNOPSIS | 19 | .SH SYNOPSIS |
@@ -207,7 +207,7 @@ vcl_recv { | |||
207 | .\" for man-based doc pages. | 207 | .\" for man-based doc pages. |
208 | .if "\V[MANCGI]"WEBDOC" \{\ | 208 | .if "\V[MANCGI]"WEBDOC" \{\ |
209 | . ds package vmod-sql | 209 | . ds package vmod-sql |
210 | . ds version 1.0 | 210 | . ds version 1.3 |
211 | . so download.inc | 211 | . so download.inc |
212 | \} | 212 | \} |
213 | .SH "SEE ALSO" | 213 | .SH "SEE ALSO" |
@@ -253,7 +253,7 @@ Sergey Poznyakoff | |||
253 | .SH "BUG REPORTS" | 253 | .SH "BUG REPORTS" |
254 | Report bugs to <gray@gnu.org>. | 254 | Report bugs to <gray@gnu.org>. |
255 | .SH COPYRIGHT | 255 | .SH COPYRIGHT |
256 | Copyright \(co 2013 Sergey Poznyakoff | 256 | Copyright \(co 2013-2018 Sergey Poznyakoff |
257 | .br | 257 | .br |
258 | .na | 258 | .na |
259 | License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> | 259 | License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> |
diff --git a/src/mysql.c b/src/mysql.c index f113b10..3cfbe03 100644 --- a/src/mysql.c +++ b/src/mysql.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of vmod-sql | 1 | /* This file is part of vmod-sql |
2 | Copyright (C) 2013-2014 Sergey Poznyakoff | 2 | Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | 3 | ||
4 | Vmod-sql is free software; you can redistribute it and/or modify | 4 | Vmod-sql is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
@@ -211,7 +211,8 @@ s_mysql_num_tuples(struct vmod_sql_connection *conn) | |||
211 | } | 211 | } |
212 | 212 | ||
213 | static const char * | 213 | static const char * |
214 | s_mysql_get_column(struct vmod_sql_connection *conn, size_t nrow, size_t ncol) | 214 | s_mysql_get_column(struct vmod_sql_connection *conn, |
215 | unsigned nrow, unsigned ncol) | ||
215 | { | 216 | { |
216 | struct vmod_mysql_data *mp = conn->data; | 217 | struct vmod_mysql_data *mp = conn->data; |
217 | MYSQL_ROW row; | 218 | MYSQL_ROW row; |
diff --git a/src/pgsql.c b/src/pgsql.c index 9d420fc..80b316a 100644 --- a/src/pgsql.c +++ b/src/pgsql.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of vmod-sql | 1 | /* This file is part of vmod-sql |
2 | Copyright (C) 2013-2014 Sergey Poznyakoff | 2 | Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | 3 | ||
4 | Vmod-sql is free software; you can redistribute it and/or modify | 4 | Vmod-sql is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
@@ -142,7 +142,8 @@ s_pgsql_num_tuples(struct vmod_sql_connection *conn) | |||
142 | } | 142 | } |
143 | 143 | ||
144 | static const char * | 144 | static const char * |
145 | s_pgsql_get_column(struct vmod_sql_connection *conn, size_t nrow, size_t ncol) | 145 | s_pgsql_get_column(struct vmod_sql_connection *conn, |
146 | unsigned nrow, unsigned ncol) | ||
146 | { | 147 | { |
147 | struct vmod_pgsql_data *dp = conn->data; | 148 | struct vmod_pgsql_data *dp = conn->data; |
148 | 149 | ||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of vmod-sql | 1 | /* This file is part of vmod-sql |
2 | Copyright (C) 2013-2014 Sergey Poznyakoff | 2 | Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | 3 | ||
4 | Vmod-sql is free software; you can redistribute it and/or modify | 4 | Vmod-sql is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
diff --git a/src/vmod-sql.c b/src/vmod-sql.c index 689b0f7..3653f69 100644 --- a/src/vmod-sql.c +++ b/src/vmod-sql.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of vmod-sql | 1 | /* This file is part of vmod-sql |
2 | Copyright (C) 2013-2017 Sergey Poznyakoff | 2 | Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | 3 | ||
4 | Vmod-sql is free software; you can redistribute it and/or modify | 4 | Vmod-sql is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
@@ -17,13 +17,18 @@ | |||
17 | #include "vmod-sql.h" | 17 | #include "vmod-sql.h" |
18 | #include <stdarg.h> | 18 | #include <stdarg.h> |
19 | #include "wordsplit.h" | 19 | #include "wordsplit.h" |
20 | #include "vcl.h" | 20 | #if VARNISHAPI_MAJOR > 5 |
21 | #include "vrt.h" | 21 | # include "cache/cache.h" |
22 | #include "vcc_if.h" | 22 | # include "vcl.h" |
23 | #include "pthread.h" | 23 | # include "vcc_if.h" |
24 | 24 | #else | |
25 | #include "cache/cache.h" | 25 | # include "vcl.h" |
26 | # include "vrt.h" | ||
27 | # include "vcc_if.h" | ||
28 | # include "cache/cache.h" | ||
29 | #endif | ||
26 | #define WSPTR(s) ((s)->ws) | 30 | #define WSPTR(s) ((s)->ws) |
31 | #include "pthread.h" | ||
27 | 32 | ||
28 | static pthread_once_t thread_once = PTHREAD_ONCE_INIT; | 33 | static pthread_once_t thread_once = PTHREAD_ONCE_INIT; |
29 | static pthread_key_t thread_key; | 34 | static pthread_key_t thread_key; |
diff --git a/src/vmod-sql.h b/src/vmod-sql.h index 2a423fe..e171414 100644 --- a/src/vmod-sql.h +++ b/src/vmod-sql.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* This file is part of vmod-sql | 1 | /* This file is part of vmod-sql |
2 | Copyright (C) 2013-2014 Sergey Poznyakoff | 2 | Copyright (C) 2013-2018 Sergey Poznyakoff |
3 | 3 | ||
4 | Vmod-sql is free software; you can redistribute it and/or modify | 4 | Vmod-sql is free software; you can redistribute it and/or modify |
5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |