ERROR while running bahmni-erp-connect

Can I please get help on this error?

/var/log/bahmni-erp-connect/ shows:

Caused by: org.bahmni.webclients.WebClientsException: Authentication with OpenELIS failed

I have fixed other errors connected to this (for openmrs) I have edited the user/passwords located in the following files to the superman/Admin123:

nano /opt/pacs-integration/pacs-integration/WEB-INF/classes/atomfeed.properties

chown bahmni /opt/pacs-integration/pacs-integration/WEB-INF/classes/atomfeed.properties

nano /etc/bahmni-lab/atomfeed.properties

chown bahmni /etc/bahmni-lab/atomfeed.properties

nano /opt/bahmni-lab/bahmni-lab/WEB-INF/classes/atomfeed.properties

chown bahmni /opt/bahmni-lab/bahmni-lab/WEB-INF/classes/atomfeed.properties

nano /opt/bahmni-erp-connect/bahmni-erp-connect/WEB-INF/classes/erp-atomfeed.properties

chown bahmni /opt/bahmni-lab/bahmni-lab/WEB-INF/classes/atomfeed.properties

I have checked as well the bahmni-lab / openelis atomfeed user / password and those are correct. I checked it by logging in openelis using the atomfeed credentials.

What am I missing?

Thank you for your help.

EDIT: Other details:

Bahmni Versions:

> ansible.noarch                        2.4.6.0-1.el7.ans          @bahmni
> atomfeed-console.noarch               1.1-1                      @bahmni
> bahmni-emr.noarch                     0.92-189                   @bahmni
> bahmni-erp.noarch                     0.92-149                   @bahmni
> bahmni-erp-connect.noarch             0.92-149                   @bahmni
> bahmni-implementer-interface.noarch   0.92-33                    @bahmni
> bahmni-installer.noarch               0.92-155                   @/bahmni-installer-0.92-155.noarch
> bahmni-lab.noarch                     0.92-59                    @bahmni
> bahmni-lab-connect.noarch             0.92-189                   @bahmni
> bahmni-reports.noarch                 0.92-30                    @bahmni
> bahmni-web.noarch                     0.92-189                   @bahmni

CentOS Version:

CentOS Linux release 7.9.2009 (Core)

Usually OpenELIS default creds are: admin/adminADMIN! While OpenMRS default creds are: superman/Admin123

You can refer to this docker-compose file, to get a sense of which values to put where:

See the .env file. And the docker-compose.yml.

Thanks for the reply Gurpreet.

I forgot to mention the version of Bahmni and OS.

Bahmni Versions:

> ansible.noarch                        2.4.6.0-1.el7.ans          @bahmni
> atomfeed-console.noarch               1.1-1                      @bahmni
> bahmni-emr.noarch                     0.92-189                   @bahmni
> bahmni-erp.noarch                     0.92-149                   @bahmni
> bahmni-erp-connect.noarch             0.92-149                   @bahmni
> bahmni-implementer-interface.noarch   0.92-33                    @bahmni
> bahmni-installer.noarch               0.92-155                   @/bahmni-installer-0.92-155.noarch
> bahmni-lab.noarch                     0.92-59                    @bahmni
> bahmni-lab-connect.noarch             0.92-189                   @bahmni
> bahmni-reports.noarch                 0.92-30                    @bahmni
> bahmni-web.noarch                     0.92-189                   @bahmni

CentOS Version:

CentOS Linux release 7.9.2009 (Core)

My issue is with the bahmni-erp-connect or bahmni-connect and I think it has to do with the this file which is located at /opt/bahmni-erp-connect/bahmni-erp-connect/WEB-INF/classes/erp-atomfeed.properties.

Inside the file is the below code.

openelis.user=atomfeed
openelis.password=AdminadMIN*
openelis.uri=http://${OPENELIS_HOST}:8052/openelis

Should I change the above code to the default OpenElis admin credentials?

admin/adminADMIN!

UPDATE:

I changed the OpenElis credentials at erp-atomfeed.properties to admin/AdminadMIN*

But, I am still getting the error in the log file. It’s weird because I was able to fix the error for OpenMRS by doing the change in the erp-atomfeed.properties file.

@johnnelito Actually OpenELIS credentials for atomfeed sync to happen is atomfeed/AdminadMIN*. Can you once validate if you can login to OpenELIS with the above mentioned credentials ?

Yes, I can login with atomfeed/AdminadMIN* on OpenElis website. The reason I changed it to admin/adminADMIN! was because of the error in the log file. However, that did not fix it.

Ohh seems weird. Can you please post the contents of your erp-atomfeed.properties file ?

Sure thanks @mohant for checking.

cat /opt/bahmni-erp-connect/bahmni-erp-connect/WEB-INF/classes/erp-atomfeed.properties:

#jdbc Settings
jdbc.driverClassName=org.postgresql.Driver
jdbc.username=postgres
jdbc.password=postgres
jdbc.url=jdbc:postgresql://localhost/odoo
update.atomfeed.marker=false

atomdb.show_sql=false
atomdb.format_sql=false
atomdb.default_schema=public

atomdb.c3p0.max_size=15
atomdb.c3p0.min_size=1
atomdb.c3p0.timeout=120000
atomdb.c3p0.max_statements=20
atomdb.c3p0.idle_test_period=300
atomdb.c3p0.acquire_increment=3

feed.id.prefix=ff554579-a19f-4bf9-b245-440814b513d9
feed.title=Events
feed.generator.title=Openerp
feed.author=openerp

customer.feed.generator.uri=http://localhost:8050/openmrs/ws/atomfeed/patient/recent
saleorder.feed.generator.uri=http://localhost:8050/openmrs/ws/atomfeed/encounter/recent
drug.feed.generator.uri=http://localhost:8050/openmrs/ws/atomfeed/drug/recent
lab.feed.generator.uri=http://localhost:8050/openmrs/ws/atomfeed/lab/recent
openmrs.auth.uri=http://localhost:8050/openmrs/ws/rest/v1/session
referencedata.feed.generator.uri=http://localhost:8050/reference-data/ws/feed/recent
referencedata.endpoint=http://localhost:8050/reference-data

openelis.user=atomfeed
openelis.password=AdminadMIN*
openelis.uri=http://localhost:8052/openelis
openelis.saleorder.feed.generator.uri=http://localhost:8052/openelis/ws/feed/patient/recent

chunking.strategy=number

openerp.port=8069
openerp.host=localhost
openerp.database=odoo
openerp.user=admin
openerp.password=admin
openerp.connectionTimeoutInMilliseconds=5000
openerp.replyTimeoutInMilliseconds=20000
openerp.maxFailedEvents=1000


openmrs.user=superman
openmrs.password=Admin123

scheduler.initial.delay=60000

@johnnelito Thanks for sharing. Let me investigate and get back to you if I could find something.

2 Likes

Probably a bug. @mohant is investigating this: ERROR while running bahmni-erp-connect

Thanks, @gsluthra. I’d like to add that the data in the database is the included demo. I read somewhere it might cause issues.

@johnnelito The issue is with the URI in erp-atomfeed.properties file. You need to update the openlis.uri value with the below URI. http://localhost:8052/openelis/ws/feed/patient/recent. Then restart bahmni-erp-connect service. Now the service should start without any error.

2 Likes

Thanks @mohant and @gsluthra. This fixed it.

1 Like