An Ecological View on Software Reuse

The increase of consumption is an important motivation for the reuse of either physical or virtual products. As the software market has risen, software reuse has become a practice with favourable effects for software development companies and their clients. The most important benefits are increased productivity, reduced costs, better and easier maintenance, decreased development lead times and the improved quality of software products. Successful reuse depends on several technical and non-technical factors. The ecological impact of software is an important non-technical factor of software reuse that needs to be analysed in the context of the rapid evolution of optimization techniques. The main goal of this study is to identify ecological perspectives on software reuse. These will complete the framework of software reuse together with other technical factors, such as compatibility, and non-technical factors, such as economic and ethical implications.


Introduction
Reuse is a component of the 3Rs (Reduce, Reuse and Recycle) promoted by environmental organizations around the world, such as the United States' Environmental Protection Agency (US EPA 2014) and the United Kingdom's Waste and Resources Action Programme (WRAP); it is also part of China's Circular Economy [1].Human consumption has increased significantly both in terms of products as well as services.Most of products and services are designed, manufactured and delivered by using hardware and software products or they are hardware and software products.The explosion of these technologies brings new challenges for humanity [2] [3].They influence climate change, biodiversity loss, and mineral scarcity, but their reuse could reduce waste and new production.In the case of software, in order to efficiently exploit the opportunities its reuse in multiple projects, it is very important to explicitly define this concept and its place in life cycle phases [4].Software reuse is the use of previously results from all phases of their life cycle: product line requirements, functions, architecture, design patterns and codes [5] [6] [7] [8].These practices should be anticipated from the conception and initiation phases of the project.Morisio et al. defined software reuse as "the systematic practice of developing software from a stock of building blocks, so that similarities in requirements and/or architecture between applications can be exploited to achieve substantial benefits in productivity, quality and business performance".Using existing components for building new applications reduces the effort of development [9].This includes not only the development of new software, but also the extraction of reusable parts of existing applications [10].The existence of the same requirements in more software project allows these practices.The availability of large numbers of open source projects is also a valuable source of reusable assets [11] and offers new possibilities for software reuse.The expected results are: increased productivity, reduced costs, better and easier maintenance, decreased development lead times and improved quality of software products.Software reuse is influenced by a wide variety of technical and non-technical factors.Projects evolve in order to meet new requirements or for maintenance reasons.In these circumstances, some changes will influence other projects that reuse the same components, especially in the case of library upgrades.According to Constantinou and Stamelos [11], software reuse is a recursive process that supposes the selection of reusable assets, upgrading libraries to the newest versions and fixing bugs.A feasibility and suitability analysis should be performed to ensure compatibility with the new application and compliance with customer requirements.Software reuse has important benefits for both companies and society.It would reduce negative environmental effects because companies would use less hardware and software resources in comparison with developing software from scratch.In order to ensure this, reusable components must satisfy quality criteria specifically for sustainable software.The rest of this paper is organized as follows.Section 2 reviews the related work on software reuse; section 3 presents the recent approaches regarding green and sustainable software and its contribution to environmental protection; section 4 describes ecological dimension of software reuse.Finally, section 5 concludes the paper and provides future research directions.

Related work
Various studies on reusing software are presented in the literature [7] [10] [11] [12] [13] [14].Additionally, software quality has been receiving a lot of attention, especially since the introduction of the concept of domain engineering, a component of software engineering [12].The other component is application engineering.According to Harsu, the domain engineering has "to provide the reusable core assets that are exploited during application engineering when assembling or customizing individual applications" [13].The same author calls domain engineering "engineering for reuse" and application engineering "engineering with reuse".The process is divided in three phases presented in Figure 1.[13], [14]) The evolution of software engineering has increased concerns regarding the development of sustainable software.Creating reusable components could positively contribute to these concerns.However, reusing software takes different forms.Jie et al. [12] identified the following two categories: product reuse and process reuse, depending on the reused Domain analysis • Specific domain information is identified and captured.In the future, the applications in the same field will be developed based on this information.Software reuse has advantages and challenges.Dabhade et al. [14] identified the following major benefits: increasing reliability and effectiveness, accelerating the development stage, increasing the productivity of software, minimizing operational and maintenance costs, enhancing system interoperability, developing software with less manpower, producing standardized software, delivering good quality software and obtaining competitive advantages.The most important challenge is technical compatibility with the system in which the components are integrated or reused.Technical compatibility is influenced by the level of reuse [15]: at a low level (reuse of design patterns), at a medium level (software reuse) or at a high level (when product line techniques are used to identify reusable components).It is also influenced by the architectural stability and evolution of the software.In order to measure these features, Constantinou and Stamelos have proposed six metrics for two project types: those intended to serve as reusable libraries and those that were not designed for reuse [11].Other technical challenges include increased maintenance costs when source code is not available, the lack of tool support, the expense of creating and maintaining reusable components in libraries, knowledge of requirements and reusable components, and legal issues [10] [14].Technical factors are crucial for software reuse, but non-technical ones are also very important.There are at least three nontechnical implications: economic, ethical and ecological.Economic and ethical implications are more evident and subject to study because they influence business decisions.The problem of environmental protection in the software industry is relatively new, even though information and communication technology (ICT) researchers and practitioners have been interested in environmental protection since the end of the last decade [16].These concerns should increase proportionally with the level of infiltration of ICT in economic and social life.They need to be analysed in accordance with the definition and characteristics of green software [17] [18] [19].In order to manage software reuse efficiently, the next section identifies and analyses ecological elements that must be considered in software reuse processes.These will complete the framework of software reuse.

