Hi Roberto! Great job looking at the issues quantitatively. Your
research will be very helpful for improving Mifos!

To anyone on the list who wants to chime in, see lower in this email for
the start of the conversation.

On Thu, Feb 28, 2008 at 1:56 AM, Roberto Musso wrote:
>    Database Schema Portability

This is the only portability issue we're focusing on within the scope of
issue 1513.

>    As we are using InnoDB tables the following reccomendation apply:
>
>    Using InnoDB tables to avoid Data Transfer problems set
>    lower_case_table_names to 1 on all platforms to force names to be
>    converted to lowercase

No. As you noted earlier, we're not concerned about data portability.
As far as we know, we don't currently have problems with data
portability.

>    Maximize the portability with a consistent naming convention and have
>       all database names and tables name in *LOWER CASE*.
>
>     Risks
>    HIGH
>    Mifos 1.1 release is very near at the testing time for rewritten code
>  and sql.

Refer back to my list of things to keep in mind while fixing this issue,
especially:

* don't worry about the "schema freeze". This is not technically a
schema change, since, currently, an uppercase table name is equivalent
to a lowercase table name in every existing running instance of Mifos.

And I would like to add to the list:

* we want to emphasize convention over configuration

>     Impact
>     HIGH

No, I don't agree. Again, everyone currently either
* runs on Windows (case is ignored by default)
* runs on a *NIX-like OS with lower_case_table_names set to 1.

I would concede that it does require changes to many files, but so do
many of the patches we receive.

>  2. Use lower_case_table_names=1 on *ALL* Platform
>   This is a *SOLUTION* as at build/configuration time this variable can be
>  set automatically in the MySQL config file (we can discuss how to do).

I don't agree that the risks and impacts are LOW.
* this is not something we want to automate nor maintain later
* it is too specific to MySQL
* it overcomplicates the build.xml file
* it requires more custom MySQL configuration settings specific to Mifos
* it requires root access or password entry on *NIX-like systems
* it still requires modification of the MySQL configuration file

>  3. Use lower_case_table_names=0 on Unix and lower_case_table_names=2 on
>  Windows.
>
>  *WE WILL NOT CONSIDERER THIS SOLUTION (third)*

Yep, this is out since we want to try to emphasize convention over
configuration.


For those just joining the discussion, here is my original email to Roberto:

On Wed, Feb 27, 2008 at 7:29 AM, Adam Monsen wrote:
> Hi Roberto,
>
>  Let's adjust this plan a bit keeping in mind the following:
>  * lowercasing table names should be the priority in fixing issue 1513
>  * no current deployments on Linux/UNIX exist today, so changing table
>  names from upper to lowercase will have no effect for most everyone
>  besides a few developers
>  * don't worry about the "schema freeze". This is not technically a
>  schema change, since, currently, an uppercase table name is equivalent
>  to a lowercase table name in every existing running instance of Mifos.
>  * no upgrade/downgrade scripts should be required since this is not
>  technically a migration
>  * the naming convention is good enough for now, and can evolve over
>  time as necessary
>  * the work can/should be performed *iteratively*. Meaning, submit one
>  patch a week until the work is done.
>
>  So, here's what I have in mind:
>  [_] change table names found in any .sql file to lowercase, EXCEPT do
>  not change upgrade_to_* and downgrade_from_* scripts or create any new
>  .sql files
>  [_] change table names found in any .java file to lowercase (custom
>  SQL, for instance)
>  [_] change table names found in any .hbm.xml file to lowercase
>
>  That's it. That should be the entire plan for fixing issue 1513, and
>  that is what should be estimated and worked on right now. Once this is
>  complete, the work can be verified by connecting to a MySQL instance
>  running on a Linux or Mac OS X box wherein the lower_case_table_names
>  setting has not been changed from the default.
>
>  After this is complete, we can proceed to:
>  [_] amend the database naming convention
>  [_] add static code verification test to ensure table names remain lowercase
>
>  How does that sound?
>
>  Ok, now I'm back on vacation for the day. :)
>  Talk with you soon.
>
>  On Wed, Feb 27, 2008 at 12:34 AM, Roberto Musso <[EMAIL PROTECTED]> wrote:
>  > Hi Adam,
>  >  I hope you are enjoying your holiday and I will try do not disturb you too
>  >  much, but Max asked me to give you some estimation.
>  >
>  >  1. Update The Dtabase Naming convention at
>  >
>  > http://mifos.org/developers/wiki/ImproveDatabaseNaming
>  >     Still big diferences with the proposal Max and I did. As Max said
>  >  yesterday the document was too verbose, but looking at
>  >  http://mifos.org/developers/wiki/ImproveDatabaseNaming and your notes,
>  >  still big diffrences.  I guess that the last word is to  you, so if you
>  >  have already btaken the decisions, as for your comment mail, pls let us
>  >  know.
>  >
>  >  2. If I well understood the plan would be as written on Issue Tracker 
> 1513.
>  >  Confirm?
>  >  3. We will try to make the changes in table names to lower case (*ONLY*
>  >  table names in lower case, not other change in SQL is foreseen)  ready for
>  >  the end of March, if shoi=uld not be ready they will postponed to Mifos
>  >  1.2. Confirm?
>  >  4. The database frozen is a condition for realizing the job for teh end of
>  >  March
>  >
>  >
>  >  Pleas amend what you think I have not understood.
>  >
>  >  Best
>
>
>  --
>  Adam Monsen
>

