pom files

Hi Murod

Hope this finds you well. I remember you were busy in Delhi
rationilizing the pom files in the dhis2 project. Did you get this
finished? It would be good to be able to build/debug/profile through
a single project.

Regards
Bob

I agree, this is on my wishlist as well. Can I get that pom.xml if committing it to the trunk is an issue

···

Regards,
Saptarshi PURKAYASTHA
Director R & D, HISP India
Health Information Systems Programme

My Tech Blog: http://sunnytalkstech.blogspot.com
You Live by CHOICE, Not by CHANCE

2009/4/14 Bob Jolliffe bobjolliffe@gmail.com

Hi Murod

Hope this finds you well. I remember you were busy in Delhi

rationilizing the pom files in the dhis2 project. Did you get this

finished? It would be good to be able to build/debug/profile through

a single project.

Regards

Bob


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Hey Murod good to hear from you.

···

2009/4/14 Murodullo Latifov <murodlatifov@yahoo.com>:

Hi Bob,

Yes, there changes to be made on poms to make dhis2 as single project. Also there are special requirements/plugins to get project into eclipse. I will write on mailing list soon on how to run/debug modules with WTP (develop as you deploy, maven-eclipse-tomcat), etc., but I need to discuss this with Lars before that. What I have done is on module level, projectwise it needs more work.
Now I am working on webwork to struts2 migration as well as upgrading hibernate to latest release and use of annotations (JPA and Hibernate). These all should be discussed in mailing list before we take steps, because they are major changes and need surrow revision and testing.

So, lets start on discussing these issues on WHYs, HOWs WHOs and WHENs scopes.

These are indeed major changes - would be good to see a proposal on the list.

Cheers
Bob

Murod,

  • What do you mean by upgrading to the latest Hibernate release? We are already running the latest one in the maven repo, 3.2.6.ga.

  • What would be the reason for switching to Hibernate/JPA annotations?

  • Why are you working with struts2 migration? Have we decided to switch? Is this something we should prioritize right now as there are lots of pressing requirements, like the list we put down a few weeks ago?

Lars

···

On Tue, Apr 14, 2009 at 3:41 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hey Murod good to hear from you.

2009/4/14 Murodullo Latifov murodlatifov@yahoo.com:

Hi Bob,

Yes, there changes to be made on poms to make dhis2 as single project. Also there are special requirements/plugins to get project into eclipse. I will write on mailing list soon on how to run/debug modules with WTP (develop as you deploy, maven-eclipse-tomcat), etc., but I need to discuss this with Lars before that. What I have done is on module level, projectwise it needs more work.

Now I am working on webwork to struts2 migration as well as upgrading hibernate to latest release and use of annotations (JPA and Hibernate). These all should be discussed in mailing list before we take steps, because they are major changes and need surrow revision and testing.

So, lets start on discussing these issues on WHYs, HOWs WHOs and WHENs scopes.

Hi Lars,

···

From: Lars Helge Øverland larshelge@gmail.com
To: Bob Jolliffe bobjolliffe@gmail.com
Cc: Murodullo Latifov murodlatifov@yahoo.com; dhis2-devs dhis2-devs@lists.launchpad.net
Sent: Tuesday, April 14, 2009 4:04:32 PM
Subject: Re: [Dhis2-devs] pom files

On Tue, Apr 14, 2009 at 3:41 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hey Murod good to hear from you.

2009/4/14 Murodullo Latifov murodlatifov@yahoo.com:

Hi Bob,

Yes, there changes to be made on poms to make dhis2 as single project. Also there are special requirements/plugins to get project into eclipse. I will write on mailing list soon on how to run/debug modules with WTP (develop as you deploy, maven-eclipse-tomcat), etc., but I need to discuss this with Lars before that. What I have done is on module level, projectwise it needs more work.

Now I am working on webwork to struts2 migration as well as upgrading hibernate to latest release and use of annotations (JPA and Hibernate). These all should be discussed in mailing list before we take steps, because they are major changes and need surrow revision and testing.

So, lets start on discussing these issues on WHYs, HOWs WHOs and WHENs scopes.

Murod,

  • What do you mean by upgrading to the latest Hibernate release? We are already running the latest one in the maven repo, 3.2.6.ga.

  • What would be the reason for switching to Hibernate/JPA annotations?

  • Why are you working with struts2 migration? Have we decided to switch? Is this something we should prioritize right now as there are lots of pressing requirements, like the list we put down a few weeks ago?

Lars

Yes, we have a list of pressing requirements, one is implementing “easy-access-help” and the other is "datavalue-history ". For implementing first one I had small discussion with you, and we decided that I will look shortly if migrating from webwork to struts2 is possible. I managed to migrate one module to run on struts2, it is possible but takes some time and efforts. As all of us know webwork is not updated since mid 2007. “easy access help” was implemented, now I am working on second one. Hibernate has support for auditing persistent objects (“datavalue history”), that is what we want. But it comes with annotations only, so I decided to change hibernate libraries to host annotations, this is the reason. I think using existing functionality is much better than hand crafting history object for datavalue table. Latest Hibernate Core is 3.3.1.GA and Hibernate Annotations is 3.4.0 GA.
Why I said to Bob I am wotrking on this and that is because I have all in my branch and cannot split easily what he wants (poms). I cannot distribute pom with new hibernate dependencies, struts2, etc. That’s WHY I said lets discuss these issues before we have made such a change. It is better to discuss how to make these things happen, if they are useful. For hibernate I can say transision is transparent, we can move one object to annotation, while others are still in hbm.xml. For struts2 the same applies to some extend.

regards,
murod.

Yes, we have a list of pressing requirements, one is implementing “easy-access-help” and the other is “datavalue-history”. For implementing first one I had small discussion with you, and we decided that I will look shortly if migrating from webwork to struts2 is possible. I managed to migrate one module to run on struts2, it is possible but takes some time and efforts. As all of us know webwork is not updated since mid 2007

Yes, but we should still have a review of struts 2 before launching into it… Anyway there are hundreds of action classes, interceptors etc and it will be a big job to change things.

“easy access help” was implemented, now I am working on second one.

Nice.

Hibernate has support for auditing persistent objects (“datavalue history”), that is what we want. But it comes with annotations only, so I decided to change hibernate libraries to host annotations, this is the reason. I think using existing functionality is much better than hand crafting history object for datavalue table.

Why I said to Bob I am wotrking on this and that is because I have all in my branch and cannot split easily what he wants (poms). I cannot distribute pom with new hibernate dependencies, struts2, etc. That’s WHY I said lets discuss these issues before we have made such a change. It is better to discuss how to make these things happen, if they are useful. For hibernate I can say transision is transparent, we can move one object to annotation, while others are still in hbm.xml.

OK. If you can use this side-by-side it sounds like a good idea. Sorry if I am sticking my nose in everything, just interested in hearing the rationale behind it…

cheers, Lars

···

Yes, we have a list of pressing requirements, one is implementing
"easy-access-help" and the other is "datavalue-history". For implementing
first one I had small discussion with you, and we decided that I will look
shortly if migrating from webwork to struts2 is possible. I managed to
migrate one module to run on struts2, it is possible but takes some time and
efforts. As all of us know webwork is not updated since mid 2007

Yes, but we should still have a review of struts 2 before launching into
it... Anyway there are hundreds of action classes, interceptors etc and it
will be a big job to change things.

