Try our conversational search powered by Generative AI!

2 DNS claims error occurs in CMS site in Azure

Fixed in

EPiServer.Azure 9.2.0

(Or a related package)

Created

Sep 13, 2016

Updated

Dec 05, 2016

Area

CMS Core

State

Closed, Fixed and tested


Description

Steps to reproduce

1. Create an Episerver CMS site using .NET Framework 4.6.1 or 4.6.2. Use these steps: [http://world.episerver.com/digital-experience-cloud-service/deploying/creating-a-new-cms-site-and-deploying/
]
Workaround: Upgrade NuGet package to WindowsAzure.ServiceBus 3.1.3 or later version.

2. When the site is deployed, an exception occurs:
_
Server Error in '/' Application.

Found 2 DNS claims in authorization context.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidOperationException: Found 2 DNS claims in authorization context.

Source Error:

The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:

1. Add a "Debug=true" directive at the top of the file that generated the error. Example:

<%@ Page Language="C#" Debug="true" %>

or:

2) Add the following section to the configuration file of your application:

<configuration>
<system.web>
<compilation debug="true"/>
</system.web>
</configuration>

Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.

Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.

Stack Trace:

[InvalidOperationException: Found 2 DNS claims in authorization context.]
Microsoft.ServiceBus.Common.AsyncResult.End(IAsyncResult result) +456
Microsoft.ServiceBus.Messaging.MessageReceiver.OnMessage(MessageReceivePump pump) +256
Microsoft.ServiceBus.Messaging.SubscriptionClient.OnMessage(Action`1 callback, OnMessageOptions onMessageOptions) +109
EPiServer.Azure.Events.AzureEventProvider.Initialize(String connectionString, String topicName) +418
System.Threading.Tasks.Task.Execute() +74

[AggregateException: One or more errors occurred.]
System.Threading.Tasks.Task.WaitAll(Task[] tasks, Int32 millisecondsTimeout, CancellationToken cancellationToken) +1269
EPiServer.Events.EventsInitialization.InitializeEvents(ISiteSecretManager siteSecretManager, IEventSiteRegistry eventSiteRegistry, EventProviderService eventProviderService) +294
System.Threading.Tasks.Task.Execute() +74

[AggregateException: One or more errors occurred.]
System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken) +263
EPiServer.Events.<>c_DisplayClass8_0.<Initialize>b_1(Object sender, EventArgs args) +46

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) +0
System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) +221
System.Delegate.DynamicInvokeImpl(Object[] args) +159
EPiServer.Framework.Initialization.InitializationEngine.OnInitComplete() +241
EPiServer.Framework.Initialization.InitializationEngine.ExecuteTransition(Boolean continueTransitions) +174
EPiServer.Framework.Initialization.InitializationModule.EngineExecute(HostType hostType, Action`1 engineAction) +278
EPiServer.Framework.Initialization.InitializationModule.FrameworkInitialization(HostType hostType) +190
EPiServer.Global..ctor() +84
ASP.global_asax..ctor() +9

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) +0
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) +199
System.Activator.CreateInstance(Type type, Boolean nonPublic) +100
System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes, StackCrawlMark& stackMark) +1550
System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +301
System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture) +26
System.Web.HttpRuntime.CreateNonPublicInstance(Type type, Object[] args) +80
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +333
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +360

[HttpException (0x80004005): Exception has been thrown by the target of an invocation.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +579
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +118
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +726

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.6.1055.0_