コード例 #1
0
        /// <summary>
        /// Initializes the document client.
        /// </summary>
        /// <returns>Task that denotes opening client</returns>
        private Task InitializeDocumentClientAsync()
        {
            if (this.client == null)
            {
                var documentDbContext = new DocumentDbContext();
                this.client = documentDbContext.GetDocumentClient(this.connectionString, this.retryCount, this.retryInterval);
            }

            return(this.client.OpenAsync());
        }