Parsing error on XML email listener in Production

Version 1

    Details

    Parsing error on XML email listener in Production:  System.Exception: Error in loading Hierarchical Object XSLT file(s) ---> System.Xml.Xsl.XslLoadException: XSLT compile error. ---> System.IO.FileNotFoundException: Could not find file 'C:\temp\Frs_Integration\Input\Email\3a41449c544a4767878c3cccb9c16cf0\NSR_Consultant_Onboard.xsl'.    at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)    at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)    at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)    at System.Xml.XmlDownloadManager.GetStream(Uri uri, ICredentials credentials, IWebProxy proxy, RequestCachePolicy cachePolicy)    at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)    at System.Xml.Xsl.Xslt.XsltLoader.CreateReader(Uri uri, XmlResolver xmlResolver)    at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(Uri uri, Boolean include)    at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(XmlReader reader, Boolean include)    --- End of inner exception stack trace ---    at System.Xml.Xsl.Xslt.XsltLoader.LoadStylesheet(XmlReader reader, Boolean include)    at System.Xml.Xsl.Xslt.XsltLoader.Load(Compiler compiler, Object stylesheet, XmlResolver xmlResolver)    at System.Xml.Xsl.Xslt.Compiler.Compile(Object stylesheet, XmlResolver xmlResolver, QilExpression& qil)    at System.Xml.Xsl.XslCompiledTransform.LoadInternal(Object stylesheet, XsltSettings settings, XmlResolver stylesheetResolver)    at FrontRange.Integration.Adapter.Container.XmlContainerBase.GetMetadataDefByTable(String fullFileName)    --- End of inner exception stack trace ---    at FrontRange.Integration.Adapter.Container.XmlContainerBase.GetMetadataDefByTable(String fullFileName)    at FrontRange.Integration.Adapter.Synchronization.Synchronizer.Sync(Object arg)  Exact setup appears to work fine in Staging.


    Resolution

    The system copies all XSLT/XSL files into the processing folder upon receiving the email through the XSLT listener.  If an XSL file is referenced in the XSLT (even if it is not needed for this particular email to process) it will create this error and the Email processing will not continue.

    Adding all the XSL files to the AdminUI refereed to in the main XSLT resolved this error.