title: How to read and write from MongoDb using two different drivers (MongoDB Scala Driver and Salat)
body: <p>We want to change our MongoDB driver overtime to MongoDB Scala Driver, but we using Salat and it reads and writes sealed classes and ADTs using &quot;_typeHint&quot; to the DB. The MongoDB Scala Driver reads and writes sealed classes and ADTs using &quot;_t&quot;, What we want is a way to read and write &quot;_typeHint&quot; using MongoDB Scala Driver? We know we need a custom codec, but not sure how to implement it.</p>
  <p>We want the ability to support both drivers until we remove Salat.</p>
  <p>Thanks.</p>