Question

I am getting the following error in Quartz.net

The assembly with display name 'Quartz.XmlSerializers' failed to load in the 'LoadFrom' binding context of the AppDomain with ID 1. The cause of the failure was: System.IO.FileNotFoundException: Could not load file or assembly 'Quartz.XmlSerializers, Version=2.0.1.100, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.

It's very odd since Quartz.XmlSerializers does not exist anywhere in any code I'm using. It's not in the Quartz source code, my code, and none of my dependencies best I can tell. It only occurs when I debug my project, but not when I download the Quartz 2.0.1 source code and run the server from there.

I am using topshelf as the service install library.

It occurs during deserialization on line 226 of XMLSchedulingDataProcessor.cs of the Quartz source.

// deserialize as object model
System.Xml.Serialization.XmlSerializer xs = new System.Xml.Serialization.XmlSerializer(typeof(QuartzXmlConfiguration20));

Any clue to solving this would be helpful as I'm stumped by this error.

Was it helpful?

Solution

In applications that use XmlSerialization, you can get a first-chance exception in outside code when the application looks for a cached serialization assembly. You can find more information in this question.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top