<h2>Pattern based discovery fails with the error - Service horizontal discovery failed due to categorized exception. Failed to initialize the pattern library. </h2><br/><div style="overflow-x:auto"><article><div ><h3 >Issue </h3><section><ul><li> Discover a Network Switch/Server using the patterns, the device classification probe is successful without any errors, reviewing the pattern logs you find the below error.</li><li> <pre>Service horizontal discovery failed due to a categorized exception. Failed to initialize the pattern library.</pre> </li></ul></section></div><div ><h3 >Release</h3><section><ul><li>Instance enabled with Discovery plugin.</li><li>Discovery is performed using patterns</li></ul></section></div><div ><h3 >Cause</h3><section><ul><li>The mid server does not load the patterns, this could occur post making changes to the mid server configurations like adding mid server certificates.</li><li>Modifications to the existing OOB patterns and publishing them.</li><li>After publishing a custom pattern.</li></ul></section></div><div ><h3 >Resolution</h3><section><ul><li>Navigate to the Mid servers list. <br /></li><li>Click on the UI Action - "Pattern Sync to Mid" to synchronize the patterns with the mid servers.</li><li>Re-discover the devices, the patterns would be loaded during the discovery and the device would be successfully discovered.</li></ul></section></div></article></div>