r3025 - trunk/varnish-cache/bin/varnishd

phk at projects.linpro.no phk at projects.linpro.no
Fri Jul 25 17:27:04 CEST 2008


Author: phk
Date: 2008-07-25 17:27:04 +0200 (Fri, 25 Jul 2008)
New Revision: 3025

Modified:
   trunk/varnish-cache/bin/varnishd/Makefile.am
   trunk/varnish-cache/bin/varnishd/cache_main.c
   trunk/varnish-cache/bin/varnishd/stevedore.c
   trunk/varnish-cache/bin/varnishd/stevedore.h
   trunk/varnish-cache/bin/varnishd/storage_file.c
   trunk/varnish-cache/bin/varnishd/storage_malloc.c
Log:
Add a stevedore for synthetic pages.

The storage from this stevedore is backed by an autoextending vsb, which
can be used to generate synthetic pages into.



Modified: trunk/varnish-cache/bin/varnishd/Makefile.am
===================================================================
--- trunk/varnish-cache/bin/varnishd/Makefile.am	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/Makefile.am	2008-07-25 15:27:04 UTC (rev 3025)
@@ -51,6 +51,7 @@
 	stevedore.c \
 	storage_file.c \
 	storage_malloc.c \
+	storage_synth.c \
 	tcp.c \
 	varnishd.c
 

Modified: trunk/varnish-cache/bin/varnishd/cache_main.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/cache_main.c	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/cache_main.c	2008-07-25 15:27:04 UTC (rev 3025)
@@ -121,6 +121,7 @@
 
 	VCA_Init();
 
+	SMS_Init();
 	STV_open();
 
 	VSL_stats->start_time = (time_t)TIM_real();

Modified: trunk/varnish-cache/bin/varnishd/stevedore.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/stevedore.c	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/stevedore.c	2008-07-25 15:27:04 UTC (rev 3025)
@@ -83,7 +83,7 @@
 }
 
 void
-STV_free(const struct storage *st)
+STV_free(struct storage *st)
 {
 
 	CHECK_OBJ_NOTNULL(st, STORAGE_MAGIC);

Modified: trunk/varnish-cache/bin/varnishd/stevedore.h
===================================================================
--- trunk/varnish-cache/bin/varnishd/stevedore.h	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/stevedore.h	2008-07-25 15:27:04 UTC (rev 3025)
@@ -39,7 +39,7 @@
 typedef void storage_open_f(const struct stevedore *);
 typedef struct storage *storage_alloc_f(struct stevedore *, size_t size);
 typedef void storage_trim_f(const struct storage *, size_t size);
-typedef void storage_free_f(const struct storage *);
+typedef void storage_free_f(struct storage *);
 
 struct stevedore {
 	unsigned		magic;
@@ -59,6 +59,9 @@
 
 struct storage *STV_alloc(struct sess *sp, size_t size);
 void STV_trim(const struct storage *st, size_t size);
-void STV_free(const struct storage *st);
+void STV_free(struct storage *st);
 void STV_add(const struct stevedore *stv, int ac, char * const *av);
 void STV_open(void);
+
+/* Synthetic Storage */
+void SMS_Init(void);

Modified: trunk/varnish-cache/bin/varnishd/storage_file.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/storage_file.c	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/storage_file.c	2008-07-25 15:27:04 UTC (rev 3025)
@@ -681,7 +681,7 @@
 /*--------------------------------------------------------------------*/
 
 static void
-smf_free(const struct storage *s)
+smf_free(struct storage *s)
 {
 	struct smf *smf;
 	struct smf_sc *sc;

Modified: trunk/varnish-cache/bin/varnishd/storage_malloc.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/storage_malloc.c	2008-07-25 14:53:08 UTC (rev 3024)
+++ trunk/varnish-cache/bin/varnishd/storage_malloc.c	2008-07-25 15:27:04 UTC (rev 3025)
@@ -86,7 +86,7 @@
 }
 
 static void
-sma_free(const struct storage *s)
+sma_free(struct storage *s)
 {
 	struct sma *sma;
 




More information about the varnish-commit mailing list