Skip to content

Multiple MongoTemplate support

Kais OMRI edited this page Apr 25, 2021 · 1 revision

Starting from RelMongo 3.4.X, the possibility to target a specific MongoTemplate has been added, you have to simply specify the targeted instance in the mongoTemplateRef attribute of the @EnableRelMongo annotation, see code below

  @EnableRelMongo(mongoTemplateRef = "myMongoTemplate")
  public class AppConfig