Java error in DBRef of mongo Driver

Getting error on MongoDB : Can’t find a codec for class com.mongodb.DBRef.
I’m getting below error while execution of mule flow. Let me know if anyone know about this.

I couldn’t find suitable answer.

org.bson.codecs.configuration.CodecConfigurationException: Can't find a codec for class com.mongodb.DBRef.

at org.bson.internal.CodecCache.getOrThrow(

at org.bson.internal.ProvidersCodecRegistry.get(

at org.bson.internal.ProvidersCodecRegistry.get(

at org.bson.codecs.DocumentCodec.writeValue(

at org.bson.codecs.DocumentCodec.writeMap(

at org.bson.codecs.DocumentCodec.encode(

Did you check some popular answers for this error? e.g. this. java - Resolve DBRef into Json - Stack Overflow