Package options
The following package options can be set with R’s options
function.
SciDB namespaces and roles
The global package option scidb.prefix
is designed to simplify working with SciDB user roles from R. SciDB user roles are provided by the namespaces plugin and may require issuing the query load_library('namespaces')
before use (usually performed by the SciDB system administrator). For instance, use the scidb.prefix
package option to assume a special database user role “functionary” shown in the following example:
options(scidb.prefix="set_role('functionary')")
After setting that, all queries will be prefixed with the role-setting statement. Another use case is to change the default namespace in which to look for arrays from public
to something else:
options(scidb.prefix="set_namespace('test_namespace')")
More information on SciDB permissioning and security can be found here.
You may use the scidb.prefix
option to prefix queries with arbitrary AFL statements. Separate multiple statements with the semi-colon character.
Alternatively, you may use the scidb_prefix()
function on a per-database connection level. The prefix will be displayed in the connection summary.
library(scidb)
db <- scidbconnect()
db <- scidb_prefix(db, "set_role('functionary')")
print(db)
Debugging
Set options(scidb.debug=TRUE)
to see interesting debugging information including all the issued SciDB queries.
SSL settings
Set options(scidb.verifyhost=FALSE)
to disable SSL certificate host name checking by default. This is important mostly for Amazon EC2 where hostnames rarely match their DNS names. If you enable this then the shim SSL certificate CN entry must match the server host name for the encrypted session to work. Set this TRUE for stronger security (help avoid MTM) in SSL connections.
curl options to allow long connections
Set curl options to allow long connections (some firewalls tend to drop connections for long running scidb queries – these options prevent such disconnections)
To see the full list of curl options, run curl::curl_options()
List of special DDL operators
options(scidb.ddl=c("cancel",
"create_array",
"remove",
"rename",
"sync",
"add_instances",
"remove_instances",
"unregister_instances",
"create_namespace",
"drop_namespace",
"move_array_to_namespace",
"create_role",
"create_user",
"drop_namespace",
"drop_role",
"drop_user",
"add_user_to_role",
"drop_user_from_role",
"set_namespace",
"set_role",
"set_role_permissions",
"verity_user",
"create_with_residency")