List:Internals« Previous MessageNext Message »
From:MARK CALLAGHAN Date:March 5 2009 7:32pm
Subject:Re: MySQL University Session: Good Coding Style follow up
View as plain text  
On Thu, Mar 5, 2009 at 11:01 AM, Konstantin Osipov <kostja@stripped> wrote:
> * MARK CALLAGHAN <mdcallag@stripped> [09/03/05 19:05]:
>
>> > All code contributed to the server must adhere to a coding
>> > style. Since many parts of the server historically originate from
>> > different development environments, it seems unnecessary to demand
>> > that all technical teams follow the same style. Besides, the
>> > existing code base doesn't satisfy this requirement.
>> Excluding storage engines, I hoped that MySQL would go from no enforcement
>> of coding style to enforcement for their chosen style.
>
> Not that Monty left this can only happen after a broad acceptance
> among the technical leads.
>
> I agree with your view, but suggesting a process is a step towards
> gaining support. I learned it hard way that it's impossible to
> enforce a dead document - one that has not been reviewed for
> years.
>
> I will be utmost happy if runtime, optimizer, replication, backup
> and engines (i.e. all teams excluding the storage engines) agree
> to have a single style.

Well, the benevolent dictator has been replaced by his trusted
lieutenants. Now it is your turn. I hope that you (leads from teams
listed above) can agree that there is one coding style for MySQL
excluding storage engines founded upon the belief that 'x= 2' is much
better than 'x = 2'.

>
> Once acceptance is gained, we can proceed with enforcement.
>
>> The URL you cite
>> describes a style. Why can't all code other than storage engines accept
>> that?
>
> Generally, yes. I also noticed that when we talk about the style,
> we pay more attention to it.
>
>> If there is a coding style per area then those of us who work on code
>> in multiple areas need multiple vim/emacs config files. Code styles are
>> bound to generate a lot of process and criticism. With one style rather than
>> many, much less energy will be used for all of that.
>
> I agree. How would you, however, enforce a single style in a
> distributed organization without a single leader, like ours?
> The only solution I see is developing a procedure, that's what I
> am trying to do.

Can you reach consensus among team leads?

If all decisions are voted on by all of us (direct democracy) I think
that it will be hard to make decisions. And then who gets to vote? Can
I vote twice -- mcallaghan@google and mdcallag@gmail?

>
>> And to make this more fun, how are files in the sql directory classified?
>> And who are the captains? How many different guides must I remember if I
>> were to review a patch?
>
> In the proposal, I suggest that a single module always follows a
> single style. sql/ is mainly runtime and the optimizer. I
> certainly hope that we will be able to follow a single style.
>
>> No role has been described for the external developer community. Can we
>> select our own style?
>
> The suggestion is that the style is set for a technical area.  To
> account for opinions of external contributors we need to develop a
> notion of core contributors -- a sort of meritocracy, when an
> opinion counts based on the contribution.  In any case, I am not
> suggesting to exclude non-staff contributors from the decision making.
>
> --
>



-- 
Mark Callaghan
mdcallag@stripped
Thread
MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
  • Re: MySQL University Session: Good Coding Style follow upRoy Lyseng5 Mar
    • Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
      • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar
    • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar
      • Re: MySQL University Session: Good Coding Style follow upRoy Lyseng8 Mar
        • Re: MySQL University Session: Good Coding Style follow upMichael Widenius9 Mar
          • Re: MySQL University Session: Good Coding Style follow upJay Pipes9 Mar
            • Re: MySQL University Session: Good Coding Style follow upMichael Widenius11 Mar
              • Re: MySQL University Session: Good Coding Style follow upJay Pipes11 Mar
                • Re: MySQL University Session: Good Coding Style follow upMichael Widenius18 Mar
      • Re: MySQL University Session: Good Coding Style follow upStewart Smith17 Mar
  • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN5 Mar
    • Re: MySQL University Session: Good Coding Style follow upIngo Strüwing5 Mar
      • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN5 Mar
        • Re: MySQL University Session: Good Coding Style follow upIngo Strüwing5 Mar
          • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN5 Mar
            • Re: MySQL University Session: Good Coding Style follow upJay Pipes5 Mar
              • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar
                • Re: MySQL University Session: Good Coding Style follow upJay Pipes8 Mar
            • Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
              • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN5 Mar
              • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar
    • Re: MySQL University Session: Good Coding Style follow upSergey Petrunia5 Mar
  • Re: MySQL University Session: Good Coding Style follow upDavi Arnaut5 Mar
    • Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
      • Re: MySQL University Session: Good Coding Style follow upDavi Arnaut5 Mar
  • Re: MySQL University Session: Good Coding Style follow upJonas Oreland5 Mar
    • Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
      • Re: MySQL University Session: Good Coding Style follow upJonas Oreland5 Mar
        • Re: MySQL University Session: Good Coding Style follow upshlomo.swidler5 Mar
          • Re: MySQL University Session: Good Coding Style follow upMichael Izioumtchenko5 Mar
        • Re: MySQL University Session: Good Coding Style follow upMichael Izioumtchenko5 Mar
        • Re: MySQL University Session: Good Coding Style follow upStewart Smith17 Mar
      • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar
Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov5 Mar
  • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN5 Mar
  • Re: MySQL University Session: Good Coding Style follow upMichael Widenius6 Mar
    • Re: MySQL University Session: Good Coding Style follow upKonstantin Osipov6 Mar
      • Re: MySQL University Session: Good Coding Style follow upMARK CALLAGHAN6 Mar
      • Re: MySQL University Session: Good Coding Style follow upMichael Widenius8 Mar