Fixed number of bugs in driver-compat

com.mongodb.CommandResult:
- nested org.mongodb.Document objects are not converted
- throw com.mongodb.MongoException.DuplicateKey if error code in [11000, 1001, 12582]

com.mongodb.WriteResult:
- getN() throws NullPointerException