Green and sustainable software
The interest in environmental protection through ICT has received particular attention over the last ten years.In 2008, the concept of green ICT was adopted in literature and practice to reflect these concerns.Although it has evolved and has been divided into specific areas, the most comprehensive definition remains the one given by Murugesan in 2008.According to this author, green ICT is "the study and practice of designing, manufacturing, using, and disposing of computers, servers, and associated subsystems-such as monitors, printers, storage devices, and networking and communications systems-efficiently and effectively with minimal or no impact on the environment.Green IT also strives to achieve economic viability and improved system performance and use, while abiding by our social and ethical responsibilities" [20].According to Vickery [21], the interaction between ICTs and the natural environment can be categorized into three levels: -Direct impactspositive and negative effects due directly to ICT goods and services and related processes; -Enabling impacts -ICT use that reduces environmental impacts across economic and social activities outside of the ICT field; and -Systemic impactsindividual and collective behavioural change.Most theoretical and practical initiatives have focused on direct impact, with a particular focus on positive and negative effects of the hardware, as their influences on the environment are more evident.However, in the past few years, new initiatives have emerged in research and practice to promote green and sustainable software.This software dictates how energy is consumed by any programmable device, although the ultimate responsibility is attributed to physical equipment [22].Optimization techniques aim to develop software to improve resource efficiency, including energy sources.The positive effects of software on the environment can be direct, by reducing negative ICT impacts, or indirect, by using software to support other business initiatives in reducing negative environmental impacts.In order to generate these influences, software must be green and sustainable.According to Dick et al. [23], green and sustainable software is "software, whose direct and indirect negative impacts on economy, society, human beings, and environment that result from development, deployment, and usage of the software are minimal and/or which has a positive effect on sustainable development".Sustainability is considered from three dimensions: social, economic and environmental [24].The last dimension corresponds to green software and can be divided according to its direct or indirect influences on the environment in "green by software" and "green in software".Table 2 presents these concepts and their impact on the environment.-Energy efficient software The concept of environmental protection in the software development life cycle has two main phases: software development and software execution [28] [29].In both phases, the main form of environmental protection is energy saving.This will have other positive influences, such as the reduction of CO2 emissions.In software development, energy can be saved by using more responsible ICT equipment, identifying existing modules or components and reusing them in new software, avoiding recurring work [28], switching equipment off or putting it in standby mode when not in use and employing refactoring strategies and self-adaptation techniques [22].In the design phase, the following methods exist to increase energy efficiency: efficient database queries (-25% energy consumption), optimized data management (+70% performance), flexible computation offload (-40% power consumption), smart use of web resources (-8.5% energy consumption), website content delivery (-45% energy consumption) and software refactoring (-50% energy consumption) [30].In software execution, energy can be saved by updating and reusing applications instead of developing new ones, selecting the most energy efficient software on the market and monitoring and optimizing energy consumption for all programmable devices.In both cases, software reuse could improve the process of software development from both a technical and non-technical perspective.Environmental protection is a non-technical motivator with long-term implications for all of society.

