Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
90b82673
Commit
90b82673
authored
Aug 18, 2014
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Retire various struct object related infrastructure.
parent
bdc6f734
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
1 addition
and
74 deletions
+1
-74
cache_ban.c
bin/varnishd/cache/cache_ban.c
+0
-3
cache_cli.c
bin/varnishd/cache/cache_cli.c
+0
-23
cache_expire.c
bin/varnishd/cache/cache_expire.c
+0
-6
cache_hash.c
bin/varnishd/cache/cache_hash.c
+1
-40
hash_slinger.h
bin/varnishd/hash/hash_slinger.h
+0
-2
No files found.
bin/varnishd/cache/cache_ban.c
View file @
90b82673
...
...
@@ -1058,7 +1058,6 @@ ban_lurker_test_ban(struct worker *wrk, struct vsl_log *vsl, struct ban *bt,
{
struct
ban
*
bl
,
*
bln
;
struct
objcore
*
oc
;
struct
object
*
o
;
unsigned
tests
;
int
i
;
...
...
@@ -1081,8 +1080,6 @@ ban_lurker_test_ban(struct worker *wrk, struct vsl_log *vsl, struct ban *bt,
oc
=
ban_lurker_getfirst
(
vsl
,
bt
);
if
(
oc
==
NULL
)
return
;
o
=
ObjGetObj
(
oc
,
&
wrk
->
stats
);
CHECK_OBJ_NOTNULL
(
o
,
OBJECT_MAGIC
);
i
=
0
;
VTAILQ_FOREACH_REVERSE_SAFE
(
bl
,
obans
,
banhead_s
,
l_list
,
bln
)
{
if
(
bl
->
flags
&
BANS_FLAG_COMPLETED
)
{
...
...
bin/varnishd/cache/cache_cli.c
View file @
90b82673
...
...
@@ -178,29 +178,6 @@ cli_debug_sizeof(struct cli *cli, const char * const *av, void *priv)
OFOF(struct storage, len);
OFOF(struct storage, space);
#endif
#if 0
OFOF(struct object, magic);
OFOF(struct object, xid);
OFOF(struct object, objstore);
OFOF(struct object, objcore);
OFOF(struct object, ws_o);
OFOF(struct object, vary);
OFOF(struct object, hits);
OFOF(struct object, response);
OFOF(struct object, gziped);
OFOF(struct object, gzip_start);
OFOF(struct object, gzip_last);
OFOF(struct object, gzip_stop);
OFOF(struct object, len);
OFOF(struct object, age);
OFOF(struct object, entered);
OFOF(struct object, exp);
OFOF(struct object, last_modified);
OFOF(struct object, last_lru);
OFOF(struct object, http);
OFOF(struct object, store);
OFOF(struct object, esidata);
#endif
#undef OFOF
#endif
}
...
...
bin/varnishd/cache/cache_expire.c
View file @
90b82673
...
...
@@ -353,7 +353,6 @@ exp_inbox(struct exp_priv *ep, struct objcore *oc, double now)
{
unsigned
flags
;
struct
lru
*
lru
;
struct
object
*
o
;
CHECK_OBJ_NOTNULL
(
ep
,
EXP_PRIV_MAGIC
);
CHECK_OBJ_NOTNULL
(
oc
,
OBJCORE_MAGIC
);
...
...
@@ -391,8 +390,6 @@ exp_inbox(struct exp_priv *ep, struct objcore *oc, double now)
}
if
(
flags
&
OC_EF_MOVE
)
{
o
=
ObjGetObj
(
oc
,
&
ep
->
wrk
->
stats
);
CHECK_OBJ_NOTNULL
(
o
,
OBJECT_MAGIC
);
oc
->
timer_when
=
EXP_When
(
&
oc
->
exp
);
ObjUpdateMeta
(
oc
,
&
ep
->
wrk
->
stats
);
}
...
...
@@ -428,7 +425,6 @@ exp_expire(struct exp_priv *ep, double now)
{
struct
lru
*
lru
;
struct
objcore
*
oc
;
struct
object
*
o
;
CHECK_OBJ_NOTNULL
(
ep
,
EXP_PRIV_MAGIC
);
...
...
@@ -466,8 +462,6 @@ exp_expire(struct exp_priv *ep, double now)
assert
(
oc
->
timer_idx
==
BINHEAP_NOIDX
);
CHECK_OBJ_NOTNULL
(
oc
->
objhead
,
OBJHEAD_MAGIC
);
o
=
ObjGetObj
(
oc
,
&
ep
->
wrk
->
stats
);
CHECK_OBJ_NOTNULL
(
o
,
OBJECT_MAGIC
);
VSLb
(
&
ep
->
vsl
,
SLT_ExpKill
,
"EXP_Expired x=%u t=%.0f"
,
ObjGetXID
(
oc
,
&
ep
->
wrk
->
stats
),
EXP_Ttl
(
NULL
,
&
oc
->
exp
)
-
now
);
...
...
bin/varnishd/cache/cache_hash.c
View file @
90b82673
...
...
@@ -609,22 +609,6 @@ double keep)
Pool_PurgeStat
(
nobj
);
}
/*---------------------------------------------------------------------
* Kill a busy object we don't need and can't use.
*/
void
HSH_Drop
(
struct
worker
*
wrk
,
struct
object
**
oo
)
{
CHECK_OBJ_NOTNULL
(
wrk
,
WORKER_MAGIC
);
AN
(
oo
);
CHECK_OBJ_NOTNULL
(
*
oo
,
OBJECT_MAGIC
);
(
*
oo
)
->
objcore
->
exp
.
ttl
=
-
1
.;
AZ
(
HSH_DerefObj
(
&
wrk
->
stats
,
oo
));
}
/*---------------------------------------------------------------------
* Fail an objcore
*/
...
...
@@ -747,34 +731,11 @@ HSH_RefBusy(const struct objcore *oc)
}
/*--------------------------------------------------------------------
* Dereference objcore and or object
*
* Can deal with:
* bare objcore (incomplete fetch)
* bare object (pass)
* object with objcore
* XXX later: objcore with object (?)
*
* But you can only supply one of the two arguments at a time.
* Dereference objcore
*
* Returns zero if target was destroyed.
*/
int
HSH_DerefObj
(
struct
dstat
*
ds
,
struct
object
**
oo
)
{
struct
object
*
o
;
struct
objcore
*
oc
;
AN
(
oo
);
o
=
*
oo
;
*
oo
=
NULL
;
CHECK_OBJ_NOTNULL
(
o
,
OBJECT_MAGIC
);
oc
=
o
->
objcore
;
return
(
HSH_DerefObjCore
(
ds
,
&
oc
));
}
int
HSH_DerefObjCore
(
struct
dstat
*
ds
,
struct
objcore
**
ocp
)
{
...
...
bin/varnishd/hash/hash_slinger.h
View file @
90b82673
...
...
@@ -66,7 +66,6 @@ void HSH_Cleanup(struct worker *w);
enum
lookup_e
HSH_Lookup
(
struct
req
*
,
struct
objcore
**
,
struct
objcore
**
,
int
wait_for_busy
,
int
always_insert
);
void
HSH_Ref
(
struct
objcore
*
o
);
void
HSH_Drop
(
struct
worker
*
,
struct
object
**
);
void
HSH_Init
(
const
struct
hash_slinger
*
slinger
);
void
HSH_AddString
(
const
struct
req
*
,
const
char
*
str
);
void
HSH_Insert
(
struct
worker
*
,
const
void
*
hash
,
struct
objcore
*
);
...
...
@@ -117,7 +116,6 @@ void HSH_Complete(struct objcore *oc);
void
HSH_DeleteObjHead
(
struct
dstat
*
,
struct
objhead
*
oh
);
int
HSH_DerefObjHead
(
struct
dstat
*
,
struct
objhead
**
poh
);
int
HSH_DerefObjCore
(
struct
dstat
*
,
struct
objcore
**
ocp
);
int
HSH_DerefObj
(
struct
dstat
*
,
struct
object
**
o
);
#endif
/* VARNISH_CACHE_CHILD */
extern
const
struct
hash_slinger
hsl_slinger
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment