You need to be checking, when the EssentialAction runs, that the *Thread's context ClassLoader* is equal to some expected value.