• Post Reply Bookmark Topic Watch Topic
  • New Topic

isses in writing a small debug application  RSS feed

 
Punit Jain
Ranch Hand
Posts: 1085
3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear All,

We at our organization use upgrade manager to upgrade from older release to newer release. internally this upgrade manager uses several migrators (each module/team has it's own migrator) to migrate from older release to newer.
The big pain is to debug these migrators, everyone escape their self from migrator issues because of this pain.

when we get customer issues, we try to reproduce them by simulating the migrator. to simulate the migrator we write the main method (in most of the migrators it's already written, we add it when we write that migrator) and call the migrator in that main method.
But for this we have to checkout the file write main method (if it's not there)and then call the class from cmd.

i was thinking of writing a small GUI app which simulates all this, so people can get rid of this pain.

Here are what issues i observed before start writing ::

1.> In the migrator we create db connection (we don't hardcode the connection but it automatically takes from the installation where we run the upgrade manager). so how do i will pass the hard coded connection from my app?

2.> in the GUI app i can give text fields where user can enter the migrator name and db details and in the backend i will create object of that migrator and call that migrator using main but:
what if that migrator already has a main method?

Let me know if it looks confusing?

Thanks,
Punit



 
K. Tsang
Bartender
Posts: 3648
16
Firefox Browser Java Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For your question 1: You may want to look into a properties file putting in the DB connection stuff and when program runs, read the values and make the JDBC url accordingly.

For your Q2: what's the difference between the original main and the one you write? Does modifying the original main needed in order to "debug" the application?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!