We recently upgraded from OpenMRS 1.12 to OpenMRS 2.0.6.
The EncounterService.getEncountersByPatientIdentifier() is extremely slow and at times unusable in our production environment. We are attempting to search for encounters using the patient identifier. Below is an example of how we are using it:
String mrn = "exampleMRN1234";
EncounterService encounterService = Context.getEncounterService();
List encounters = encounterService.getEncountersByPatientIdentifier(mrn);
This method takes approximately 20 seconds to return a result. In our previous version of OpenMRS this method worked just fine.