Ecological dimensions of software reuse
Software reuse is not new, but it still fails frequently in commercial companies, most often for human and organizational reasons and sometimes for technical reasons [31].Software engineers must find their own benefits of reusing software.Their personal values on environmental protection, together with organization strategies in the same field, could be sufficient incentives for adopting these practices.However, previous research in software reuse has focused most often on its economic and technical benefits; environmental implications have not been studied.Reusability is a criteria for sustainable software [32].Before deciding on the software components that should be reused at various stage of the software development life cycle, a feasibility study on their environmental impact is required.Even if reuse could be technically and economically favourable, from the viewpoint of influences on the environment the reuse of some software components could be less advantageous, due the rapid evolution of optimization techniques.According to Beghoura et al. [18], green constraints fit into the category of non-functional requirements, so they need to be explicitly defined in the requirements specification phase and supported by software design and implementation.Based on their opinion, the opportunity to reuse software must be analysed starting with initial requirements specifications.
These could include specifications on reducing energy consumption or using more environmentally friendly hardware or tools, if the client or the company developing the application has and applies strategies for environmental protection.These specifications could limit software reuse or could allow its reuse with modifying parameters or with modifying code and design.These practices consume more resources in the development stage, but are more eco-effective post-implementation.In addition, the new components that consume fewer resources will be reused later in other systems.Johann et al. [33] proposed the following activities in order to enhance an environmentally favourable impact over the whole life cycle: sustainability reviews and previews for every phase, process assessment and the sustainability retrospective.Before reusing a component, it must be evaluated according to environmental quality criteria.A presentation of the environmental impact, along with other aspects of software sustainability, need to be described in a sustainability journal [34].The environmental quality criteria must follow the same stages and activities as quality software evaluation: acceptance criteria, an environmental project quality plan, environmental quality criteria and the environmental quality assurance role that could be achieved by auditors [26].One solution is the labelling of software components and software products according to their influence on the environment.At present, there are some initiatives to label green software [35], but a standardized ecolabel is still missing [36].Previous studies show that neither programmers nor users request energy efficiency for their product and this concern is missing during maintenance [37] [38].In order to encourage the reuse of only green software components, these should be evaluated according to environmental criteria.Kern et al. proposed the following criteria for software evaluation: efficiency, feasibility and perdurability [35].
-Efficiency is defined as software behaviour when it can save resources and avoid waste [39]; -Feasibility refers to environmental impact resource-oriented feasibility (energy type, energy consumption, energy management options and carbon footprint) and social impactwell-being oriented feasibility (sustainability support, accessibility and usability) [39] [35]; and -Perdurability is "the degree to which a software product can be modified, adapted and reused in order to perform specified functions under specified conditions for a long period of time" [40].Perdurability refers directly to software reuse.In Standards ISO: 25010, Calero et al. [40] identified three characteristics related to this criteria: (1) reusabilitythe degree to which an asset can be used in more than one system, or in building other assets; (2) adaptabilitythe degree to which a product or system can effectively and efficiently be adapted for different or evolving hardware, software or other operational or usage environments; and (3) modifiabilitythe degree to which a product or system can be effectively and efficiently modified without introducing defects or degrading existing product quality [41].In Figure 2, perdurability aspects are presented separately by the development and usage phase.Fig. 1.Criteria for sustainable software products mapping to perdurability [35] The possible environmental impact is not the only challenge of software reuse for decreasing negative ecological influences.Software development teams need to anticipate future environmental regulations, best practices, norms and market trends [26].But awareness regarding environmental protection in the software industry starts with education.In general, green computing elements are missing in the training of programmers.According to Pang et al. [37], the influence of the algorithms used on energy consumption should be integrated into computer programming courses in university and school.These concerns also be included in software companies' strategies regarding environmental protection and in specifications of products and services [42].As a result of software reuse, the quality of the applications and systems will be improved.Efforts should be aimed at replacing or modifying components with high energy consumption or with other negative environmental effects.A classification of the components that could be reused according to ecological impact would be useful.Even in the absence of software component labelling standards, companies could have some internal criteria for environmental protection for these components.Figure 2   Starting from existing software components and based on the premise that the client, the developer or both are interested in developing environment-friendly systems, resource optimization specifications will be included in the task repository.These specifications are requirements that will need to be developed in a similar manner to functional requirements and will tested in accordance with ICT companies' and clients' strategies regarding environmental protection.Minimizing negative environmental impacts should be an indicator of software quality.To validate a favourable influence on the environment or to reduce negative environmental effects, the following metrics could be used: energy consumption, performance (response time), computing resource utilization (hard disk, storage, memory and I/O operations) and pollution or CO2 generated by software usage or development [43].In practice, it is recommended to use hybrid metrics to objectively and realistically assess the effects of developing new components versus software reuse, as well as the correlation between them.For example, in most cases, energy consumption increases the volume of CO2 in the context of significant energy use from non-green sources.

Conclusions
Software reuse has a wide variety of benefits for software companies and their clients.This practice saves costs and time, increases the quality of the application and improves maintenance.In order to increase the efficiency of ICT, it is recommended to reuse only the software that positively influences the environment or has a minimum negative impact.Reusing a component is not a guarantee for environmental benefits.This paper presents some ecological aspects of software reuse and the possibility of their integration into the software development life cycle.The integration of environmental concerns in software development is not new, but it has not been studied in the case of software reuse.In the medium and long term it will bring not only ecological benefits, but also financial and technical benefits.In future work, the ecological dimension of software reuse will be used to develop a framework for software reuse processes.