Saturday, September 14, 2013

Completing GSoC project tasks : GSoC Week 13

This week I completed the final task for GSoC 2013 which is providing a way to fix validation errors in Conecepts.

Before start work on that i changed the UI view of the validation error table, as instructed by my mentor and  now the error table displays the following information.


The when fixing validation errors in Concepts, for this i have used the Concept Id and once the user need to fix the error it will redirect user to 'Edit Concept' page like shown in the image below.


With this i have successfully finished the work schedules for the GSoC 2013 project this summer under 'Validation Module Enhancements' project.  My mentor has review the final task and provided some feedback, which needs to be modified. Therefore i will be working on that as well as work on documenting during the last  week of the project before 'Hard Pencil Down Date'.


Friday, September 6, 2013

Starting 'Fix Validation Errors in Concept' : GSoC Week 12

This week i first started on trying to implement 'fixing validation errors in concepts' task. However as this is the final task for my GSoC project this time, i then decided it would be better to discuss the next steps with my mentor before we proceed. Therefore both of us had a detailed discussion on the next steps of the project.

The following are the things we agreed on finishing in the remain time.

1. In validation error table it currently displays a string of error key. We are going to change this as getting an OpenMRS Object as key and display the Object id: UUID as the first column information.

2. The fixing concepts errors option would be implemented as, when the user clicks Fix link, a new window would pop up which has the concept edit page for the given concept id. We are going to edit the Concept here, and save it back to the database.

Therefore i have started with these two points in this week and will be finishing them in coming two weeks.

Friday, August 30, 2013

Finalizing Validation Report Display : GSoC Week 11

This week i have completed VM-4 , Displaying Validation Error Report, with finishing both error views: Class and Error views.

In class view the validation errors are sorted under the class name as shown in the image below.



In error view validation errors are sorted under the error name as shown in the image.



After getting feedback from my mentor on this ticket, i will be starting my final feature of GSoC 2013, which is Fixing Validation Errors in Concepts, hopefully from next week.

Saturday, August 24, 2013

Completing the display errors based on Class type: GSoC Week 10

This week i first completed the code which displays the validation errors based on Class name. I have been able to display the Class errors in a table where the errors are displayed under each class as Error id and the Error description as follows.




After that  i worked on correcting the code written for this feature, after getting the code reviewed from my mentor Wyclif. There were also some feedback for Stop Validation feature and therefore i had to correct them all in this week too.

Friday, August 16, 2013

Categorizing the validation errors based on class : GSoC Week 9

As i had created the layout of the Report page which will be used to display the generated validation report last week, this week i coded to get a combined Map of validation errors along with  having Object type's Class name as they key of the Map.

So i have implemented for iterating via all the detected validation errors and comparing the Class name the similar set of errors are pu into a single collection and final validation error Map is generated.

Then after using that Map, the errors are displayed in the 'Class View' tab of the report page as a table as sketched in follows.

Class Type Error Name Description
Concept Duplicate Name Exception A is duplicated in Concept "B"
Duplicate Name Exception C is duplicated in Concept "B"

Currently i am having some issues in displaying this in the page, and that is why there is no screenshot of the yet. I will be publishing the screenshot in my next week blog once i fix all the bugs regarding the task.

Saturday, August 10, 2013

Group and Display Validation Errors : GSoC Week 8

After passing the mid evaluation, this week i started working with ticket VM-4 which is display the error report produced in validation.

To view the validation report, you have to click the 'Show Report'. Then you are redirected to Report page where the validation errors are displayed in a tabbed pane whch has two tabs.

1. Class View tab : This displays the error list based on the Error class
2. Error View tab :  This displays the error list based on the Name of the error.

As the initial work i created the tabbed pane and got the errors  list into it as displayed in the snapshot.


Friday, August 2, 2013

Here Comes the Mid Term : GSOC Week 7

This week is the mid evaluations week in GSOC 2013 and today is the last date for mid evaluation submission. (Feeling excited :D)

This week what i basically did was making sure that all my previous codes work and all the documenting is made. Then there was the mid term presentation at the weekly developer forum for my project and i presented the tasks i have done so far.

You can find the PDF of the presentation in here.

In the last days of the week, i discussed the next task of the project with my mentor Wyclif. The next task is 'Grouping validation errors based on class type or error type'. I am going to start it coding today and progress will be updated next week :)

Friday, July 26, 2013

Documenting, Test Cases and Getting ready for Mid: GSOC Week 6

As this is the final week before the mid evaluation, i finished the test cases for stop validation module.

Then i wrote the documentation for the two newly added features, and added them into the validation module documentation which can be found here. However as the changes are still not available in the publicly visible module, i also added a comment there saying that, the changes will be included once the GSoC project is over.

Validation Module New Documentation

There after i have been working this week on polishing my existing code, covering test cases and documenting them. Hopefully i can complete the mid evaluation tasks well in this week.

Saturday, July 20, 2013

Completing 'Stop validation' : GSoC Week 5

In this week i finished 'Stop Validation' task. The earlier method of stopping the validation with using a button didn't work as expected so i rewrote the UI code to display a progress message once the validation starts. This has a link named 'Stop' which user can click to stop the currently running validation.

When user click 'Stop' link validation will be stopped and all the validation threads are interrupted. After successfully stopping the process, it will display a 'validation stopped' message in screen. If the validation is not stopped and finished as normal, the progress message will dissapear when the validation completed successfully. In this the the usual 'validation success' message will come out.

1. Validation Progress bar with 'Stop' option.



2. Validation stopped message

Friday, July 12, 2013

Adding test cases for task VM-2 : GSoC week 4

This week i spent on writing test cases for the first feature i have implemented which is VM-2, Make it possible to select the type of metadata or data to validate instead of typing a fully qualified class name. I first added the OpenMRS GenerateTestCases plugin for IntelliJ Idea and generated the skeletons of the test methods.

The follwing is the list of test cases i have written for this week.


  • @should verify all validation threads have started
  • @should verify validation is completed
  • @should verify thread count is correct
However i came through an issue while trying on running the test cases as the IDE threw a lot of ClassNotFoundExceptions. It seems that this is due to classpath settings issues in my project, so i am going to work with my mentor on resolving these today and will properly test the written test classes.

Friday, July 5, 2013

Adding 'All Data' selection option to validation UI : GSoC week 3

In this week i was able to complete the following tasks.

1. Modified the code in a way to display the simple object type names in a three column view.



2. Added an option to select 'All Data' to validate at once. [VM-1]
    Once the user checks the 'All Data' checkbox in the selection window, the whole list of available validators will be displayed in the UI and user can validate the whole data with a single click.


Therefore i am expecting to finish this feature within next week with completing unit tests and the documentation.

After that i will be working on VM-3, which is adding a way to stop validation. I already got a start to that this week, however hope to continue it after the VM-2, the current task is completed. Also i need to discuss the approach for VM-3 with my mentor too.

Thursday, June 27, 2013

Improving the object selection code: GSoC week 2

As my mentor Wyclif had reviewed the first week code changes for the 'select object types to validation' feature and have added his comments on the code I spent this week to modify the code according to the feedback and improving it.

The main three points to do improvement were,

1. In the object types selection dialog window, show the Simple Object type name instead of showing the full class name as org.openmrs.Concept etc. So with the new changes these types are changes to;

org.openmrs.Concept  --> Concept
org.openmrs.Provider --> Provider etc.

2. Instead of string processing to get the selected types to be posted once the list is submitted, use Spring and send a List of types.
After i set the name of the checkboxes to be the same i.e type, then the browser always sends all checked ones to the server and spring automatically convert them into a list or array. Therefore i changed the previous way of reading the types and append them into a single send before it is posted and used this method.

3. Reviewed on the logic which makes validation threads and tested whether it works fine.

Saturday, June 22, 2013

Beginning the coding phase - Week 1

This monday began the GSoC 2013 coding period. As discussed with my mentor I have started coding with VM-2 where i am going to work on 'Make it possible to select the type of metadata or data to validate instead of typing a fully qualified class name'.

At the end of week i have finished the following tasks in the ticket.

1. The new validator UI contains 4 buttons as 'Select Types', 'Show Report', 'Stop Validation' and 'Validate Types'.


2. Once the user click 'Select Types' a new dialog window will be open where the user can select all the object types that needs to be validated.


3. When the required types are selected and click 'Done', the selected types will be displayed in the UI. If user wants to remove or add more types, he can again use 'Select Types' window. The previous options will be stored in the dialog window, hence user can remove/add more option in there and click 'Done' back. The types list will be updated accordingly.




After selecting the types, click 'Validate Types' button. The object types will e validated and user will be redirected back to front UI, in image 1.


Tuesday, May 28, 2013

Beginning another summer with OpenMRS :)

Google Summer of Code 2013 results just arrived with a good news for my one month long waiting. I am a GSoCer again with OpenMRS, Yeppi!



I was also a participant in GSoC 2012 with OpenMRS last year. Hence i was very eager on trying in this summer too due to my interest in working full time with an OpenMRS project back because, the support  i got from the community during the last time of GSoC was awesome.

I am going to work in the "Validation Module Enhancements" project for GSoC 2013 which is about improving and adding some very useful features into the OpenMRS Validation Module. As i was discussing the project with Rafal from OpenMRS, throughout the student application period it feels that i am lot aware of the requirements now and looking forward to begin the project soon. Excited :)

My mentor for this summer would be Wyclif Luyima. We hope to discuss the final project plan soon in the community bonding period.

The excitement is now to begin with the summer!