简体   繁体   English

从2011年到2016年升级Dynamics CRM

[英]Upgrading Dynamics CRM from 2011 to 2016

With little knowledge of CRM, we were tasked with exposing data and other functionality from CRM 2011. We developed a RESTful wrapper that allows other developers to leverage it in their apps. 由于对CRM知之甚少,我们的任务是从CRM 2011中公开数据和其他功能。我们开发了一个RESTful包装器,允许其他开发人员在他们的应用程序中利用它。 Some example endpoints might have been: 一些示例端点可能是:

API/v2/Accounts(someguid)
API/v2/Lead/Create {json object}
etc

This application needs to be upgraded to support dynamics 2016. We fired up our 2011 app, and simply changed a config variable to point to a 2016 instance. 此应用程序需要升级以支持动态2016.我们启动了2011应用程序,并简单地将配置变量更改为指向2016实例。 So far we haven't been able to do anything because right after the second line below: 到目前为止,我们无法做任何事情,因为在第二行之后:

        var context = new XrmServiceContext(_organizationService);

        var crmUser = (from systemUser in context.SystemUserSet
                       where systemUser.DomainName == user.DomainUserName
                       select systemUser).FirstOrDefault();

I get authentication failed exceptions: 我得到认证失败的例外:

在此输入图像描述

Is this indeed a known authentication issue when upgrading from 11 to 16, or am I missing something? 当从11升级到16时,这确实是一个已知的身份验证问题,还是我错过了什么?

There have been countless Authenticate Changes between CRM 2011 and 2016. The SDK should handle all of these issues for you, fairly seamlessly. 在CRM 2011和2016之间进行了无数的身份验证更改.SDK应该可以无缝地为您处理所有这些问题。

Download the latest version from https://www.microsoft.com/en-us/download/details.aspx?id=50032 , and update any of Microsoft.Xrm.* dlls that you are referencing in your project. https://www.microsoft.com/en-us/download/details.aspx?id=50032下载最新版本,并更新您在项目中引用的任何Microsoft.Xrm。* dll。

If you're using Nuget, you could add these instead: 如果您正在使用Nuget,则可以添加以下内容:

  • Microsoft.CrmSdk.Extensions (7.1.0.1 - this contains the older connection method to CRM. It will be going away, but for now, is still compatible) Microsoft.CrmSdk.Extensions(7.1.0.1 - 这包含旧的CRM连接方法。它将会消失,但目前仍然兼容)
  • Microsoft.CrmSdk.Deployment (8.2.0.2) Microsoft.CrmSdk.Deployment(8.2.0.2)
  • Microsoft.CrmSdk.Workflow (8.2.0.0) --> This one should actually be optional. Microsoft.CrmSdk.Workflow(8.2.0.0) - >这个实际上应该是可选的。

Once you've updated your references, rebuild, and retry. 一旦更新了引用,重建并重试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM