One of the first projects that I’ve been working on this semester is the OpenMRS Project. “OpenMRS is a collaborative open source project to develop software to support the delivery of health care in developing countries.” I found this to be an interesting project to work on since it’s an open source project with many talented developers as well as supporting a good cause. However, the setup to begin developing was definitely challenging.
Since OpenMRS is open source, all of their code is published on GitHub, so being able to jump in to developing should be easy. Wrong (for me at least). First I was introduced to a new IDE, which is no big deal, that’s easy enough. The IDE I was starting to learn was called IntelliJ IDEA, or as I like to call it, IntelliJelli. What’s nice about IntelliJelli is that you can directly import a project from GitHub. However, I did not do this at first. I thought it would be easier to pull the code from GitHub and just import it myself. Upon doing this, as planned it imported all the code, but it was missing everything; and what I mean by everything is that it wasn’t created as a maven project, it was missing some maven imports, it even had errors that I don’t know how to explain. After being very confused and disgruntled with all the unknown errors I had, I decided I would try importing directly from GitHub. Why I didn’t think of that in the first place is beyond me. It worked flawlessly. It created it as a maven project by default, it had all the imports it needed, everything was perfect except for a couple of lines that had a few errors (later I would find out that these errors are not important).
In order to finish getting a working build of this code, I had to open the console and use a few commands to get things working. First I needed to work my way towards the OpenMRS directory and do a clean maven install. This built the project as a maven project (again I believe? If not officially for the first time so it’s recognized). Once the maven clean install and updates were finished, I was ready to start the server that’s contained within.
OpenMRS works within a browser so I had to work my way to the webapp folder and start the jetti program. Now starting the jetti server worked, however I had nothing to actually work with, I needed some form of UI and database to work with while developing. Thankfully, OpenMRS supplies an option upon the initial setup to create a fake database of people with certain information and characteristics. To store this database, I also needed MySQL.
So the first step to this was downloading and installing MySQL, which also needed Python, visual basics, SQL connector, etc. So before I could even get the database setup, I needed other programs and languages as well. After installing those and finishing the installation of MySQL, I was ready to begin the installation of the Legacy UI supported by OpenMRS. Thankfully there was a very helpful tutorial provided by OpenMRS on their wiki page, so I followed those instructions and placed the generated UI file into my appdata folder. With this I was finally ready to begin the initial setup of OpenMRS in my browser.
Upon starting MySQL and the OpenMRS jetti server, I opened up my browser and went to localhost port number 8080. I went through the custom / advanced setup so that I could select creating a database of fake people to use and to communicate with MySQL. It took awhile for it to create the data, but it finally worked and redirected me to the log in page. Success. I logged in and went straight to the database to see what I could find for data. I found 2 people. I can tell that the identification numbers for the people are not in chronological order, but I feel like I should have more than 2 people in my database. I’m hoping to resolve this issue soon.
In the coming days / weeks I’ll be working on a new project with OpenMRS that deals with radiology. The radiology team seems excited to be helping us students succeed, which is very thoughtful of them and I’m grateful for that. Working on the tickets they suggested we look into will be interesting and I’m hoping it will put my knowledge to the test.
Until next time… Nick
From the blog CS@Worcester – Nick Richard by Nick Richard and used with permission of the author. All other rights reserved by the author.