How to use the azure-common.ServiceClient function in azure-common

To help you get started, we’ve selected a few azure-common examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Azure / azure-sdk-for-node / test / services / blob / blobservice-tests.js View on Github external
// Test includes
var testutil = require('../../util/util');
var blobtestutil = require('../../framework/blob-test-utils');

// Lib includes
var common = require('azure-common');
var storage = testutil.libRequire('services/legacyStorage');

var azureutil = common.util;
var azure = testutil.libRequire('azure');
var WebResource = common.WebResource;

var SharedAccessSignature = storage.SharedAccessSignature;
var BlobService = storage.BlobService;
var ServiceClient = common.ServiceClient;
var ExponentialRetryPolicyFilter = common.ExponentialRetryPolicyFilter;
var Constants = common.Constants;
var BlobConstants = Constants.BlobConstants;
var HttpConstants = Constants.HttpConstants;
var ServiceClientConstants = common.ServiceClientConstants;
var QueryStringConstants = Constants.QueryStringConstants;

var containerNames = [];
var containerNamesPrefix = 'cont';

var blobNames = [];
var blobNamesPrefix = 'blob';

var testPrefix = 'blobservice-tests';

var blobService;
github Azure / azure-sdk-for-node / test / services / table / querytablesresultcontinuation-tests.js View on Github external
// limitations under the License.
//

var assert = require('assert');

// Test includes
var testutil = require('../../util/util');
var tabletestutil = require('../../framework/table-test-utils');

// Lib includes
var common = require('azure-common');
var storage = require('azure-storage-legacy');
var azureutil = common.util;
var testutil = testutil.libRequire('common/lib/util/util');

var ServiceClient = common.ServiceClient;
var TableQuery = storage.TableQuery;
var Constants = common.Constants;
var HttpConstants = Constants.HttpConstants;
var StorageErrorCodeStrings = Constants.StorageErrorCodeStrings;

var tableService;
var tableNames = [];
var tablePrefix = 'tablecont';

