Azure MVC5 BundleTransformer Меньше нехватки памяти

Я обновляю свой веб-сайт и получаю прибыль, переписывая свой Css на Less. Веб-сайт представляет собой веб-приложение Azure с MVC 5 и BundleTransformer для Js и меньше. На локальных iis10 и iisExpress все нормально.

Но после развертывания на лазури. Я выигрываю великолепную ошибку 500 с помощью:

Exception: BundleTransformer.Core.Translators.AssetTranslationException 
    InnerException: JavaScriptEngineSwitcher.Core.JsRuntimeException: Out of memory 
    ---> MsieJavaScriptEngine.JsRuntimeException: Out of memory bei MsieJavaScriptEngine.ActiveScript.ActiveScriptJsEngineBase.InvokeScript(Action action) bei 
    JavaScriptEngineSwitcher.Msie.MsieJsEngine.InnerExecute(String code) 
    --- Ende der internen Ausnahmestapelüberwachung 
    --- bei JavaScriptEngineSwitcher.Msie.MsieJsEngine.InnerExecute(String code) 
    bei BundleTransformer.Less.Compilers.LessCompiler.Initialize() 
    bei BundleTransformer.Less.Compilers.LessCompiler.Compile(String content, String path, DependencyCollection dependencies, CompilationOptions options) 
    bei BundleTransformer.Less.Translators.LessTranslator.InnerTranslate(IAsset asset, LessCompiler lessCompiler, Boolean enableNativeMinification) 
    Message: During translation of LESS-code, readed from the file '/Content/less/light.less', to CSS-code error has occurred. 
    See more details: Out of memory StackTrace: bei BundleTransformer.Less.Translators.LessTranslator.InnerTranslate(IAsset asset, LessCompiler lessCompiler, Boolean enableNativeMinification) 
    bei BundleTransformer.Less.Translators.LessTranslator.Translate(IList`1 assets) bei BundleTransformer.Core.Transformers.TransformerBase.Translate(IList`1 assets, Boolean isDebugMode) 
    bei BundleTransformer.Core.Transformers.TransformerBase.Transform(IList`1 assets, BundleContext bundleContext, BundleResponse bundleResponse, VirtualPathProvider virtualPathProvider, Boolean isDebugMode) 
    bei BundleTransformer.Core.Transformers.TransformerBase.Process(BundleContext bundleContext, BundleResponse bundleResponse, Boolean isDebugMode) 
    bei System.Web.Optimization.Bundle.ApplyTransforms(BundleContext context, String bundleContent, IEnumerable`1 bundleFiles) 
    bei System.Web.Optimization.Bundle.GetBundleResponse(BundleContext context) 
    bei System.Web.Optimization.BundleResolver.GetBundleContents(String virtualPath) 
    bei System.Web.Optimization.AssetManager.EliminateDuplicatesAndResolveUrls(IEnumerable`1 refs) 
    bei System.Web.Optimization.AssetManager.DeterminePathsToRender(IEnumerable`1 assets)
    bei System.Web.Optimization.AssetManager.RenderExplicit(String tagFormat, String[] paths) 
    bei ASP._Page_Views_Shared__Layout_cshtml.Execute() in d:\home\site\wwwroot\Views\Shared\_Layout.cshtml:Zeile 42. 
    bei System.Web.WebPages.WebPageBase.ExecutePageHierarchy() bei System.Web.Mvc.WebViewPage.ExecutePageHierarchy() 
    bei System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage) 
    bei System.Web.WebPages.WebPageBase.RenderSurrounding(String partialViewName, Action`1 body) bei System.Web.WebPages.WebPageBase.PopContext() 
    bei System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context) 
    bei System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) 
    bei System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) 
    bei System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) 
    bei System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) 
    bei System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) 
    bei System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass21.<BeginInvokeAction>b__1e(IAsyncResult asyncResult)
    bei System.Web.Mvc.Controller.<BeginExecuteCore>b__1d(IAsyncResult asyncResult, ExecuteCoreState innerState) 
    bei System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) 
    bei System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) bei System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) 
    bei System.Web.Mvc.MvcHandler.<BeginProcessRequest>b__5(IAsyncResult asyncResult, ProcessRequestState innerState) 
    bei System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) bei System.Web.HttpApplication.CallHandlerExecutionStep.OnAsyncHandlerCompletion(IAsyncResult ar)

Единственная подсказка, которую я нашел в Интернете, это of-an-invocatio">это

Есть идеи? Спасибо.


person Cantinos    schedule 26.09.2015    source источник
comment
Разве вы не можете использовать webessentials/некоторые инструменты или задачу grunt, чтобы преобразовать свой файл less и включить только css в свой StyleBundle?   -  person christophe.chapron    schedule 26.09.2015
comment
Я бы сказал, сделайте связку перед развертыванием с помощью чего-то вроде gulp. В любом случае это vNext способ сделать это   -  person MikeSW    schedule 26.09.2015
comment
Я уже проделал трюк с webessential, но очень плохо, что он не работал правильно. :-с   -  person Cantinos    schedule 27.09.2015


Ответы (2)


Я переключил двигатель на

<jsEngine name="V8JsEngine" />

Теперь он работает на лазури :)

person Cantinos    schedule 27.09.2015

Скорее всего, на сервере установлена ​​старая версия Internet Explorer (до версии 9.0), которая не поддерживает JavaScript-движок Chakra.

person Andrey Taritsyn    schedule 09.12.2015