From a331c1f677c4ee47b0b46f720cf7353cec23f194 Mon Sep 17 00:00:00 2001 From: Magnus Hagander Date: Sun, 11 Dec 2011 14:15:41 +0100 Subject: [PATCH] Add a varnish_purge() function to be used in local installs --- sql/varnish_local.sql | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 sql/varnish_local.sql diff --git a/sql/varnish_local.sql b/sql/varnish_local.sql new file mode 100644 index 00000000..cb3a9340 --- /dev/null +++ b/sql/varnish_local.sql @@ -0,0 +1,15 @@ +BEGIN; + +-- +-- "cheating" version of the varnish_purge() function +-- that can be used on a local installation that doesn't +-- have any frontends. +-- + +CREATE OR REPLACE FUNCTION varnish_purge(url text) +RETURNS bigint +AS $$ + SELECT 1::bigint; +$$ LANGUAGE 'sql'; + +COMMIT; \ No newline at end of file