My count is just over 400 actions. And considerably fewer
interceptors. Mind you the transition from webwork to struts2 doesn't
appear catastrophic
(http://struts.apache.org/2.0.14/docs/key-changes-from-webwork-2.html\)
and probably a good bit could be automated. But I know, the devil is
always in the detail :slight_smile: But I agree with Murod - sitting on webwork
past its expiry date is a risk. The trouble is that such a migration
can't be a gradual one like the hibernate case. I guess it would be a
case of migrate one and all ...

Reminds me how it would be really useful to have some sort of selenium
test suite I wonder what came of Satvik's efforts to put together a
list of test cases for the webapp. Satvik, I saw the beginning of
this - can you share what you have?

What would the steps be in looking at such a proposal? Something like
1. review of struts2 and its differences from webwork leading to a
decision and prioritisation
2. compilation of selenium style battery tests covering at least the
results of 400 actions! Probably not all at once, but generally
something useful in itself.
3. creation of a migration branch
4. auto-convert as much as possible
5. cycle of test and fix what's still broken

"easy access help" was implemented, now I am working on second one.

Nice.

Hibernate has support for auditing persistent objects ("datavalue
history"), that is what we want. But it comes with annotations only, so I
decided to change hibernate libraries to host annotations, this is the
reason. I think using existing functionality is much better than hand
crafting history object for datavalue table.

Why I said to Bob I am wotrking on this and that is because I have all in
my branch and cannot split easily what he wants (poms). I cannot distribute
pom with new hibernate dependencies, struts2, etc.

I think that it would be really useful to be able to fix the poms with
the existing dependencies rather than wait for the outcome of what
might be a long and uncertain process. If you can just send the poms
I'd love to have a look. I'm far from a maven expert, but I'm getting
better.

On unix like systems (including probably cygwin):

find . -iname pom.xml |zip poms.zip -@

That's WHY I said lets
discuss these issues before we have made such a change. It is better to
discuss how to make these things happen, if they are useful. For hibernate I
can say transision is transparent, we can move one object to annotation,
while others are still in hbm.xml.

OK. If you can use this side-by-side it sounds like a good idea. Sorry if I
am sticking my nose in everything, just interested in hearing the rationale
behind it...

This gradual transition sounds do-able. Though I guess we are still
talking about a hibernate library upgrade even while still using a
mixture of modes.

Cheers
Bob

···

2009/4/14 Lars Helge Øverland <larshelge@gmail.com>:

Hi Bob,

< I think that it would be really useful to be able to fix the poms with
< the existing dependencies rather than wait for the outcome of what
< might be a long and uncertain process. If you can just send the poms
< I'd love to have a look. I'm far from a maven expert, but I'm getting
< better.
<
< On unix like systems (including probably cygwin):

< find . -iname pom.xml |zip poms.zip -@

edit main pom and add dhis-web as module. edit dhis-web pom and add dhis-web-portal as module
dhis
  <modules>
    <module>dhis-api</module>
    <module>dhis-i18n</module>
    <module>dhis-options</module>
    <module>dhis-services</module>
    <module>dhis-support</module>
    <module>dhis-useradminandsecurity</module>
    <module>dhis-web</module>
  </modules>

dhis-web

  <modules>
    <module>dhis-web-commons</module>
    <module>dhis-web-commons-resources</module>
    <module>dhis-web-maintenance</module>
    <module>dhis-web-dataentry</module>
    <module>dhis-web-importexport</module>
    <module>dhis-web-datamart</module>
    <module>dhis-web-validationrule</module>
    <module>dhis-web-reporting</module>
    <module>dhis-web-gis</module>
    <module>dhis-web-openhealth-integration</module>
    <module>dhis-web-dashboard-integration</module>
    <module>dhis-web-jforum-integration</module>
    <module>dhis-web-portal</module>
    <module>dhis-web-commons-struts2</module>
    <module>dhis-web-commons-resources-struts2</module>
    <module>dhis-web-importexport-struts2</module>
  </modules>

don't run mvn eclipse:eclipse

open eclipse

install tomcat from menu window - preferences - server

install maven multiproject import plugin Update site for Eclipse-Tools

install m2eclipse plugin http://m2eclipse.codehaus.org/update/

import dhis2 code using maven multiproject plugin (this should be under import - general - maven projects). You should see list of all projects in a hierarchy view.

to compile web modules
run… tick off resolve project artefacts checkbox (bug)
to debug use debug - on server.
goal - install

to run single web module right click on it, select run on server.

currently war overlaying is not supported by m2eclipse, so copy missing files in tomcat work directory from target/module name/ manually.

I didn't configure any profiler, so no idea on that.

I might missed something, feel free to ask. be careful, commit your code before these tasks.

regards,
murod

Thanks Murod.

Hi Bob,

< I think that it would be really useful to be able to fix the poms with
< the existing dependencies rather than wait for the outcome of what
< might be a long and uncertain process. If you can just send the poms
< I'd love to have a look. I'm far from a maven expert, but I'm getting
< better.
<
< On unix like systems (including probably cygwin):

< find . -iname pom.xml |zip poms.zip -@

edit main pom and add dhis-web as module. edit dhis-web pom and add dhis-web-portal as module
dhis

That makes sense. I thought you had mentioned some circular references before?

Regards
Bob

···

2009/4/14 Murodullo Latifov <murodlatifov@yahoo.com>:

<modules>
<module>dhis-api</module>
<module>dhis-i18n</module>
<module>dhis-options</module>
<module>dhis-services</module>
<module>dhis-support</module>
<module>dhis-useradminandsecurity</module>
<module>dhis-web</module>
</modules>

dhis-web

<modules>
<module>dhis-web-commons</module>
<module>dhis-web-commons-resources</module>
<module>dhis-web-maintenance</module>
<module>dhis-web-dataentry</module>
<module>dhis-web-importexport</module>
<module>dhis-web-datamart</module>
<module>dhis-web-validationrule</module>
<module>dhis-web-reporting</module>
<module>dhis-web-gis</module>
<module>dhis-web-openhealth-integration</module>
<module>dhis-web-dashboard-integration</module>
<module>dhis-web-jforum-integration</module>
<module>dhis-web-portal</module>
<module>dhis-web-commons-struts2</module>
<module>dhis-web-commons-resources-struts2</module>
<module>dhis-web-importexport-struts2</module>
</modules>

don't run mvn eclipse:eclipse

open eclipse

install tomcat from menu window - preferences - server

install maven multiproject import plugin Update site for Eclipse-Tools

install m2eclipse plugin http://m2eclipse.codehaus.org/update/

import dhis2 code using maven multiproject plugin (this should be under import - general - maven projects). You should see list of all projects in a hierarchy view.

to compile web modules
run… tick off resolve project artefacts checkbox (bug)
to debug use debug - on server.
goal - install

to run single web module right click on it, select run on server.

currently war overlaying is not supported by m2eclipse, so copy missing files in tomcat work directory from target/module name/ manually.

I didn't configure any profiler, so no idea on that.

I might missed something, feel free to ask. be careful, commit your code before these tasks.

regards,
murod

no, that was my misconfiguration in eclipse.

···

----- Original Message ----
From: Bob Jolliffe <bobjolliffe@gmail.com>
To: Murodullo Latifov <murodlatifov@yahoo.com>
Cc: Lars Helge Øverland <larshelge@gmail.com>; dhis2-devs <dhis2-devs@lists.launchpad.net>
Sent: Tuesday, April 14, 2009 7:47:44 PM
Subject: Re: [Dhis2-devs] pom files

Thanks Murod.

2009/4/14 Murodullo Latifov <murodlatifov@yahoo.com>:

Hi Bob,

< I think that it would be really useful to be able to fix the poms with
< the existing dependencies rather than wait for the outcome of what
< might be a long and uncertain process. If you can just send the poms
< I'd love to have a look. I'm far from a maven expert, but I'm getting
< better.
<
< On unix like systems (including probably cygwin):

< find . -iname pom.xml |zip poms.zip -@

edit main pom and add dhis-web as module. edit dhis-web pom and add dhis-web-portal as module
dhis

That makes sense. I thought you had mentioned some circular references before?

Regards
Bob

<modules>
   <module>dhis-api</module>
   <module>dhis-i18n</module>
   <module>dhis-options</module>
   <module>dhis-services</module>
   <module>dhis-support</module>
   <module>dhis-useradminandsecurity</module>
   <module>dhis-web</module>
</modules>

dhis-web

<modules>
   <module>dhis-web-commons</module>
   <module>dhis-web-commons-resources</module>
   <module>dhis-web-maintenance</module>
   <module>dhis-web-dataentry</module>
   <module>dhis-web-importexport</module>
   <module>dhis-web-datamart</module>
   <module>dhis-web-validationrule</module>
   <module>dhis-web-reporting</module>
   <module>dhis-web-gis</module>
   <module>dhis-web-openhealth-integration</module>
   <module>dhis-web-dashboard-integration</module>
   <module>dhis-web-jforum-integration</module>
   <module>dhis-web-portal</module>
   <module>dhis-web-commons-struts2</module>
   <module>dhis-web-commons-resources-struts2</module>
   <module>dhis-web-importexport-struts2</module>
</modules>

don't run mvn eclipse:eclipse

open eclipse

install tomcat from menu window - preferences - server

install maven multiproject import plugin Update site for Eclipse-Tools

install m2eclipse plugin http://m2eclipse.codehaus.org/update/

import dhis2 code using maven multiproject plugin (this should be under import - general - maven projects). You should see list of all projects in a hierarchy view.

to compile web modules
run… tick off resolve project artefacts checkbox (bug)
to debug use debug - on server.
goal - install

to run single web module right click on it, select run on server.

currently war overlaying is not supported by m2eclipse, so copy missing files in tomcat work directory from target/module name/ manually.

I didn't configure any profiler, so no idea on that.

I might missed something, feel free to ask. be careful, commit your code before these tasks.

regards,
murod

Sounds reasonable.

I am not saying switching to struts is a bad thing (I guess struts2 is more of a webwork continuation with some struts additions ++), just that it takes time and its a question of priority…

···

2009/4/14 Bob Jolliffe bobjolliffe@gmail.com

2009/4/14 Lars Helge Øverland larshelge@gmail.com:

Yes, we have a list of pressing requirements, one is implementing

“easy-access-help” and the other is “datavalue-history”. For implementing

first one I had small discussion with you, and we decided that I will look

shortly if migrating from webwork to struts2 is possible. I managed to

migrate one module to run on struts2, it is possible but takes some time and

efforts. As all of us know webwork is not updated since mid 2007

Yes, but we should still have a review of struts 2 before launching into

it… Anyway there are hundreds of action classes, interceptors etc and it

will be a big job to change things.

My count is just over 400 actions. And considerably fewer

interceptors. Mind you the transition from webwork to struts2 doesn’t

appear catastrophic

(http://struts.apache.org/2.0.14/docs/key-changes-from-webwork-2.html)

and probably a good bit could be automated. But I know, the devil is

always in the detail :slight_smile: But I agree with Murod - sitting on webwork

past its expiry date is a risk. The trouble is that such a migration

can’t be a gradual one like the hibernate case. I guess it would be a

case of migrate one and all …

Reminds me how it would be really useful to have some sort of selenium

test suite I wonder what came of Satvik’s efforts to put together a

list of test cases for the webapp. Satvik, I saw the beginning of

this - can you share what you have?

What would the steps be in looking at such a proposal? Something like

  1. review of struts2 and its differences from webwork leading to a

decision and prioritisation

  1. compilation of selenium style battery tests covering at least the

results of 400 actions! Probably not all at once, but generally

something useful in itself.

  1. creation of a migration branch

  2. auto-convert as much as possible

  3. cycle of test and fix what’s still broken