ICode9

精准搜索请尝试: 精确搜索
  • java-必须为此操作提供PartitionKey值2019-12-11 04:02:45

    我正在尝试从Azure Cosmos Db集合中检索文档.我遇到一个错误 Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is java.lang.UnsupportedOperationException: PartitionKey value must

  • c#-Azure Functions DocumentClient无法从程序集异常加载类型2019-12-11 02:05:43

    我有一个调用了实用程序库的Azure Function v2,该库又实例化了DocumentClient.在本地运行我的函数时,此行将引发异常: _client = new DocumentClient(new Uri(cosmosDbEndpoint), cosmosDbAuthKey, Storage.SerializerSettings, connectionPolicy); System.Private.CoreLib: Exce

  • java-Cosmosdb保存的数据无法在门户中找到,但可以从azure-documentdb-spring-boot-starter中找到2019-11-10 19:01:45

    我的项目使用azure-documentdb-spring-boot-starter:0.2.0与cosmosdb进行交互: @Repository public interface PingEasyRepo extends DocumentDbRepository<PingEasy, String> { } @Document(collection = "test") public class PingEasy { @Id private Strin

  • c#-实现自定义BotState服务后,Cosmos DB引发“找不到资源”错误2019-11-10 15:16:12

    我们最近更新了我们的机器人,使用以下文章将其从即将弃用的默认BotState服务迁移到Azure Cosmos DB存储中: https://docs.microsoft.com/en-us/bot-framework/dotnet/bot-builder-dotnet-state-azure-cosmosdb 以下模块在会话容器中的Application_Start方法中注册: public class Cus

  • c#-DocumentDB Upsert和Replace不会改变复杂的属性吗?2019-10-27 11:07:59

    使用“ Microsoft.Azure.DocumentDB”:“ 1.5.2”我遇到了复杂对象正确保存到数据库的问题.它们的初始存储似乎可以,但是仅对复杂结构的较深部分进行更改时,Upsert或Replace似乎无法正确更新文档. 我有一个看起来像这样的对象(有些改动,缩减了版本)… public class Profile : Docum

  • javascript – 如何使用版本^ 3上的gremlin与CosmoDB图形数据库建立新连接2019-09-10 15:42:39

    我试图在节点js中创建一个新的gremlin客户端,但我找不到任何文档如何设置与URL和主键(在Azure CosmosDB中生成)的连接. 有关如何在版本<中执行此操作的示例v3,例如here. 有关新版本gremlin的文档可在new documentation上获得,但它没有解释如何将主键放入对象中(包也不是很清楚,我试

  • javascript – CosmosDB:如何查询嵌套在json数组中的值的存在?2019-08-28 09:37:46

    我的数据库实例包含一些具有以下模式的文档: { id: <someGuid> myJsonArray: [ { subId: SmallUniqueId1, val: <someValue> }, { subId: SmallUniqueId2, val: <someOtherValue> }

  • c# – 如何(我应该)模拟DocumentClb进行DocumentDb单元测试?2019-07-10 17:05:44

    从新的CosmosDb模拟器我得到了一个存储库来执行基本的documentdb操作,这个存储库被注入其他类.我想对基本查询进行单元测试. public class DocumentDBRepository<T> where T : class { //Details ommited... public IQueryable<T> GetQueryable() { return _cli

  • c# – Cosmos DB – CreateDocumentQuery不反序列化抽象类型2019-07-10 17:05:25

    我试图让Cosmos DB .NET SDK v1.19.1使用Json.net序列化设置自动将对象反序列化为正确的类型.除了查询文档时,这似乎工作正常.以下面的代码为例: public abstract class Shape { public int Area { get; set; } } public class Square : Shape { } pu

  • c# – OData和Cosmos DB2019-07-10 13:06:48

    我正在寻找实现OData v4作为我正在使用的ASP.NET核心应用程序中的查询工具,我们的支持持久性存储是Cosmos DB.到目前为止,我还没有找到一种方法可以在不遇到某种异常或错误的情况下对DocumentQuery IQueryable接口运行OData查询. 我想知道是否有一种“干净”的方式来利用OData来对

  • c# – DocumentDB STARTSWITH无法使用.NET2019-07-06 09:07:38

    我有一个名为Customer的集合,每个条目都有一个名为Number的属性.以下是select all命令的内容: [ { "Number": "K1", "Label": "Test1" }, { "Number": "T1", "Label": "

  • c# – 在Cosmos DB中重试策略2019-07-05 20:07:56

    我想了解如何最好地为cosmos db(documentdb)实现重试/退避策略. 据我所知,sdk中内置了一些默认的重试机制,我可以在connectionpolicy中进行更改,如下所示: RetryOptions = new RetryOptions() { MaxRetryAttemptsOnThrottledRequests = 3, MaxRetryWaitTimeInSeconds = 60 } 但是,

  • c# – 与LINQ一起使用时,CreateDocumentQuery抛出异常,很好用SQL2019-07-03 03:05:49

    我正在尝试检索存储在Azure DocumentDb中的单个实体.我发现我的代码仅在我通过SQL提供查询时才有效,如下所示: var query = String.Format("SELECT * FROM UserDetail u WHERE u.id = '{0}'", id); return _client.CreateDocumentQuery<TEntity>(_selfLink, query).AsEnumerable().

  • c# – 使用SQL查询在单元测试中模拟IDocumentQuery2019-06-27 11:54:01

    我正在使用单元测试来测试DocumentDBRepository类.我以this post作为SQL查询用例的示例.但它显示错误 Message: System.InvalidCastException : Unable to cast object of type ‘System.Linq.EnumerableQuery to type ‘Microsoft.Azure.Documents.Linq.IDocumentQuery

  • c# – DocumentDB – 输入名称无效.确保提供小于’255’字符的唯一非空字符串2019-06-09 05:51:53

    我试图将数据插入Azure DocumentDb,但是我收到以下错误 The input name "123456" is invalid. Ensure to provide a unique non-empty string less than '255' characters.","The request payload is invalid. Ensure to provide a valid request payload."

  • 从Android连接到Azure DocumentDB2019-05-28 14:13:52

    有没有人经历过从android连接到Azure的documentdb?我尝试过使用新的Java SDK,但由于核心android SDK中存在一些旧的必需Apache依赖冲突,因此它似乎在android中不受支持.我正在尝试Rest API方法,但它很慢. 在此先感谢您的帮助!解决方法:好吧,这是一个要解决的噩梦.九个小时后…… -_-

  • c# – DocumentDB客户端生命周期2019-05-27 13:54:37

    要访问DocumentDB / CosmosDB,我使用的是Microsoft.Azure.DocumentDB.Core包(v1.3.2).当我创建和初始化DocumentClient类时,我注意到了: var documentClient = new DocumentClient(new Uri(endpointUrl), primaryKey); await documentClient.OpenAsync(); 向端点发出了许多请求以

  • c# – 如何从带有guid id的集合中进行选择?2019-05-19 09:54:06

    我有这个带有guid id的集合.当我使用Azure Query Explorer并在上面的组合框中选择了集合时,它可以: SELECT * FROM c 但是当我尝试选择它时(来自查询exlorer和c#代码): SELECT * FROM 357fa002-dc7d-4ede-935a-6a0c80cf9239 c 我明白了: Syntax error, invalid numeric value to

  • c# – 在DocumentDB中插入json文档2019-05-16 22:55:21

    在DocumentDB文档示例中,我找到了C#对象的插入. // Create the Andersen family document. Family AndersenFamily = new Family { Id = "AndersenFamily", LastName = "Andersen", Parents = new Parent[] { new Parent { FirstName = "Thom

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有