suite('querytablesresultcontinuation-tests', function () {
  setup(function (done) {
    tableService = storage.createTableService()
      .withFilter(new common.ExponentialRetryPolicyFilter());

    done();
  });
github Azure / azure-sdk-for-node / test / services / table / tabledatatype-tests.js View on Github external
//

var assert = require('assert');
var _ = require('underscore');

// Test includes
var testutil = require('../../util/util');
var tabletestutil = require('../../framework/table-test-utils');

// Lib includes
var common = require('azure-common');
var storage = require('azure-storage-legacy');

var azureutil = common.util;

var ServiceClient = common.ServiceClient;
var TableQuery = storage.TableQuery;
var Constants = common.Constants;
var HttpConstants = Constants.HttpConstants;
var StorageErrorCodeStrings = Constants.StorageErrorCodeStrings;

var tableNames = [];
var tablePrefix = 'tabledatatype';

var testPrefix = 'tabledatatype-tests';

var tableService;
var suiteUtil;

describe('Table Service', function () {
  before(function (done) {
    tableService = storage.createTableService()
github Azure / azure-sdk-for-node / lib / services / webSiteManagement / lib / scmservice.js View on Github external
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// 
// See the License for the specific language governing permissions and
// limitations under the License.
// 

// Module dependencies.
var url = require('url');
var util = require('util');

var azureCommon = require('azure-common');
var azureutil = azureCommon.util;

var ServiceClient = azureCommon.ServiceClient;
var WebResource = azureCommon.WebResource;
var Constants = azureCommon.Constants;

var HeaderConstants = Constants.HeaderConstants;

/**
*
* Creates a new ScmService object.
* @class
* The ScmService object allows you to perform management operations on Windows Azure Web Sites Repositories.
* @constructor
*
* @param {object} authentication                                       The authentication object for the client.
*                                                                      You must use a auth/pass for basic authentication.
* @param {string} [authentication.user]                                The basic authentication username.
* @param {string} [authentication.pass]                                The basic authentication password.
github BabylonJS / Extensions / LeaderBoard / Zumo / service / node_modules / azure / lib / azure.js View on Github external
* @return {CertificateCloudCredentials}
*/
exports.createCertificateCloudCredentials = azureCommon.createCertificateCloudCredentials;

/**
* Creates a new BasicAuthenticationCloudCredentials object.
* Either a pair of cert / key values need to be pass or a pem file location.
*
* @param {string} credentials.username            The username.
* @param {string} credentials.password            The password.
* @return {BasicAuthenticationCloudCredentials}
*/
exports.createBasicAuthenticationCloudCredentials = azureWebSite.createBasicAuthenticationCloudCredentials;

exports.Constants = azureCommon.Constants;
exports.ServiceClient = azureCommon.ServiceClient;
exports.ServiceClientConstants = azureCommon.ServiceClientConstants;
exports.ConnectionStringParser = azureCommon.ConnectionStringParser;
exports.Logger = azureCommon.Logger;
exports.WebResource = azureCommon.WebResource;
exports.Validate = azureCommon.validate;
exports.date = azureCommon.date;

exports.ServiceSettings = azureCommon.ServiceSettings;
exports.ServiceBusSettings = azureCommon.ServiceBusSettings;
exports.ServiceManagementSettings = azureCommon.ServiceManagementSettings;
exports.StorageServiceSettings = azureCommon.StorageServiceSettings;

// Credentials
exports.CertificateCloudCredentials = azureCommon.CertificateCloudCredentials;
exports.TokenCloudCredentials = azureCommon.TokenCloudCredentials;
exports.AnonymousCloudCredentials = azureCommon.AnonymousCloudCredentials;
github Azure / azure-xplat-cli / lib / util / communityUtil.js View on Github external
//   http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//
// See the License for the specific language governing permissions and
// limitations under the License.
//

// Module dependencies.
var url = require('url');
var util = require('util');

var azureCommon = require('azure-common');
var ServiceClient = azureCommon.ServiceClient;
var WebResource = azureCommon.WebResource;
var Constants = azureCommon.Constants;
var HeaderConstants = Constants.HeaderConstants;

// Expose 'CommunityUtil'.
exports = module.exports = CommunityUtil;

/**
* Creates a new CommunityUtil object.
*
* @constructor
*/
function CommunityUtil(managementEndPoint) {
  CommunityUtil['super_'].call(this);
  var serviceHost = 'vmdepot.msopentech.com';
  var managementEndPointAsUrl = url.parse(managementEndPoint);
github Azure / azure-sdk-for-node / lib / azure.js View on Github external
* @return {CertificateCloudCredentials}
 */
exports.createCertificateCloudCredentials = azureCommon.createCertificateCloudCredentials;

/**
 * Creates a new BasicAuthenticationCloudCredentials object.
 * Either a pair of cert / key values need to be pass or a pem file location.
 * @method
 * @param {string} credentials.username            The username.
 * @param {string} credentials.password            The password.
 * @return {BasicAuthenticationCloudCredentials}
 */
exports.createBasicAuthenticationCloudCredentials = azureWebSite.createBasicAuthenticationCloudCredentials;

exports.Constants = azureCommon.Constants;
exports.ServiceClient = azureCommon.ServiceClient;
exports.ServiceClientConstants = azureCommon.ServiceClientConstants;
exports.ConnectionStringParser = azureCommon.ConnectionStringParser;
exports.Logger = azureCommon.Logger;
exports.WebResource = azureCommon.WebResource;
exports.Validate = azureCommon.validate;
exports.date = azureCommon.date;

exports.ServiceSettings = azureCommon.ServiceSettings;
exports.ServiceBusSettings = azureCommon.ServiceBusSettings;
exports.ServiceManagementSettings = azureCommon.ServiceManagementSettings;
exports.StorageServiceSettings = azureCommon.StorageServiceSettings;

// Credentials
exports.CertificateCloudCredentials = azureCommon.CertificateCloudCredentials;
exports.TokenCloudCredentials = azureCommon.TokenCloudCredentials;
exports.AnonymousCloudCredentials = azureCommon.AnonymousCloudCredentials;
github Azure / azure-sdk-for-node / lib / services / sql / sqlserveracs.js View on Github external
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// 
// See the License for the specific language governing permissions and
// limitations under the License.
// 

// Module dependencies.
var util = require('util');
var url = require('url');
var _ = require('underscore');

var azureCommon = require('azure-common');
var azureutil = azureCommon.util;
var ServiceClient = azureCommon.ServiceClient;

var WebResource = azureCommon.WebResource;
var Constants = azureCommon.Constants;
var SqlAzureConstants = Constants.SqlAzureConstants;

function escapeConnectionCredentials(value) {
  return value.replace(/\\/g, /\\\\/g).replace(/:/g, /\\:/g);
}

/**
* Creates a new SqlServerAcs object.
*
* @param {string} acsHost                      The access control host.
* @param {string} serverName                   The SQL server name.
* @param {string} administratorLogin           The administrator login.
* @param {string} administratorLoginPassword   The administrator login password.
github Azure / azure-sdk-for-node / lib / azure.js View on Github external
exports.isEmulated = function (host) {
  return azureCommon.ServiceClient.isEmulated(host);
};
github BabylonJS / Extensions / LeaderBoard / Zumo / service / node_modules / azure / lib / azure.js View on Github external
exports.isEmulated = function (host) {
  return azureCommon.ServiceClient.isEmulated(host);
};