Im having a requirement to create mongodb collections by tenant specific. Eg: I have a collection called audit_logs, but I want to create the following way
tenant : EAD collection : ead_audit_logs tenant : gtc collection : gtc_audit_logs and so on.
somebody please help me to do the configuration in micronaut.
im using micronaut-data and the configuration to be done in the pojo/entity class is not working out.
@Getter
@Setter
@MappedEntity
@Property(name = "#{@ThreadContext.get('tenant')}_audit_log")
public class AuditLog {
@Id
@GeneratedValue
private String id;
}