Closed rcrichton closed 9 years ago
Hi Ryan,
Sorry for the late reply. I do think that new concepts will be added whenever a CDA contains a new concept and autocreate concepts is set to true. Would this code also work in that situation? For example, CDA A is received with an observation whereby the import process has to create a concept and CDA B is subsequently received with the same observation type.
Hey @justin-fyfe1, so this code will still work in that case. Just the first time that concept is fetched it will take some time as it has to pull it out of the db (~300ms).
Hey @justin-fyfe1 I've changed this code some that it will rather cache conceptIds rather than the full concept objects. I think this is better so we aren't using object across threads etc. What do you think?
Hey @justin-fyfe what do you think of this simple caching to improve performance? I was able to get a 10 fold performance increase with this once the concepts are cached.
The problems are that if the concept dictionary changes then we will require a server re-start. However, I don't think that is the worst thing for an SHR.