an aop approach to software energy efficiency in decentralised server systems

28
Green Software Samuel Chinenyeze :: Xiaodong Liu :: Ahmed Al-Dubai An AOP Approach to Software Energy Efficiency in Decentralised Server Systems Publication Authors: Download publication: http :// atlantis-press.com/php/paper-details.php?id=13432

Upload: samuel-chinenyeze

Post on 15-Aug-2015

69 views

Category:

Technology


4 download

TRANSCRIPT

Page 1: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Green Software

Samuel Chinenyeze :: Xiaodong Liu :: Ahmed Al-Dubai

An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Publication Authors:

Download publication: http://atlantis-press.com/php/paper-details.php?id=13432

Page 2: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Content

• Intro Greenness in Software

• Software Quality• AOP• Proposed Idea• Conclusion

Keywords:Green Software Engineering, Green Aspects, Greening Legacy Systems, Green Components

Page 3: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Intro

Green software is software which exhibits/ drives any or all of:

• efficient energy usage• efficient system resource usage• increased component reuse (at EOL)

Hierarchy of current research interest

Eco-friendly

Page 4: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Intro

Green software engineering investigates:

• Tools• Techniques and processes

to model, analyse and minimize the environmental impact of industrial solutions/ software.

Page 5: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Intro

• Green software engineeringtargets environmental impact of

industrial solutions : BY software : IN

• From our definition, greensoftware

exhibits eco-friendliness : IN drives eco-friendliness : BY

• greenness IN software• greenness BY software

aspects

Page 6: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Improving energy consumption• Monitor the application

• Identify causes of software bloat/areas of improvement

• Implement green policy1

• Test optimised version

1 Green policies are – principles known to be eco-friendly – concept adopted from green hardware. For software they involve optimised algorithms, inter-process communications…

Evolvability >>Resource efficiency >> Energy efficiency

Page 7: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Energy Efficiency Measurement techniques [1]

• Hardware measurement uses instruments to obtain real-time voltage and current and

compute the power and consumption. requires the support of special hardware.

• Software simulation works by a calibration system, e.g. Joulemeter. limitation: obtains the coarse power consumption at the level

of nodes.

• Theory computing exploits working frequency and voltage to calculate the power

consumption of CPU. lacks in accuracy

Page 8: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Still on techniques: theory computing is something like [2]…

Page 9: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Parameter Value

Processing Technology 65 nm CMOS

Number of Transistors (N) 582 million

Voltage Design (V) 1.2 V

Transistor Current (I) 11 uA

Transistor Transit Time (t) 32 psec

Clock Speed (S) 2.4 GHz

1.01 x Joules

Greenness in Software

Still on techniques: theory computing is something like…

Calculations &quantitative … good

~Lots of assumptions …not good

http://ark.intel.com/products/29765/

0.8500V-1.5V

X

X

Eper_sec = V * I * t * S

With Kentsfield-07 using provided valuesWith Ivy Bridge-12 [Intel i7-3632QM]

Codenames

X

INTEL CORE 2 QUAD Q6600 CPU SPECIFICATION

Page 10: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Just a thought ???

• How long does it take a research student to reproduce the results of an experiment?

• 1d, 2d, …, …, 1 week, … +

Page 11: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

• Energy Efficiency Measurement methods [3]Recall white box and black box testing.Intro to Software Engineering --- SE 101

Page 12: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Summary of current research process

New systems

Existing/legacy systems

Efficient development process

Optimised/energy-aware algorithms

Page 13: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Greenness in Software

Summary of current research process

New systems

Existing/legacy systems

Efficient development process

Optimised/energy-aware algorithms

System re-design

Component re-design

Page 14: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Software Quality

• Current research present ‘Greenness in software’ as an emerging quality attribute.

• Quality attributes Functional

• how well software meets functional requirements

Non-functional/structural• how well software meets non-functional requirements

• Software Quality is the degree to which a system, component, or process meets specified requirements. IEEE

Page 15: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Software QualityQuality Requirements

Functional RQs1

[rq1, rq2, …, rqN]

Non-functional Reliability, efficiency, security, maintainability…

1 Focus is on the functionalities : services provided by the system.

Novel industry development/provisioning approach seem to emphasize that ‘functional quality and user satisfaction are more important than structural quality’ in determining software quality.

Page 16: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Software Quality

• For instance: Cloud computing: provisioning computing as a service fQ: services on demand nQ: reliability, efficiency, security, maintainability

SaaS PaaS IaaS

*architectures: complex to maintain

*provisioning: compromising resource life span

*uptime: compromising energy

