Make Atomfeed as an optional dependency for bahmni appointments

Tags: #<Tag:0x00007fdde93a4908> #<Tag:0x00007fdde93a4818> #<Tag:0x00007fdde93a4750>

Hello team,

We are planning to use the bahmni appointments module as part of openmrs-ref-app. As of now, Bahmni Appointments module requires the openmrs-atomfeed module to be present. Since we won’t be using the atomfeed we are trying to avoid this extra jar.

We see Atomfeed events are getting raised behind a global-property toggle here. We can change the dependency to be an aware_of_module dependency rather than required_module dependency. In that case, this module only be required if we want to raise events for appointments created.

Let us know your thoughts.

CC: @angshuonline @mksd @binduak @snehabagri @mksrom

In case we want the events to be raised how will we do it?

In that case It will be the current workflow.

  • Install openmrs-atomfeed module
  • Install appointments module
  • Set the global_property atomfeed.publish.eventsForAppointments to true.

It would continue to work as the current behavior.

If we don’t want to raise events, then we can just:

  • Install appointments module
  • Set the global_property atomfeed.publish.eventsForAppointments to false.

This is my understanding after looking at the code and the flow.

Bumping this up,

I will go ahead and create a BAH card on product jira. I will make the changes and test above scenarios mentioned. Will raise a PR if I find them working.

Let us know your thoughts.

@angshuonline @snehabagri @binduak @swetha184

Created a card here, https://bahmni.atlassian.net/browse/AP-12.

I have added different scenarios in this. I will move the card once I start working on this.