And here is his response:

On Thu, Feb 28, 2008 at 1:56 AM, Roberto Musso wrote:
> Hello Adam and good morning,
>  I have just summarized everything to address correctly what I beleive it is
>  an architectural issue and not a simple patch on a bug.
>
>  The Issue 1513 correctly reports a bug: Mifos is not working on Linux (and
>  will not work on Mac).
>
>  This issue represents a new requirement  for Mifos (Mifos 1.1 or later?) to
>  work also on Linux and Mac OS X.
>  A new requirement requires a feasibility and analysis study. In my opinion
>  to have Mifos working on different platforms and to allow the possibility
>  of moving from Windows to Linux (is this the objective, right?) we need to
>  have *PORTABILITY*.
>  What is Portability ?
>
>    Code Portability
>    Database Schema Portability
>    Data Portability
>    Portability on different Database than MYSQL
>
>  I hope I didn't forget anything.
>
>  We would like to focus on 1 and 2.
>
>  Focusing on these two points and reading the MySQL documentation
>  (http://dev.mysql.com/doc/refman/5.0/en/identifier-case-sensitivity.html) I
>  believe there are multiple ways to address it:
>
>    1. Maximize the portability with a consistent naming convention and have
>    all database names and tables name in *LOWER CASE*.
>
>
>    2. Use lower_case_table_names=1 on *ALL* Platform
>    This is a *SOLUTION* as at build/configuration time this variable can be
>    set automatically in the MySQL config file (we can discuss how to do).
>    As we are using InnoDB tables the following reccomendation apply:
>
>    Using InnoDB tables to avoid Data Transfer problems set
>    lower_case_table_names to 1 on all platforms to force names to be
>    converted to lowercase
>
>
>    3. Use lower_case_table_names=0 on Unix and lower_case_table_names=2 on
>    Windows.
>
>  We can now make a quality evaluation of these *3 solutions* as proposed by
>  MySQL
>
>    Maximize the portability with a consistent naming convention and have
>       all database names and tables name in *LOWER CASE*.
>
>    Data Portability
>     Maximized
>
>    Schema Portability
>    To be tested on MacX
>
>      Advantages:
>     No change at configuration file level. No need further scripts
>
>      Disadvantages:
>     Some Code and sql scripts must be rewritten
>
>      Estimation Time:
>     3-4 weeks (could be more if the Unit Test will be the same as now). A
>  system tets shoudl be planned.
>
>     Risks
>    HIGH
>    Mifos 1.1 release is very near at the testing time for rewritten code
>  and sql.
>
>     Impact
>     HIGH
>
>
>  2. Use lower_case_table_names=1 on *ALL* Platform
>   This is a *SOLUTION* as at build/configuration time this variable can be
>  set automatically in the MySQL config file (we can discuss how to do).
>
>   Data Portability
>   Some more test should be carried, but we normally dump the data on Windows
>  and we recover on Linux.
>
>   Schema Portability
>   Setting lower_case_table_names=1 all platforms means forcing names to be
>  converted to lowercase. We use the portability from Windows to Linux
>
>   Advantages:
>   Quick and easy to be implemented
>
>   This is exactly as difficult as to set and environment variable and can
>  be easily scripted
>
>   No more problem for Unix/MacX users as lower_case_table_names=1  is
>  enforced at build time or running a script that we can release.
>
>      Disadvantages:
>     In the config MySQL file of all platform lower_case_table_names=1 means
>  , as Adam pointed out, imposing to MySQL other databases on the same system
>  a global setting maybe un-wanted
>
>     The command SHOW TABLES or SHOW DATABASES,  do not show the names in
>  their original lettercase
>
>      Estimation Time:
>     Less than one week depending on which implementation (ant task ,
>  separate script, README).
>     Putting in the README can be operating from next building.
>
>     Risks
>    LOW
>
>     Impact
>     LOW
>
>
>  3. Use lower_case_table_names=0 on Unix and lower_case_table_names=2 on
>  Windows.
>
>  *WE WILL NOT CONSIDERER THIS SOLUTION (third)*
>
>  In the MySQL documentation there is teh following:  Note that if you force
>  this variable to 0 with --lower-case-table-names=0 on a case-insensitive
>  filesystem and access MyISAM tablenames using different lettercases, index
>  corruption may result"
>
>
>  It should be clear that a consistent Naming Conventions and scripts to
>  check the respect of the Naming Convention are valid for both Solution 1
>  and Solution 2.
>
>  I hope I have listed all the main decision points for this architectural
>  issue.
>
>  Best Regards,
>
>

Regarding Mac OS X:

On Wed, Feb 27, 2008 at 9:35 AM, Sam Birney wrote:
>
>  We are not supporting Mac OS X for Mifos as of now, so don't worry
>  about it. I will be happy to maintain that platform though and fix
>  any Mac-specific bugs though :)
>
>
>
>
>  On 2/27/08 9:14 AM, "Massimiliano Parlione" <[EMAIL PROTECTED]> wrote:
>
>  > Hi,
>  > MACOS/X is not a platform that we can test here.
>  >

-- 
Adam Monsen

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

Reply via email to