+1-888-365-2779
Try Now
More in this section

Forums / Deployment / Deploying Sitefinity as precompiled site with aspnet_compiler and aspnet_merge

Deploying Sitefinity as precompiled site with aspnet_compiler and aspnet_merge

2 posts, 1 answered
  1. Ian
    Ian avatar
    75 posts
    Registered:
    25 Oct 2010
    28 Jan 2011
    Link to this post
    Hello
    I'm trying to deploy sitefinity as a precompiled web app via aspnet_compiler.exe and aspnet_merge.exe, but i'm getting an error to do with the presence of the PrecompiledApp.config file in the output directory. When the PrecompiledApp.config file is present, i get either one of the two errors below. Without the precompiledapp.config file, the web site runs normally.

    As the PrecompiledApp.config is required by ASP.Net, what could be wrong to cause this problem?

    IIS has been set up according to the Installation guide:
    the application is in a .Net 4.0 only AppPool;
    site is configured to run ASP.Net 4.0;
    the ISAPI mappings have been set up as per the installation guide and are not checking for existence of the files;
    and all permissions are set correctly.

    Moving the PrecompiledApp.config out of the root and restarting IIS allows the site to run.


    Timestamp: 28/01/2011 12:45:00
        Message: The file '/SFRes/Telerik.Sitefinity.Resources.SitefinityDefault.aspx' does not exist.

       at System.Web.UI.Util.CheckVirtualFileExists(VirtualPath virtualPath)
       at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound)
       at System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp)
       at Telerik.Sitefinity.Web.RouteHandlerBase.CreateHandler(RequestContext requestContext, ITemplate pageTemplate)
       at Telerik.Sitefinity.Web.RouteHandlerBase.GetHttpHandler(RequestContext requestContext)
       at System.Web.Routing.UrlRoutingModule.PostResolveRequestCache(HttpContextBase context)
       at System.Web.Routing.UrlRoutingModule.OnApplicationPostResolveRequestCache(Object sender, EventArgs e)
       at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)


    Timestamp: 28/01/2011 12:49:40
        Message: Directory 'C:\Inetpub\sitefinity\SFRes' does not exist. Failed to start monitoring file changes.

       at System.Web.FileChangesMonitor.FindDirectoryMonitor(String dir, Boolean addIfNotFound, Boolean throwOnError)
       at System.Web.FileChangesMonitor.StartMonitoringPath(String alias, FileChangeEventHandler callback, FileAttributesData& fad)
       at System.Web.Caching.CacheDependency.Init(Boolean isPublic, String[] filenamesArg, String[] cachekeysArg, CacheDependency dependency, DateTime utcStart)
       at System.Web.Hosting.MapPathBasedVirtualPathProvider.GetCacheDependency(String virtualPath, IEnumerable virtualPathDependencies, DateTime utcStart)
       at System.Web.Hosting.VirtualPathProvider.GetCacheDependency(VirtualPath virtualPath, IEnumerable virtualPathDependencies, DateTime utcStart)
       at System.Web.Compilation.MemoryBuildResultCache.CacheBuildResult(String cacheKey, BuildResult result, Int64 hashCode, DateTime utcStart)
       at System.Web.Compilation.BuildManager.GetBuildResultFromCacheInternal(String cacheKey, Boolean keyFromVPP, VirtualPath virtualPath, Int64 hashCode, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVPathBuildResultFromCacheInternal(VirtualPath virtualPath, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
       at System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound)
       at System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp)
       at Telerik.Sitefinity.Web.RouteHandlerBase.CreateHandler(RequestContext requestContext, ITemplate pageTemplate)
       at Telerik.Sitefinity.Web.RouteHandlerBase.GetHttpHandler(RequestContext requestContext)
       at System.Web.Routing.UrlRoutingModule.PostResolveRequestCache(HttpContextBase context)
       at System.Web.Routing.UrlRoutingModule.OnApplicationPostResolveRequestCache(Object sender, EventArgs e)
       at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

    Thanks

    Ryan
  2. Nikolay Datchev
    Nikolay Datchev avatar
    87 posts
    Registered:
    01 Nov 2016
    01 Feb 2011
    Link to this post
    Hi Ryan,

    I am afraid in our case it is necessary to remove the PrecompiledApp.config, e.g. the site should run in updatable mode. This file generally says to asp.net that there is no need to compile aspx pages on the first request, since they are already precompiled. The problem is that some of our aspx and  ascx files cannot be precompiled since they are distributed as embedded resources inside the binaries(not as external files) and are provided through a Virtual Path Provider in a faked(non-present on the disk) virtual sub directory. So the only way to compile them is on the first request and this gets messed with PrecompiledApp.config.

    Regards,
    Nikolay Datchev
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
    Answered
2 posts, 1 answered