Interface ReactiveServerCommands
- All Known Subinterfaces:
ReactiveClusterServerCommands
public interface ReactiveServerCommands
Redis Server commands executed using reactive infrastructure.
- Since:
- 2.0
- Author:
- Mark Paluch, Christoph Strobl, Dennis Neufeld
-
Method Summary
Modifier and TypeMethodDescriptionStart an Append Only File rewrite process on server.bgSave()
Start background saving of db on server.dbSize()
Get the total number of available keys in currently selected database.flushAll()
Delete all all keys from all databases.Delete all all keys from all databases using the specifiedRedisServerCommands.FlushOption
.flushDb()
Delete all keys of the currently selected database.Delete all keys of the currently selected database using the specifiedRedisServerCommands.FlushOption
.Request information and statistics about connected clients.Returns the name of the current connection.Load configuration parameters for givenpattern
from server.info()
Load default server information like memory cpu utilization replicationLoad server information for givenselection
.killClient
(String host, int port) Closes a given client connection identified by host:port.lastSave()
Get time unix timestamp of last successfulbgSave()
operation in seconds.Reset statistic counters on server.save()
Synchronous save current db snapshot on server.setClientName
(String name) Assign given name to current connection.Set server configuration forparam
tovalue
.time()
Request server timestamp usingTIME
command inTimeUnit.MILLISECONDS
.Request server timestamp usingTIME
command.
-
Method Details
-
bgReWriteAof
Start an Append Only File rewrite process on server.- Returns:
Mono
indicating command completion.- See Also:
-
bgSave
Start background saving of db on server.- Returns:
Mono
indicating command received by server. Operation success needs to be checked vialastSave()
.- See Also:
-
lastSave
Get time unix timestamp of last successfulbgSave()
operation in seconds.- Returns:
Mono
wrapping unix timestamp.- See Also:
-
save
Synchronous save current db snapshot on server.- Returns:
Mono
indicating command completion.- See Also:
-
dbSize
Get the total number of available keys in currently selected database.- Returns:
Mono
wrapping number of keys.- See Also:
-
flushDb
Delete all keys of the currently selected database.- Returns:
Mono
indicating command completion.- See Also:
-
flushDb
Delete all keys of the currently selected database using the specifiedRedisServerCommands.FlushOption
.- Parameters:
option
-- Returns:
Mono
indicating command completion.- Since:
- 2.7
- See Also:
-
flushAll
Delete all all keys from all databases.- Returns:
Mono
indicating command completion.- See Also:
-
flushAll
Delete all all keys from all databases using the specifiedRedisServerCommands.FlushOption
.- Parameters:
option
-- Returns:
Mono
indicating command completion.- Since:
- 2.7
- See Also:
-
info
Mono<Properties> info()Load default server information like- memory
- cpu utilization
- replication
- Returns:
Mono
wrapping server information.- See Also:
-
info
Load server information for givenselection
.- Parameters:
section
- must not be null nor empty.- Returns:
Mono
wrapping server information of givensection
.- Throws:
IllegalArgumentException
- when section is null or empty.- See Also:
-
getConfig
Load configuration parameters for givenpattern
from server.- Parameters:
pattern
- must not be null.- Returns:
Mono
wrapping configuration parameters matching givenpattern
.- Throws:
IllegalArgumentException
- whenpattern
is null or empty.- See Also:
-
setConfig
Set server configuration forparam
tovalue
.- Parameters:
param
- must not be null nor empty.value
- must not be null nor empty.- Throws:
IllegalArgumentException
- whenpattern
/value
is null or empty.- See Also:
-
resetConfigStats
Reset statistic counters on server.
Counters can be retrieved usinginfo()
.- Returns:
Mono
indicating command completion.- See Also:
-
time
Request server timestamp usingTIME
command inTimeUnit.MILLISECONDS
.- Returns:
Mono
wrapping current server time in milliseconds.- See Also:
-
time
Request server timestamp usingTIME
command. -
killClient
Closes a given client connection identified by host:port.- Parameters:
host
- of connection to close. Must not be null nor empty.port
- of connection to close- Returns:
Mono
wrappingString
representation of the command result.- Throws:
IllegalArgumentException
- ifhost
is null or empty.- See Also:
-
setClientName
Assign given name to current connection.- Parameters:
name
- must not be null nor empty.- Throws:
IllegalArgumentException
- whenname
is null or empty.- See Also:
-
getClientName
Returns the name of the current connection.- Returns:
Mono
wrapping the connection name.- See Also:
-
getClientList
Flux<RedisClientInfo> getClientList()Request information and statistics about connected clients.- Returns:
Flux
emittingRedisClientInfo
objects.- See Also:
-