*middleware abstractions: compromising evolvability

*provisioning: compromising efficient resource utilization*provisioning: not

suitable for mission-critical jobs.

*compatibility across providers.

*unutilized modules: resource inefficient

Page 17: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Software Quality

…and here’s the misconception• Functional and Non-functional quality attributes

as External and Internal quality:

fQ : External nQ : Internal

critical to the user meaningful to the developer only

what a user experiences when running the software in its operational mode

aspects that are code-dependent, and that are not visible to the end-user

Page 18: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

AOP: a design technique

• “Systems are frequently redesigned not because they are functionally deficient but because they are difficult to maintain, port, or scale, or are too slow, or have been compromised by network hackers.” [4]

• AOP has been explored for several crosscutting concerns of software, such as security checks, performance, transaction management, error-handling, logging etc. [5]

• Instead of redesigning legacy systems for energy efficiency why not try AOP, with EE as a cross-cutting concern.

Page 19: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

AOP: a design technique

Without AOP With AOP

Using AOP, we can separate large chunk of cross-cutting concerns from code base and centralize them.

public class MyFirstClass{ public void amethod (String bar) { Logger.doLoggingBefore(); //business logic goes here Logger.doLoggingAfter(); }}public class MySecondClass{ public void function (Object arg) { Logger.doLoggingBefore(); //business logic goes here Logger.doLoggingAfter(); }}

public class MyFirstClass{ public void amethod (String bar) { //business logic goes here }}

public class MySecondClass{ public void function (Object arg) { //business logic goes here }}

public aspect LogInterceptor{ public Object invoke () { Logger.doLoggingBefore(); method.execute(); Logger.doLoggingAfter(); }}

Page 20: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea

Comprises of • A Model: AMEE• With an Algorithm

• AMEE: aspect model for energy efficiency

Page 21: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea

Decentralised layer

Actual request

handling

*Separate concerns

*Centralise resource status

*Share info - defined algorithm

Page 22: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea// aspect: EE-Aspect on main_server

continuous_check: monitor cpu_consumptionpointcut: before handling new client_request

advice:if (cpu_consumption > threshold)

{ 1. block service on main_server; 2. connect to free_server; 3. redirect client_request to free_server; 4. retrieve client_response from free_server; 5. send response from free_server to client;}

the algorithm: overload scenario

Page 23: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea

Sequence of implementation

White box measuring

Page 24: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea

Deployment diagram

~Software Simulation technique

Page 25: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Proposed Idea

Results

Time : response-time[start-time].

R : signifies that the client was redirected to an alternate server.

Page 26: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

Conclusions* Greenness in Software is of significance in attaining green IT.

* AOP as a design technique can be more explore in a wider range, for improving the energy consumption of existing software systems.

* As there are trade-offs in implementing various quality attributes – like security and availability. There are always trade-offs to be considered between performance and energy efficiency when it comes to green software.

* So far green software engineering benefits are better observed from the energy saving for hundreds/thousands of devices in a period of months/years is significant. This is especially true for server farms or cloud computing infrastructures that consist of hundred/thousands of Servers.

Page 27: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

[1] Q. Li and M. Zhou, “The Survey and Future Evolution of Green Computing,” 2011 IEEE/ACM International Conference on Green Computing and Communications, pp. 230–233, Aug. 2011.[2] B. Zhong, M. F. M. Feng, and C.-H. L. C.-H. Lung, “A Green Computing Based Architecture Comparison and Analysis,” 2010 IEEEACM Intl Conference on Green Computing and Communications Intl Conference on Cyber Physical and Social Computing, pp. 386–391, Dec. 2010.[3] T. Johann, M. Dick, S. Naumann, and E. Kern, “How to measure energy-efficiency of software: Metrics and measurement results,” 2012 First International Workshop on Green and Sustainable Software (GREENS), pp. 51–54, Jun. 2012. [4] L. Bass, P. Clements, and R. Kazman, Software Architecture in Practice, 2nd ed. Boston: Addison-Wesley Professional, 2003.[5] R. Laddad, AspectJ In Action: Enterprise AOP with Spring Applications, Second Ed. Manning Publications Co., 2010.

Publication download link:http://atlantis-press.com/php/download_paper.php?id=13432

References

Page 28: An AOP Approach to Software Energy Efficiency in Decentralised Server Systems

ThanksFeedback welcomed.

Dr Xiaodong Liu Dr Ahmed Al-Dubai Prof Emma HartDirector of Studies Second Supervisor Panel ChairCISS CDCS CEC

Samuel ChinenyezePhD StudentCISS