new.SonarConnection: JSON Studio connection

Description Usage Arguments Details Value See Also Examples

View source: R/new.SonarConnection.R

Description

Create a connection to a Mongo database through JSON Studio

Usage

1
2
3
new.SonarConnection(url, host, db, port = 27017, username = NULL,
  pwd = NULL, sdb = NULL, ssl = FALSE, anyCert = FALSE, krb = FALSE,
  mapCredentials = FALSE, secondaryPref = FALSE)

Arguments

url

the url where JSON Studio can be accessed

host

the hostname of the Mongo server, as it would be entered from the JSON Studio login screen

db

the name of the database you intend to access

port

the port number where Mongo is running

username

a username to log in to the database, if necessary

pwd

a password to log in to the database, if necessary

sdb

the name of a database to store JSON Studio-related collections

ssl

TRUE to connect using SSL

anyCert

TRUE to accept any SSL certificate

krb

TRUE to authenticate using Kerberos

mapCredentials

TRUE to map credentials to a functional user account with which to access data

secondaryPref

TRUE to allow connecting to a secondary of a replica set and prefer a secondary if the host value passed in is a replica set

Details

This function returns a SonarConnection object which can be used with sonarFind and sonarAgg to query a Mongo database.

The parameters for this function are explained in greater detail in the JSON Studio help page Using the Gateway.

Value

A SonarConnection object to connect to the given Mongo database through JSON Studio, which can be used with sonarFind or sonarAgg.

See Also

http://jsonstudio.com/wp-content/uploads/2014/04/manual141/_build/html/index.html

Other connection: sonarAgg; sonarCSV; sonarFind; sonarJSON

Examples

1
con <- new.SonarConnection('https://localhost:8443', 'localhost', 'test')

jSonarR documentation built on May 30, 2017, 8:16 a.m.