Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
82ef6ebf
Commit
82ef6ebf
authored
Dec 30, 2010
by
antirez
Browse files
added cache-flush-delay configuration directive. Don't BGSAVE when using diskstore
parent
eea15afe
Changes
2
Show whitespace changes
Inline
Side-by-side
src/config.c
View file @
82ef6ebf
...
@@ -250,6 +250,9 @@ void loadServerConfig(char *filename) {
...
@@ -250,6 +250,9 @@ void loadServerConfig(char *filename) {
server
.
ds_path
=
sdsnew
(
argv
[
1
]);
server
.
ds_path
=
sdsnew
(
argv
[
1
]);
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"cache-max-memory"
)
&&
argc
==
2
)
{
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"cache-max-memory"
)
&&
argc
==
2
)
{
server
.
cache_max_memory
=
memtoll
(
argv
[
1
],
NULL
);
server
.
cache_max_memory
=
memtoll
(
argv
[
1
],
NULL
);
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"cache-flush-delay"
)
&&
argc
==
2
)
{
server
.
cache_flush_delay
=
atoi
(
argv
[
1
]);
if
(
server
.
cache_flush_delay
<
0
)
server
.
cache_flush_delay
=
0
;
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"hash-max-zipmap-entries"
)
&&
argc
==
2
)
{
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"hash-max-zipmap-entries"
)
&&
argc
==
2
)
{
server
.
hash_max_zipmap_entries
=
memtoll
(
argv
[
1
],
NULL
);
server
.
hash_max_zipmap_entries
=
memtoll
(
argv
[
1
],
NULL
);
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"hash-max-zipmap-value"
)
&&
argc
==
2
)
{
}
else
if
(
!
strcasecmp
(
argv
[
0
],
"hash-max-zipmap-value"
)
&&
argc
==
2
)
{
...
...
src/redis.c
View file @
82ef6ebf
...
@@ -596,7 +596,7 @@ int serverCron(struct aeEventLoop *eventLoop, long long id, void *clientData) {
...
@@ -596,7 +596,7 @@ int serverCron(struct aeEventLoop *eventLoop, long long id, void *clientData) {
}
}
updateDictResizePolicy
();
updateDictResizePolicy
();
}
}
}
else
{
}
else
if
(
!
server
.
ds_enabled
)
{
/* If there is not a background saving in progress check if
/* If there is not a background saving in progress check if
* we have to save now */
* we have to save now */
time_t
now
=
time
(
NULL
);
time_t
now
=
time
(
NULL
);
...
...
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