Friday, August 30, 2013

PDI story Contd...

This week i tried to build, deploy and run the PDI plugin of OpenMRS. It seems it has bit old file structure. As I saw no one has touched that after February of 2012.

Still I unable to build it properly because its  tests fail. It gives a
" JsonMappingException: Can not deserialize instance of java.util.ArrayList out of START_OBJECT token " exception. http://pastebin.com/HgDZbrr9 . As I understood, it throws the error because of the structure of our JSON output we producing. I have to find a way to build it properly.

The existing plugin only accept a DataSet Definition and a CohortDefinition. I hope we can extend this to accept a ReportDefinition and parameters.

And I don't think we can happy about the way of  testings on the PDI module. it directly access the OpenMRS server data for testing purposes. I think it is better to use a xml test data file instead of the OpenMRS server data.

 After discussing with Darius I hope to start the implementation in the upcoming week.


Sunday, August 25, 2013

Migrating to Pentaho

After working several weeks with RESTful web services, I started to work on my second phase of my project. Writing a plugin for Kettle.

First I got some undestand on Pentaho Data Integration(Kettle project).
I downloaded the Pentaho Data Integration and did some transformations with spoon.

I read the pdi_embed_extend_guide.pdf. It gives a good idea to how to start to write a plugin.
I deploy and run the example plugin.

Then I moved on to our existing OpenMRS plugin. I compared it with the given pentaho example plugin.
It has thoroughly followed the Pentaho conventions. It uses a RestClient to pull data from the REST API of OpenMRS. It is a Input step.

So my next target will be identify the improvidence which need in this release.
Hope to speedup my coding in next few days.