Can't get a registeredcomponent for synced visit


during development work on synchronizing Visits I encountered a problem in org.openmrs.api.context.Context class in getRegisteredComponent method

I’m running getRegisteredComponent method with arguments: beanName=sync2.api.filter.pull.visit and clazz=interface org.openmrs.modules.sync2.api.filter.objectFilter and I get an APIException: “service.error.during.getting.component”

does anyone know how this method works and what arguments it expects? @dkayiwa, @dserkowski, anyone ?

Regards, Tomasz

The first argument is the spring bean name and the second is the java class

Does the bean need to be registered somewhere to have the registeredComponent retrieved by this method?

All that matters is it being a spring bean

@tmueller, are you still stuck on this?

Maybe you can you point to the code where you’re trying to do this?

(As Wyclif says, that method is basically just our custom OpenMRS approach for getting a Spring bean at runtime.)

No, this problem is already solved thanks to @dserkowski