Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to pass an object to createCUBRIDConnection() #27

Closed
kadishmal opened this issue Feb 1, 2015 · 1 comment
Closed

Allow to pass an object to createCUBRIDConnection() #27

kadishmal opened this issue Feb 1, 2015 · 1 comment
Assignees
Milestone

Comments

@kadishmal
Copy link
Contributor

Migrated from http://jira.cubrid.org/browse/APIS-592.

The current API is:

/**
 * Creates a new connection
 * @param brokerServer
 * @param brokerPort
 * @param user
 * @param password
 * @param database
 * @return {*}
 */
exports.createCUBRIDConnection = function (brokerServer, brokerPort, user, password, database) {
  return new _CUBRIDConnection(brokerServer, brokerPort, user, password, database);
};

This requires to connect to CUBRID Broker as follows:

var conn = CUBRID.createCUBRIDConnection(conf.cubrid.host, conf.cubrid.port, conf.cubrid.user, conf.cubrid.password, conf.cubrid.dbname);

It would be convenient to have the following option:

var conf = {
      cubrid: {
        host: '',
        user: '',
        password: '',
        dbname: ''
      }
};

var conn = CUBRID.createCUBRIDConnection(conf.cubrid);
@kadishmal kadishmal self-assigned this Feb 1, 2015
@kadishmal kadishmal added this to the v2.1.0 milestone Feb 1, 2015
@kadishmal
Copy link
Contributor Author

Implemented in v2.1.0 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant