Analyzing the effects of refactorings on bad smells

Detalhes bibliográficos
Autor(a) principal: Cleiton Silva Tavares
Data de Publicação: 2021
Tipo de documento: Dissertação
Idioma: eng
Título da fonte: Repositório Institucional da UFMG
Texto Completo: http://hdl.handle.net/1843/38392
Resumo: Refactoring aims to increase software systems' maintainability by improving their structure without changing their behavior, may applied to remove bad smells. Even with tools to assist refactoring, many developers do not trust their solutions, claiming that some studies show that refactoring can introduce new bad smells into the source code. However, we have not found a complete catalog that states when this may occur. To investigate this subject deeply, the goal of this dissertation is to evaluate the effects of refactoring on bad smells. Specifically, we want to know if and what refactoring removes bad smells or introduces them. To achieve this goal, we conducted a Systematic Literature Review (SLR) to identify the relationship between refactorings and bad smells proposed by Fowler. We also conducted an empirical study with eight software systems applying five refactorings to analyze their effects on ten bad smells with the assist of five tools. As a result of the empirical study, we present, through the data studied, which bad smells tend to be removed or introduced by the automated refactoring process. In the SLR, we found 20 papers showing the direct relationship between 31 refactorings and 16 bad smells. We produced a catalog showing these relationships, and we also showed a contrast with relationships discussed by Fowler. We identified that the most discussed relationship in the literature is between Move Method and Feature Envy. The SLR also revealed different refactoring strategies than those discussed by Fowler for dealing with bad smells. In the empirical study, we observed that refactoring generated decrease, increase, and neutral variations in the number of bad smells. Unlike Fowler's definition, we surprisingly found that the number of bad smells decrease was the lowest compared to cases of increase and neutral variations. In an additional analysis, we contrast the results found in the two studies carried out, classifying, validating and complementing them.
id UFMG_007a027a5b2ca88f583c020981284ea5
oai_identifier_str oai:repositorio.ufmg.br:1843/38392
network_acronym_str UFMG
network_name_str Repositório Institucional da UFMG
repository_id_str
spelling Mariza Andrade da Silva Bigonhahttp://lattes.cnpq.br/6660127471891321Eduardo Magno Lages FigueiredoAndré Cavalcante HoraKécia Aline Marques Ferreirahttp://lattes.cnpq.br/1929115389330037Cleiton Silva Tavares2021-10-17T23:37:41Z2021-10-17T23:37:41Z2021-03-31http://hdl.handle.net/1843/38392Refactoring aims to increase software systems' maintainability by improving their structure without changing their behavior, may applied to remove bad smells. Even with tools to assist refactoring, many developers do not trust their solutions, claiming that some studies show that refactoring can introduce new bad smells into the source code. However, we have not found a complete catalog that states when this may occur. To investigate this subject deeply, the goal of this dissertation is to evaluate the effects of refactoring on bad smells. Specifically, we want to know if and what refactoring removes bad smells or introduces them. To achieve this goal, we conducted a Systematic Literature Review (SLR) to identify the relationship between refactorings and bad smells proposed by Fowler. We also conducted an empirical study with eight software systems applying five refactorings to analyze their effects on ten bad smells with the assist of five tools. As a result of the empirical study, we present, through the data studied, which bad smells tend to be removed or introduced by the automated refactoring process. In the SLR, we found 20 papers showing the direct relationship between 31 refactorings and 16 bad smells. We produced a catalog showing these relationships, and we also showed a contrast with relationships discussed by Fowler. We identified that the most discussed relationship in the literature is between Move Method and Feature Envy. The SLR also revealed different refactoring strategies than those discussed by Fowler for dealing with bad smells. In the empirical study, we observed that refactoring generated decrease, increase, and neutral variations in the number of bad smells. Unlike Fowler's definition, we surprisingly found that the number of bad smells decrease was the lowest compared to cases of increase and neutral variations. In an additional analysis, we contrast the results found in the two studies carried out, classifying, validating and complementing them.Refatoração visa aumentar a manutenibilidade de sistemas de software melhorando a sua estrutura sem alterar seu comportamento, podendo ser aplicada para remover bad smells. Mesmo com a existência de ferramentas para auxiliar a refatoração, muitos desenvolvedores não confiam em suas soluções, alegando que alguns estudos mostram que a refatoração pode introduzir novos bad smells no código-fonte. Contudo, não encontramos um catálogo completo que indique quando isso ocorre. Para investigar esse assunto em detalhe, o objetivo desta dissertação é avaliar os efeitos da refatoração em bad smells. Especificamente, investigamos se e qual refatoração remove bad smells ou os introduz. Para atingir esse objetivo, realizamos uma Revisão Sistemática da Literatura (RSL) para identificar a relação entre as refatorações e os bad smells propostos por Fowler. Conduzimos um estudo empírico com oito sistemas de software, aplicando cinco refatorações para analisar seus efeitos em dez bad smells com o auxílio de cinco ferramentas. Como resultado do estudo empírico, apresentamos via os dados estudados, quais bad smells são removidos ou introduzidos pelo processo de refatoração automatizada. A RSL resultou em 20 artigos mostrando a relação direta entre 31 refatorações e 16 bad smells. Produzimos um catálogo exibindo essas relações e também apresentamos um contraste com as relações discutidas por Fowler. Identificamos que a relação mais discutida na literatura se dá entre Move Method e Feature Envy. A RSL também revelou que existem estratégias de refatoração diferentes daquelas discutidas por Fowler para lidar com bad smells. No estudo empírico, observamos que os tipos de refatoração geraram diminuição, aumento e variações neutras no número de bad smells. Diferente da definição de Fowler, surpreendentemente descobrimos que a diminuição no número de bad smells foi a mais baixa em comparação com casos de aumento e variações neutras. Em uma análise adicional, contrastamos os resultados encontrados nos dois estudos realizados, classificando-os, validando-os e complementando-os.CAPES - Coordenação de Aperfeiçoamento de Pessoal de Nível SuperiorengUniversidade Federal de Minas GeraisPrograma de Pós-Graduação em Ciência da ComputaçãoUFMGBrasilICX - DEPARTAMENTO DE CIÊNCIA DA COMPUTAÇÃOComputação – TesesEngenharia de Software – TesesSoftware - Refatoração– TesesBad smell – TesesRefactoringBad smellRefactoring impactsRefactoring effectsAnalyzing the effects of refactorings on bad smellsAnalisando os efeitos da refatoração em bad smellsinfo:eu-repo/semantics/publishedVersioninfo:eu-repo/semantics/masterThesisinfo:eu-repo/semantics/openAccessreponame:Repositório Institucional da UFMGinstname:Universidade Federal de Minas Gerais (UFMG)instacron:UFMGORIGINALDissertacao_Digital.pdfDissertacao_Digital.pdfapplication/pdf1024198https://repositorio.ufmg.br/bitstream/1843/38392/3/Dissertacao_Digital.pdfd2c68f331863968d139e243247448c80MD53LICENSElicense.txtlicense.txttext/plain; charset=utf-82118https://repositorio.ufmg.br/bitstream/1843/38392/4/license.txtcda590c95a0b51b4d15f60c9642ca272MD541843/383922021-10-17 20:37:42.059oai:repositorio.ufmg.br:1843/38392TElDRU7Dh0EgREUgRElTVFJJQlVJw4fDg08gTsODTy1FWENMVVNJVkEgRE8gUkVQT1NJVMOTUklPIElOU1RJVFVDSU9OQUwgREEgVUZNRwoKQ29tIGEgYXByZXNlbnRhw6fDo28gZGVzdGEgbGljZW7Dp2EsIHZvY8OqI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BIERFIEZPTUVOVE8gT1UgT1VUUk8gT1JHQU5JU01PLCBWT0PDiiBERUNMQVJBIFFVRSBSRVNQRUlUT1UgVE9ET1MgRSBRVUFJU1FVRVIgRElSRUlUT1MgREUgUkVWSVPDg08gQ09NTyBUQU1Cw4lNIEFTIERFTUFJUyBPQlJJR0HDh8OVRVMgRVhJR0lEQVMgUE9SIENPTlRSQVRPIE9VIEFDT1JETy4KCk8gUmVwb3NpdMOzcmlvIEluc3RpdHVjaW9uYWwgZGEgVUZNRyBzZSBjb21wcm9tZXRlIGEgaWRlbnRpZmljYXIgY2xhcmFtZW50ZSBvIHNldSBub21lKHMpIG91IG8ocykgbm9tZXMocykgZG8ocykgZGV0ZW50b3IoZXMpIGRvcyBkaXJlaXRvcyBhdXRvcmFpcyBkYSBwdWJsaWNhw6fDo28sIGUgbsOjbyBmYXLDoSBxdWFscXVlciBhbHRlcmHDp8OjbywgYWzDqW0gZGFxdWVsYXMgY29uY2VkaWRhcyBwb3IgZXN0YSBsaWNlbsOnYS4KRepositório de PublicaçõesPUBhttps://repositorio.ufmg.br/oaiopendoar:2021-10-17T23:37:42Repositório Institucional da UFMG - Universidade Federal de Minas Gerais (UFMG)false
dc.title.pt_BR.fl_str_mv Analyzing the effects of refactorings on bad smells
dc.title.alternative.pt_BR.fl_str_mv Analisando os efeitos da refatoração em bad smells
title Analyzing the effects of refactorings on bad smells
spellingShingle Analyzing the effects of refactorings on bad smells
Cleiton Silva Tavares
Refactoring
Bad smell
Refactoring impacts
Refactoring effects
Computação – Teses
Engenharia de Software – Teses
Software - Refatoração– Teses
Bad smell – Teses
title_short Analyzing the effects of refactorings on bad smells
title_full Analyzing the effects of refactorings on bad smells
title_fullStr Analyzing the effects of refactorings on bad smells
title_full_unstemmed Analyzing the effects of refactorings on bad smells
title_sort Analyzing the effects of refactorings on bad smells
author Cleiton Silva Tavares
author_facet Cleiton Silva Tavares
author_role author
dc.contributor.advisor1.fl_str_mv Mariza Andrade da Silva Bigonha
dc.contributor.advisor1Lattes.fl_str_mv http://lattes.cnpq.br/6660127471891321
dc.contributor.advisor-co1.fl_str_mv Eduardo Magno Lages Figueiredo
dc.contributor.referee1.fl_str_mv André Cavalcante Hora
dc.contributor.referee2.fl_str_mv Kécia Aline Marques Ferreira
dc.contributor.authorLattes.fl_str_mv http://lattes.cnpq.br/1929115389330037
dc.contributor.author.fl_str_mv Cleiton Silva Tavares
contributor_str_mv Mariza Andrade da Silva Bigonha
Eduardo Magno Lages Figueiredo
André Cavalcante Hora
Kécia Aline Marques Ferreira
dc.subject.por.fl_str_mv Refactoring
Bad smell
Refactoring impacts
Refactoring effects
topic Refactoring
Bad smell
Refactoring impacts
Refactoring effects
Computação – Teses
Engenharia de Software – Teses
Software - Refatoração– Teses
Bad smell – Teses
dc.subject.other.pt_BR.fl_str_mv Computação – Teses
Engenharia de Software – Teses
Software - Refatoração– Teses
Bad smell – Teses
description Refactoring aims to increase software systems' maintainability by improving their structure without changing their behavior, may applied to remove bad smells. Even with tools to assist refactoring, many developers do not trust their solutions, claiming that some studies show that refactoring can introduce new bad smells into the source code. However, we have not found a complete catalog that states when this may occur. To investigate this subject deeply, the goal of this dissertation is to evaluate the effects of refactoring on bad smells. Specifically, we want to know if and what refactoring removes bad smells or introduces them. To achieve this goal, we conducted a Systematic Literature Review (SLR) to identify the relationship between refactorings and bad smells proposed by Fowler. We also conducted an empirical study with eight software systems applying five refactorings to analyze their effects on ten bad smells with the assist of five tools. As a result of the empirical study, we present, through the data studied, which bad smells tend to be removed or introduced by the automated refactoring process. In the SLR, we found 20 papers showing the direct relationship between 31 refactorings and 16 bad smells. We produced a catalog showing these relationships, and we also showed a contrast with relationships discussed by Fowler. We identified that the most discussed relationship in the literature is between Move Method and Feature Envy. The SLR also revealed different refactoring strategies than those discussed by Fowler for dealing with bad smells. In the empirical study, we observed that refactoring generated decrease, increase, and neutral variations in the number of bad smells. Unlike Fowler's definition, we surprisingly found that the number of bad smells decrease was the lowest compared to cases of increase and neutral variations. In an additional analysis, we contrast the results found in the two studies carried out, classifying, validating and complementing them.
publishDate 2021
dc.date.accessioned.fl_str_mv 2021-10-17T23:37:41Z
dc.date.available.fl_str_mv 2021-10-17T23:37:41Z
dc.date.issued.fl_str_mv 2021-03-31
dc.type.status.fl_str_mv info:eu-repo/semantics/publishedVersion
dc.type.driver.fl_str_mv info:eu-repo/semantics/masterThesis
format masterThesis
status_str publishedVersion
dc.identifier.uri.fl_str_mv http://hdl.handle.net/1843/38392
url http://hdl.handle.net/1843/38392
dc.language.iso.fl_str_mv eng
language eng
dc.rights.driver.fl_str_mv info:eu-repo/semantics/openAccess
eu_rights_str_mv openAccess
dc.publisher.none.fl_str_mv Universidade Federal de Minas Gerais
dc.publisher.program.fl_str_mv Programa de Pós-Graduação em Ciência da Computação
dc.publisher.initials.fl_str_mv UFMG
dc.publisher.country.fl_str_mv Brasil
dc.publisher.department.fl_str_mv ICX - DEPARTAMENTO DE CIÊNCIA DA COMPUTAÇÃO
publisher.none.fl_str_mv Universidade Federal de Minas Gerais
dc.source.none.fl_str_mv reponame:Repositório Institucional da UFMG
instname:Universidade Federal de Minas Gerais (UFMG)
instacron:UFMG
instname_str Universidade Federal de Minas Gerais (UFMG)
instacron_str UFMG
institution UFMG
reponame_str Repositório Institucional da UFMG
collection Repositório Institucional da UFMG
bitstream.url.fl_str_mv https://repositorio.ufmg.br/bitstream/1843/38392/3/Dissertacao_Digital.pdf
https://repositorio.ufmg.br/bitstream/1843/38392/4/license.txt
bitstream.checksum.fl_str_mv d2c68f331863968d139e243247448c80
cda590c95a0b51b4d15f60c9642ca272
bitstream.checksumAlgorithm.fl_str_mv MD5
MD5
repository.name.fl_str_mv Repositório Institucional da UFMG - Universidade Federal de Minas Gerais (UFMG)
repository.mail.fl_str_mv
_version_ 1801676605966254080