You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by Miles Teg <la...@gmail.com> on 2016/05/02 23:25:49 UTC

About refactoring

Hello Everyone,

I'm part of a team trying to analyse the effects of refactoring on large
codebases. In this regard, we are analysing the Felix project and its
JIRA tickets.

We would like to know:
i) Do you follow a particular conventions for changes that are
refactorings: e.g. special ticket type or commit messages
ii) Are there specific tickets that are examples of large-scale
refactorings that were done with the intention of improving maintainability.

Would appreciate any pointers in this regard :)

Thank you in advance,
Miles

Re: About refactoring

Posted by Miles Teg <la...@gmail.com>.
Dear Ray and David,

Thank you very much for the quick and valuable replies :)

Best Regards,
Miles

On Tue, May 3, 2016 at 12:44 AM, David Jencks <
david_jencks@yahoo.com.invalid> wrote:

> First of all, what Ray said :-)
>
> Due to the nature of Felix, where there are generally “subprojects” of one
> or a very few bundles implementing an OSGI specification, any refactoring
> efforts are almost certain to be confined to one of these subprojects.  I
> think I’ve been the main contributor to the scr project for several years
> now (although there have also been extremely important contributions from
> at least Carsten and Guillaume) so I’ll speak to that.
>
> I don’t use any special Jira issue type.  I generally do refactoring prior
> to making significant changes in order to make the new functionality
> possible to implement.  I often try to separate the refactoring into one or
> more commits separate from the new functionality, but I don’t always
> succeed; sometimes as I implement the new functionality I discover the need
> for more refactoring.  I’ve sometimes tried to use git rebase -i to collect
> all the refactoring into sequential commits and the new functionality into
> later, sequential, commits.  Sometimes everything ends up in one svn
> commit.  I don’t think my refactoring is often “pure” in that I try to
> rearrange code so less logic is needed and try to fix
> lack-of-special-case-handling and similar problems while rearranging stuff,
> so the behavior is usually slightly  different (and hopefully more correct)
> after than before.
>
> Hope this helps,
> david jencks
>
> > On May 2, 2016, at 2:50 PM, Raymond Auge <ra...@liferay.com>
> wrote:
> >
> > The first thing I would offer is that the felix project is an OSGi
> project
> > and with that it follows OSGi Semantic Versioning (
> > https://www.osgi.org/wp-content/uploads/SemanticVersioning.pdf)
> >
> > The effect of semantic versioning to API design is dramatic in that APIs
> > are designed to be concise and cohesive and results in the very rare need
> > to do wide ranging refactorings. If you look across the felix project (or
> > similarly well structured and OSGi projects) you should note a
> dramatically
> > reduced amount of large scale refactoring. Most refactoring is limited to
> > single or very few bundles at a time.
> >
> > I'm sure there are others who can share more details about your specific
> > questions about JIRA and commit practices, but I don't recall any
> specific
> > process for those (but I'm pretty new to it so...)
> >
> > - Ray
> >
> > On Mon, May 2, 2016 at 5:25 PM, Miles Teg <la...@gmail.com> wrote:
> >
> >> Hello Everyone,
> >>
> >> I'm part of a team trying to analyse the effects of refactoring on large
> >> codebases. In this regard, we are analysing the Felix project and its
> >> JIRA tickets.
> >>
> >> We would like to know:
> >> i) Do you follow a particular conventions for changes that are
> >> refactorings: e.g. special ticket type or commit messages
> >> ii) Are there specific tickets that are examples of large-scale
> >> refactorings that were done with the intention of improving
> >> maintainability.
> >>
> >> Would appreciate any pointers in this regard :)
> >>
> >> Thank you in advance,
> >> Miles
> >>
> >
> >
> >
> > --
> > *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
> > (@rotty3000)
> > Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
> > (@Liferay)
> > Board Member & EEG Co-Chair, OSGi Alliance <http://osgi.org>
> (@OSGiAlliance)
>
>

Re: About refactoring

Posted by David Jencks <da...@yahoo.com.INVALID>.
First of all, what Ray said :-)

Due to the nature of Felix, where there are generally “subprojects” of one or a very few bundles implementing an OSGI specification, any refactoring efforts are almost certain to be confined to one of these subprojects.  I think I’ve been the main contributor to the scr project for several years now (although there have also been extremely important contributions from at least Carsten and Guillaume) so I’ll speak to that.

I don’t use any special Jira issue type.  I generally do refactoring prior to making significant changes in order to make the new functionality possible to implement.  I often try to separate the refactoring into one or more commits separate from the new functionality, but I don’t always succeed; sometimes as I implement the new functionality I discover the need for more refactoring.  I’ve sometimes tried to use git rebase -i to collect all the refactoring into sequential commits and the new functionality into later, sequential, commits.  Sometimes everything ends up in one svn commit.  I don’t think my refactoring is often “pure” in that I try to rearrange code so less logic is needed and try to fix lack-of-special-case-handling and similar problems while rearranging stuff, so the behavior is usually slightly  different (and hopefully more correct) after than before.

Hope this helps,
david jencks

> On May 2, 2016, at 2:50 PM, Raymond Auge <ra...@liferay.com> wrote:
> 
> The first thing I would offer is that the felix project is an OSGi project
> and with that it follows OSGi Semantic Versioning (
> https://www.osgi.org/wp-content/uploads/SemanticVersioning.pdf)
> 
> The effect of semantic versioning to API design is dramatic in that APIs
> are designed to be concise and cohesive and results in the very rare need
> to do wide ranging refactorings. If you look across the felix project (or
> similarly well structured and OSGi projects) you should note a dramatically
> reduced amount of large scale refactoring. Most refactoring is limited to
> single or very few bundles at a time.
> 
> I'm sure there are others who can share more details about your specific
> questions about JIRA and commit practices, but I don't recall any specific
> process for those (but I'm pretty new to it so...)
> 
> - Ray
> 
> On Mon, May 2, 2016 at 5:25 PM, Miles Teg <la...@gmail.com> wrote:
> 
>> Hello Everyone,
>> 
>> I'm part of a team trying to analyse the effects of refactoring on large
>> codebases. In this regard, we are analysing the Felix project and its
>> JIRA tickets.
>> 
>> We would like to know:
>> i) Do you follow a particular conventions for changes that are
>> refactorings: e.g. special ticket type or commit messages
>> ii) Are there specific tickets that are examples of large-scale
>> refactorings that were done with the intention of improving
>> maintainability.
>> 
>> Would appreciate any pointers in this regard :)
>> 
>> Thank you in advance,
>> Miles
>> 
> 
> 
> 
> -- 
> *Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
> (@rotty3000)
> Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
> (@Liferay)
> Board Member & EEG Co-Chair, OSGi Alliance <http://osgi.org> (@OSGiAlliance)


Re: About refactoring

Posted by Raymond Auge <ra...@liferay.com>.
The first thing I would offer is that the felix project is an OSGi project
and with that it follows OSGi Semantic Versioning (
https://www.osgi.org/wp-content/uploads/SemanticVersioning.pdf)

The effect of semantic versioning to API design is dramatic in that APIs
are designed to be concise and cohesive and results in the very rare need
to do wide ranging refactorings. If you look across the felix project (or
similarly well structured and OSGi projects) you should note a dramatically
reduced amount of large scale refactoring. Most refactoring is limited to
single or very few bundles at a time.

I'm sure there are others who can share more details about your specific
questions about JIRA and commit practices, but I don't recall any specific
process for those (but I'm pretty new to it so...)

- Ray

On Mon, May 2, 2016 at 5:25 PM, Miles Teg <la...@gmail.com> wrote:

> Hello Everyone,
>
> I'm part of a team trying to analyse the effects of refactoring on large
> codebases. In this regard, we are analysing the Felix project and its
> JIRA tickets.
>
> We would like to know:
> i) Do you follow a particular conventions for changes that are
> refactorings: e.g. special ticket type or commit messages
> ii) Are there specific tickets that are examples of large-scale
> refactorings that were done with the intention of improving
> maintainability.
>
> Would appreciate any pointers in this regard :)
>
> Thank you in advance,
> Miles
>



-- 
*Raymond Augé* <http://www.liferay.com/web/raymond.auge/profile>
 (@rotty3000)
Senior Software Architect *Liferay, Inc.* <http://www.liferay.com>
 (@Liferay)
Board Member & EEG Co-Chair, OSGi Alliance <http://osgi.org> (@OSGiAlliance)