View Source Comtile38 (Comtile38 v0.0.1)
Entry point module of the library with all Tile38 commands functions.
The functions defined here are loaded in compile time from the
Tile38 commands documentation
The only exceptions are commands/0, command_group/1 and command_groups/0
that provide a way to look for the desired commands.
Because you don't need to remember all of them by heart
Link to this section Summary
Functions
Downloads the AOF starting from pos and keeps the connection alive
Performs a checksum on a portion of the aof
Shrinks the aof in the background
Authenticate to the server
Get the combined bounds of all the objects in a key
Finds all channels matching a pattern
Returns the commands in the given command group.
Returns the names of the command groups provided by Redis.
Returns the list of all available commands.
Get the value of a configuration parameter
Rewrite the configuration file with the in memory configuration
Set a configuration parameter to the given value
Delete an id from a key
Removes a channel
Removes a webhook
Remove a key from the database
Evaluates a Lua script
Evaluates a Lua script in a non-atomic fashion
Evaluates, in a non-atomic fashion, a Lua script cached on the server by its SHA1 digest
Evaluates a read-only Lua script
Evaluates a read-only Lua script cached on the server by its SHA1 digest
Evaluates a Lua script cached on the server by its SHA1 digest
Set a timeout on an id
Removes all keys
Follows a leader host
Set the value for one or more fields of an id
Forces a garbage collection
Get the object of an id
Finds all hooks matching a pattern
Searches for ids that intersect an area
Delete a value from a JSON document
Get a value from a JSON document
Set a value in a JSON document
Finds all keys matching the given pattern
Searches for ids that are nearby a point
Gets or sets the output format for the current connection.
Removes all objects matching a pattern
Removes all channels matching a pattern
Removes all hooks matching a pattern
Remove the existing timeout on an id
Ping the server
Subscribes the client to the given patterns
Close the connection
Turns on or off readonly mode
Rename a key to be stored under a different name.
Rename a key to be stored under a different name, if a new key does not exist.
Incrementally iterate though a key
Returns information about the existence of the scripts in server cache
Flushes the server cache of Lua scripts
Loads the compiled version of a script into the server cache, without executing
Search for string values in a key
Show server stats and details
Sets the value of an id
Creates a pubsub channel which points to geofenced search
Creates a webhook which points to geofenced search
Show stats for one or more keys
Subscribe to a geofence channel
Performs spatial test
Runs the following command with the timeout
Get a timeout on an id
Searches for ids that completely within the area
Link to this section Functions
Downloads the AOF starting from pos and keeps the connection alive
Group: replication
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
posinteger
Performs a checksum on a portion of the aof
Group: replication
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
posintegersizeinteger
Shrinks the aof in the background
Group: replication
Authenticate to the server
Group: connection
Arguments:
passwordstring
Get the combined bounds of all the objects in a key
Group: keys
Available since version 1.3.0.
Time complexity: O(1)
Arguments:
keystring
Finds all channels matching a pattern
Group: pubsub
Arguments:
pattern
Returns the commands in the given command group.
@spec command_groups() :: [atom()]
Returns the names of the command groups provided by Redis.
@spec commands() :: [atom()]
Returns the list of all available commands.
Get the value of a configuration parameter
Group: server
Arguments:
parameterstring
Rewrite the configuration file with the in memory configuration
Group: server
Set a configuration parameter to the given value
Group: server
Arguments:
parameterstringvalueoptional, string
Delete an id from a key
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstringerron404optional
Removes a channel
Group: pubsub
Arguments:
namestring
Removes a webhook
Group: webhook
Arguments:
namestring
Remove a key from the database
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystring
Evaluates a Lua script
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
scriptstringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Evaluates a Lua script in a non-atomic fashion
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
scriptstringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Evaluates, in a non-atomic fashion, a Lua script cached on the server by its SHA1 digest
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
sha1stringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Evaluates a read-only Lua script
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
scriptstringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Evaluates a read-only Lua script cached on the server by its SHA1 digest
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
scriptstringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Evaluates a Lua script cached on the server by its SHA1 digest
Group: scripting
Available since version 1.10.0.
Time complexity: Depends on the evaluated script
Arguments:
sha1stringnumkeysintegerkeyoptional, multiple, stringargoptional, multiple, string
Set a timeout on an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstringsecondsdouble
Removes all keys
Group: server
Available since version 1.0.0.
Time complexity: O(1)
Follows a leader host
Group: replication
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
hoststringportinteger
Set the value for one or more fields of an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstringxxoptionalfield_value[string, double]field_valueoptional, multiple, [string, double]
Forces a garbage collection
Group: server
Available since version 1.0.0.
Time complexity: O(1)
Get the object of an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstringwithfieldsoptionaltypeoptional
Finds all hooks matching a pattern
Group: webhook
Arguments:
pattern
Searches for ids that intersect an area
Group: search
Available since version 1.0.0.
Time complexity: O(log(N)) where N is the number of ids in the area
Arguments:
keystringcursoroptional, integerlimitoptional, integermatchoptionalwhereoptional, multiple, [string, double, double]whereinoptional, multiple, [string, integer, double]whereevaloptional, multiple, [string, integer, string]whereevalshaoptional, multiple, [string, integer, string]clipoptionalnofieldsoptionalfenceoptionaldetectoptional, [string]commandsoptional, [string]typeoptionalarea
Delete a value from a JSON document
Group: keys
Time complexity: O(1)
Arguments:
keystringidstringpathstring
Get a value from a JSON document
Group: keys
Time complexity: O(1)
Arguments:
keystringidstringpathstringrawoptional
Set a value in a JSON document
Group: keys
Time complexity: O(1)
Arguments:
keystringidstringpathstringvaluestring`` optional
Finds all keys matching the given pattern
Group: keys
Available since version 1.0.0.
Time complexity: O(N) where N is the number of keys in the database
Arguments:
pattern
Searches for ids that are nearby a point
Group: search
Available since version 1.0.0.
Time complexity: O(log(N)) where N is the number of ids in the area
Arguments:
keystringcursoroptional, integerlimitoptional, integermatchoptionaldistanceoptionalwhereoptional, multiple, [string, double, double]whereinoptional, multiple, [string, integer, double]whereevaloptional, multiple, [string, integer, string]whereevalshaoptional, multiple, [string, integer, string]nofieldsoptionalfenceoptionaldetectoptional, [string]commandsoptional, [string]typeoptionalarea
Gets or sets the output format for the current connection.
Group: connection
Arguments:
formatoptional
Removes all objects matching a pattern
Group: keys
Arguments:
keystringpattern
Removes all channels matching a pattern
Group: pubsub
Arguments:
pattern
Removes all hooks matching a pattern
Group: webhook
Arguments:
pattern
Remove the existing timeout on an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstring
Ping the server
Group: connection
Subscribes the client to the given patterns
Group: pubsub
Arguments:
pattern
Close the connection
Group: connection
Turns on or off readonly mode
Group: server
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
- `` ["yes", "no"]
Rename a key to be stored under a different name.
Group: keys
Available since version 1.14.5.
Time complexity: O(1)
Arguments:
keystringnewkeystring
Rename a key to be stored under a different name, if a new key does not exist.
Group: keys
Available since version 1.14.5.
Time complexity: O(1)
Arguments:
keystringnewkeystring
Incrementally iterate though a key
Group: search
Available since version 1.0.0.
Time complexity: O(N) where N is the number of ids in the key
Arguments:
keystringcursoroptional, integerlimitoptional, integermatchoptionalorderoptionalwhereoptional, multiple, [string, double, double]whereinoptional, multiple, [string, integer, double]whereevaloptional, multiple, [string, integer, string]whereevalshaoptional, multiple, [string, integer, string]nofieldsoptionaltypeoptional
Returns information about the existence of the scripts in server cache
Group: scripting
Available since version 1.10.0.
Time complexity: O(N) where N is the number of provided sha1 arguments
Arguments:
sha1multiple, string
Flushes the server cache of Lua scripts
Group: scripting
Available since version 1.10.0.
Time complexity: O(1)
Loads the compiled version of a script into the server cache, without executing
Group: scripting
Available since version 1.10.0.
Time complexity: O(N) where N is the number of bytes in the script
Arguments:
scriptstring
Search for string values in a key
Group: search
Available since version 1.4.2.
Time complexity: O(N) where N is the number of values in the key
Arguments:
keystringcursoroptional, integerlimitoptional, integermatchoptionalorderoptionalwhereoptional, multiple, [string, double, double]whereinoptional, multiple, [string, integer, double]whereevaloptional, multiple, [string, integer, string]whereevalshaoptional, multiple, [string, integer, string]nofieldsoptionaltypeoptional
Show server stats and details
Group: server
Available since version 1.0.0.
Time complexity: O(1)
Sets the value of an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstringfieldoptional, multiple, [string, double]exoptional, [double]typeoptionalvalue
Creates a pubsub channel which points to geofenced search
Group: pubsub
Arguments:
namestringmetaoptional, multiple, [string, string]exoptional, [double]` ["NEARBY", "WITHIN", "INTERSECTS"] *keystring *fence*detectoptional, [string] *commandsoptional, [string] *param` string
Creates a webhook which points to geofenced search
Group: webhook
Arguments:
namestringendpointstringmetaoptional, multiple, [string, string]exoptional, [double]` ["NEARBY", "WITHIN", "INTERSECTS"] *keystring *fence*detectoptional, [string] *commandsoptional, [string] *param` string
Show stats for one or more keys
Group: keys
Available since version 1.0.0.
Time complexity: O(N) where N is the number of keys being requested
Arguments:
keystring
Subscribe to a geofence channel
Group: pubsub
Arguments:
channelstring
Performs spatial test
Group: tests
Available since version 1.16.0.
Time complexity: One test per command, complexity depends on the test
Arguments:
area1testclipoptionalarea2
Runs the following command with the timeout
Group: connection
Arguments:
secondsdoublecommandstringargoptional, multiple, string
Get a timeout on an id
Group: keys
Available since version 1.0.0.
Time complexity: O(1)
Arguments:
keystringidstring
Searches for ids that completely within the area
Group: search
Available since version 1.0.0.
Time complexity: O(log(N)) where N is the number of ids in the area
Arguments:
keystringcursoroptional, integerlimitoptional, integermatchoptionalwhereoptional, multiple, [string, double, double]whereinoptional, multiple, [string, integer, double]whereevaloptional, multiple, [string, integer, string]whereevalshaoptional, multiple, [string, integer, string]nofieldsoptionalfenceoptionaldetectoptional, [string]commandsoptional, [string]typeoptionalarea