SlideShare a Scribd company logo
Pablo Basanta Val& Marisol García Valls
DREQUIEM Lab.
Universidad Carlos III de Madrid
http://www.it.uc3m.es/drequiem/
Extending Distributed Real-
Time Java with Remote
Memory Areas
Outline
 Context
 {Real-Time Java}Context
 Distributed real-time Java
 Contribution:Remote Memory Areas
 Abstraction Overview
 Developer perspective
 Empirical Evaluation
 Conclusion and Future Work
Introduction
 Industrial applications may benefit from having high-
level programming abstractions
 E.g. MDA, MDE, Java, real-time Java
 Benefits
 Reduced development time
 Kind of applications developed
 More success in producing final products/developments
 Drawbacks
 These technologies are also source of their own issues
 Less tested technology
 Lower execution performance
 Specific research niches
Real-time Java technology
 Centralized efforts
 Leading effort RTSJ (Real-Time Specification for Java)
has
 An specification , several implementations ready to be used
 An high-integrity specification for Java is ongoing
 (SCSJ) Safety Critical Specification for Java
 A specification and partial implementation
 Distributed efforts
 Leading effort DRTSJ (Distributed Real-Time
Specification for Java) is upcoming
 More immature than RTSJ:
 No specification for DRTSJ,
 Only partial prototype implementations for RMI (Java Remote
Method Invocation).
The contribution in a nutshell
 Most approaches for distributed real-time Java
are based on remote invocations included in
Java’s RMI
 Well-known distributed object model
 This paper explores another approach that may
complement the RMI previous model: Remote
Memory Areas
“An RMA is generic set of mechanism that allows
execution of remote code in a remote node”
 Technical approach:
To transform RTSJ’s MemoryAreainto remote objects
 DRTSJ may benefit from RMAs.
Remote Memory Areas
 Based on the semantics
of the enter method of
RTSJ
 This method changes the
allocation context of a
thread when calling the
method
 RMAs extend the
semantic to a distributed
system
 Applications invoke on
remote memory areas
API of a Memory Area in RTSJ
01: public abstract class MemoryArea{
02: MemoryArea(long size)
03: void enter(Runnable logic)
04: void executeInArea(Runnable logic)
05: Object newInstance();
…
06: }
Local JVM
Local JVM Remote JVM
enter( )
enter( ) enter( )
(1)
(2)
Local
invocation
Remote
invocation
ss.run();
client server
Runnable
Schedulable
Remote Memory Areas: Interface
 Based on the semantics of the enter method of
RTSJ
 This method changes the allocation context of a
thread when calling the method
 RMAs extend the semantic to a distributed system
 Applications may invoke on remote memory areas
Remote Memory Area interface
01: RemoteMemoryArea extends java.rmi.Remote{
02: Schedulable enterSchedulable(Schedulable s)
03: throws RemoteException;
04: void enterAsyncSchedulable(Schedulable s)
05: throws RemoteException;
06:}
Remote Memory Areas: Issues
 Relationship with CPU
 Server defined
 Each remote objet has its own scheduling information
 Client-propagated Scheduling information
 Mainly Priorities
 Relationship with the garbage collector
 Heap dependant on a
 Interaction with the GC
 No-heap behavior in applications that do want
 No interaction with the GC
 Very specific programming model (NhRo-paradigm)
Type of application with RMAs
 Applications are defined
 as runnable objects with scheduling
information
 Each server
 Changes its scheduling parameters
 Executes the run method
 Restores its previous state
01: public class NormalizerFilter
02: implements Runnable, Serializable, Schedulable{
03: long samples[1024]; //Input and Output
03: public void run(){
04: for (int=0;i<1024; i++){
05: samples[i]=normalize(samples, i);
06: }
07:}
Heap remote memory area
00:class RemoteHeapMemory implements
01: RemoteMemoryArea, Schedulable{
02: public RemoteHeapMemory() {
03: }
04: public Schedulable enterSchedulable(Schedulable ss)
05: { Schedulable th=set_thread_parameters(ss);
06: ss.run();
07: restore_thead_parameters(th);
08: return ss;
09: }
10: public void enterAsyncSchedulable (Schedulable ss)
11: { RealtimeThread th= threadpool.getThread();
12: set_thread_parameters(ss);
13: th.runAsync(ss);
12: return;
13: }
...
14:}
No-GC Remote Memory Area
Implementation
Objects allocated in a LTMemory Instance from the LTMemoryAreaPool
Objects allocated in a LTMemory Instance from the LTMemoryAreaPool.
00:class RemoteLTMemoryAreaPool implements
01: RemoteMemoryArea, Schedulable{
02: public RemoteLTMemoryAreaPool(int ltmemory_size,
03: int element_size) {
04: ltmpool= new LTMemoryAreaPool(size,element_size);
05: }
06: public Schedulable enterSchedulable(Schedulable ss)
07: { Schedulable th=set_thread_parameters(ss);
08: ss.run();
09: restore_thead_parameters(th);
10: return ss;
11: }
11: public void enterAsyncSchedulable (Schedulable ss)
12: { threadpool.getThread().runAsync(ss);
13: return;
14: }
...
15:}
Developer Perspective
 An industrial
inspired use-
case
 A simple
distributed
application for
control that
i) reads data,
ii) processes
these data,
iii) and stores the
data
End-to-end application deadline
ProcessDataReadData WriteOutput
input
RTSJ-JVM
Server1
RTSJ-JVM
Server2
RTSJ-JVM
Server3
outputprocess
SRC
RMA
PROC
RMA
DEST
RMA
RMI RMI RMI
RMI
Registry
SRC
RMA
PROC
RMA
DEST
RMA
RTSJ-JVM
Client
RMI
enteSch
enterSch
enterSch
Step 1 Step 2 Step 3
ThreeStepsApp
The application in a
single Runnable class
 Three is a internal
counter (scount) that
decides in which step
is the application
 All public and
serializable attributes
are transferred from a
to the server
 (namely:
05: array
04: local
02: scount
)
00: public class ThreeStepsApp
01: extends Schedulable, Serializable{
02: int scount=0;
03: ...
04: boolean local=true;
05: long[] array= null;
06: ThreeStepsApp(...){
07: array=new long[1024];
08: }
09: public void run(){
10: scount ++;
11: switch(scount)
13: {
14: case 1: //First execution
15: for (int i=0; i<1024; i++)
16: { array[i]=input();
17: }
18: break;
19: case 2: //Second execution
20: for (int i=0; i<1024; i++)
21: { array[i]=process(array[i]);
22: }
23: case 3:
24: output(array[1023]);
25: break;
26: }
27: private trace(long){ … }
28: }
Running the example
 Periodically, it runs the three steps application
 At a 32 priority which is propagated from client to
servers
01:new RealtimeThread(){
02: public void run(){
03: setSchedulingParameters
04: (PriorityParamters(32));
05: ThreeStepsApp tsc= new ThreeStepsApp();
06: RemoteMemoryArea src=lookupSrc();
07: RemoteMemoryArea proc=lookupDest();
08: RemoteMemoryArea dest=lookupRemoteHeap();
09: tsc.setSchedulingParameters
10: (PriorityParamters(8));
11: do{
12: tsc=(TestSchedulable3)src.enterSchedulable(tsc);
12: tsc=(TestSchedulable3)proc.enterSchedulable(tsc);
13: tsc=(TestSchedulable3)dest.enterSchedulable(tsc);
14: waitForTheNextPeriod();
15: }while(true);
16:}.start();
Empirical evaluation
 Derived from the previous
application
 Control benchmark application
 The extension
 + RMAs
 + Lightweight RT-RMI Extensions
 Software stack
 Oracle’ JRTS.
 Two virtual machines running on an
800 MHz processor+100 Mbps
Ethernet.
 The underlying kernel is a real-time
Linux 3.0 rt-patched kernel on a
Debian 6.0 distribution
RT-RMI extensions
Oracle JRTS
Debian 3.0 rt-patch
Intel 800 Mhz -100 Mbits
RMAs
Extension
Control Application
Empirical evaluation results
 Parametric benchmark
 Array sizes from
 100 bytes,
 to
 1E05 bytes
 Not much overhead when
compared against
traditional RMI
 Similar results
 Overhead reduces with
high data volumes
 From [15% to less than
5%] in 100 bytes to 1E5
bytes
Conclusions
 A new way of performing remote communications
was proposed
 Remote Memory Area (RMA)s based on runnable
objects
 More low-level (& flexible than traditional remote
invocations)
 RMAs was evaluated with a distributed control
applications
 With an use case three steps application
 RMAs empirical evidence showed that
 They do not produce too much overhead
Ongoing Work
 Security issues:
 Safe execution of runnable objects in
servers
 Merging the model with other
architectural models
 With support from distributable threads
 As a means to provide real-time
reconfiguration
Any questions???
http://www.it.uc3m.es/drequiem/

More Related Content

Similar to Remote Memory Areas for distributed real-time Java

Shree krishna 20140214
Shree krishna 20140214Shree krishna 20140214
Shree krishna 20140214
Shree Shrestha
 
my accadanic project ppt
my accadanic project pptmy accadanic project ppt
my accadanic project ppt
Manivel Thiruvengadam
 
Anti patterns
Anti patternsAnti patterns
Anti patterns
Alex Tumanoff
 
Embedded Mirror Maker
Embedded Mirror MakerEmbedded Mirror Maker
Embedded Mirror Maker
Simon Suo
 
(DEV204) Building High-Performance Native Cloud Apps In C++
(DEV204) Building High-Performance Native Cloud Apps In C++(DEV204) Building High-Performance Native Cloud Apps In C++
(DEV204) Building High-Performance Native Cloud Apps In C++
Amazon Web Services
 
Cloud patterns - NDC Oslo 2016 - Tamir Dresher
Cloud patterns - NDC Oslo 2016 - Tamir DresherCloud patterns - NDC Oslo 2016 - Tamir Dresher
Cloud patterns - NDC Oslo 2016 - Tamir Dresher
Tamir Dresher
 
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
Chester Chen
 
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed KafsiSpark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit
 
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in SwitzerlandMobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
François Garillot
 
VideoMR - A Map and Reduce Framework for Real-time Video Processing
VideoMR - A Map and Reduce Framework for Real-time Video ProcessingVideoMR - A Map and Reduce Framework for Real-time Video Processing
VideoMR - A Map and Reduce Framework for Real-time Video Processing
Matthias Trapp
 
Enhancing the region model of RTSJ
Enhancing the region model of RTSJEnhancing the region model of RTSJ
Enhancing the region model of RTSJ
Universidad Carlos III de Madrid
 
2011.jtr.pbasanta.
2011.jtr.pbasanta.2011.jtr.pbasanta.
Java rmi example program with code
Java rmi example program with codeJava rmi example program with code
Java rmi example program with code
kamal kotecha
 
ST-Toolkit, a Framework for Trajectory Data Warehousing
ST-Toolkit, a Framework for Trajectory Data WarehousingST-Toolkit, a Framework for Trajectory Data Warehousing
ST-Toolkit, a Framework for Trajectory Data Warehousing
Simone Campora
 
Hadoop cluster performance profiler
Hadoop cluster performance profilerHadoop cluster performance profiler
Hadoop cluster performance profiler
Ihor Bobak
 
Java
JavaJava
Java
cafael
 
Rmi
RmiRmi
Distributes objects and Rmi
Distributes objects and RmiDistributes objects and Rmi
Distributes objects and Rmi
Mayank Jain
 
Ajila (1)
Ajila (1)Ajila (1)
Ajila (1)
akanksha kunwar
 
4CS4-25-Java-Lab-Manual.pdf
4CS4-25-Java-Lab-Manual.pdf4CS4-25-Java-Lab-Manual.pdf
4CS4-25-Java-Lab-Manual.pdf
amitbhachne
 

Similar to Remote Memory Areas for distributed real-time Java (20)

Shree krishna 20140214
Shree krishna 20140214Shree krishna 20140214
Shree krishna 20140214
 
my accadanic project ppt
my accadanic project pptmy accadanic project ppt
my accadanic project ppt
 
Anti patterns
Anti patternsAnti patterns
Anti patterns
 
Embedded Mirror Maker
Embedded Mirror MakerEmbedded Mirror Maker
Embedded Mirror Maker
 
(DEV204) Building High-Performance Native Cloud Apps In C++
(DEV204) Building High-Performance Native Cloud Apps In C++(DEV204) Building High-Performance Native Cloud Apps In C++
(DEV204) Building High-Performance Native Cloud Apps In C++
 
Cloud patterns - NDC Oslo 2016 - Tamir Dresher
Cloud patterns - NDC Oslo 2016 - Tamir DresherCloud patterns - NDC Oslo 2016 - Tamir Dresher
Cloud patterns - NDC Oslo 2016 - Tamir Dresher
 
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
SF Big Analytics 20191112: How to performance-tune Spark applications in larg...
 
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed KafsiSpark Summit EU talk by Francois Garillot and Mohamed Kafsi
Spark Summit EU talk by Francois Garillot and Mohamed Kafsi
 
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in SwitzerlandMobility insights at Swisscom - Understanding collective mobility in Switzerland
Mobility insights at Swisscom - Understanding collective mobility in Switzerland
 
VideoMR - A Map and Reduce Framework for Real-time Video Processing
VideoMR - A Map and Reduce Framework for Real-time Video ProcessingVideoMR - A Map and Reduce Framework for Real-time Video Processing
VideoMR - A Map and Reduce Framework for Real-time Video Processing
 
Enhancing the region model of RTSJ
Enhancing the region model of RTSJEnhancing the region model of RTSJ
Enhancing the region model of RTSJ
 
2011.jtr.pbasanta.
2011.jtr.pbasanta.2011.jtr.pbasanta.
2011.jtr.pbasanta.
 
Java rmi example program with code
Java rmi example program with codeJava rmi example program with code
Java rmi example program with code
 
ST-Toolkit, a Framework for Trajectory Data Warehousing
ST-Toolkit, a Framework for Trajectory Data WarehousingST-Toolkit, a Framework for Trajectory Data Warehousing
ST-Toolkit, a Framework for Trajectory Data Warehousing
 
Hadoop cluster performance profiler
Hadoop cluster performance profilerHadoop cluster performance profiler
Hadoop cluster performance profiler
 
Java
JavaJava
Java
 
Rmi
RmiRmi
Rmi
 
Distributes objects and Rmi
Distributes objects and RmiDistributes objects and Rmi
Distributes objects and Rmi
 
Ajila (1)
Ajila (1)Ajila (1)
Ajila (1)
 
4CS4-25-Java-Lab-Manual.pdf
4CS4-25-Java-Lab-Manual.pdf4CS4-25-Java-Lab-Manual.pdf
4CS4-25-Java-Lab-Manual.pdf
 

More from Universidad Carlos III de Madrid

Tecnicas y extensiones para Java de tiempo real
Tecnicas y extensiones para Java de tiempo realTecnicas y extensiones para Java de tiempo real
Tecnicas y extensiones para Java de tiempo real
Universidad Carlos III de Madrid
 
A simple data muling protocol
A simple data muling protocolA simple data muling protocol
A simple data muling protocol
Universidad Carlos III de Madrid
 
Mejoras a la predictibilidad de la tecnología Java EE
Mejoras a la predictibilidad de la tecnología Java EEMejoras a la predictibilidad de la tecnología Java EE
Mejoras a la predictibilidad de la tecnología Java EE
Universidad Carlos III de Madrid
 
Fine
FineFine
Basanta jtr2009
Basanta jtr2009Basanta jtr2009
No Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time JavaNo Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time Java
Universidad Carlos III de Madrid
 
A synchronous scheduling service for distributed real-time Java
A synchronous scheduling service for distributed real-time JavaA synchronous scheduling service for distributed real-time Java
A synchronous scheduling service for distributed real-time Java
Universidad Carlos III de Madrid
 
Simple asynchronous remote invocations for distributed real-time Java
Simple asynchronous remote invocations for distributed real-time JavaSimple asynchronous remote invocations for distributed real-time Java
Simple asynchronous remote invocations for distributed real-time Java
Universidad Carlos III de Madrid
 
Pbasanta@jtres06 extendedportal
Pbasanta@jtres06 extendedportalPbasanta@jtres06 extendedportal
Pbasanta@jtres06 extendedportal
Universidad Carlos III de Madrid
 

More from Universidad Carlos III de Madrid (9)

Tecnicas y extensiones para Java de tiempo real
Tecnicas y extensiones para Java de tiempo realTecnicas y extensiones para Java de tiempo real
Tecnicas y extensiones para Java de tiempo real
 
A simple data muling protocol
A simple data muling protocolA simple data muling protocol
A simple data muling protocol
 
Mejoras a la predictibilidad de la tecnología Java EE
Mejoras a la predictibilidad de la tecnología Java EEMejoras a la predictibilidad de la tecnología Java EE
Mejoras a la predictibilidad de la tecnología Java EE
 
Fine
FineFine
Fine
 
Basanta jtr2009
Basanta jtr2009Basanta jtr2009
Basanta jtr2009
 
No Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time JavaNo Heap Remote Objects for Distributed real-time Java
No Heap Remote Objects for Distributed real-time Java
 
A synchronous scheduling service for distributed real-time Java
A synchronous scheduling service for distributed real-time JavaA synchronous scheduling service for distributed real-time Java
A synchronous scheduling service for distributed real-time Java
 
Simple asynchronous remote invocations for distributed real-time Java
Simple asynchronous remote invocations for distributed real-time JavaSimple asynchronous remote invocations for distributed real-time Java
Simple asynchronous remote invocations for distributed real-time Java
 
Pbasanta@jtres06 extendedportal
Pbasanta@jtres06 extendedportalPbasanta@jtres06 extendedportal
Pbasanta@jtres06 extendedportal
 

Recently uploaded

Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
saastr
 
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
Chart Kalyan
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
Zilliz
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
Zilliz
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Malak Abu Hammad
 
WeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation TechniquesWeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation Techniques
Postman
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
saastr
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
HarisZaheer8
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
SitimaJohn
 
Operating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptxOperating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptx
Pravash Chandra Das
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
Zilliz
 
Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!
GDSC PJATK
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
MichaelKnudsen27
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
alexjohnson7307
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Jeffrey Haguewood
 

Recently uploaded (20)

Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
Deep Dive: AI-Powered Marketing to Get More Leads and Customers with HyperGro...
 
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfHow to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdf
 
Programming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup SlidesProgramming Foundation Models with DSPy - Meetup Slides
Programming Foundation Models with DSPy - Meetup Slides
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
 
WeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation TechniquesWeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation Techniques
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
 
Operating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptxOperating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptx
 
Fueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte WebinarFueling AI with Great Data with Airbyte Webinar
Fueling AI with Great Data with Airbyte Webinar
 
Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!Finale of the Year: Apply for Next One!
Finale of the Year: Apply for Next One!
 
Nordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptxNordic Marketo Engage User Group_June 13_ 2024.pptx
Nordic Marketo Engage User Group_June 13_ 2024.pptx
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
 
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...
 

Remote Memory Areas for distributed real-time Java

  • 1. Pablo Basanta Val& Marisol García Valls DREQUIEM Lab. Universidad Carlos III de Madrid http://www.it.uc3m.es/drequiem/ Extending Distributed Real- Time Java with Remote Memory Areas
  • 2. Outline  Context  {Real-Time Java}Context  Distributed real-time Java  Contribution:Remote Memory Areas  Abstraction Overview  Developer perspective  Empirical Evaluation  Conclusion and Future Work
  • 3. Introduction  Industrial applications may benefit from having high- level programming abstractions  E.g. MDA, MDE, Java, real-time Java  Benefits  Reduced development time  Kind of applications developed  More success in producing final products/developments  Drawbacks  These technologies are also source of their own issues  Less tested technology  Lower execution performance  Specific research niches
  • 4. Real-time Java technology  Centralized efforts  Leading effort RTSJ (Real-Time Specification for Java) has  An specification , several implementations ready to be used  An high-integrity specification for Java is ongoing  (SCSJ) Safety Critical Specification for Java  A specification and partial implementation  Distributed efforts  Leading effort DRTSJ (Distributed Real-Time Specification for Java) is upcoming  More immature than RTSJ:  No specification for DRTSJ,  Only partial prototype implementations for RMI (Java Remote Method Invocation).
  • 5. The contribution in a nutshell  Most approaches for distributed real-time Java are based on remote invocations included in Java’s RMI  Well-known distributed object model  This paper explores another approach that may complement the RMI previous model: Remote Memory Areas “An RMA is generic set of mechanism that allows execution of remote code in a remote node”  Technical approach: To transform RTSJ’s MemoryAreainto remote objects  DRTSJ may benefit from RMAs.
  • 6. Remote Memory Areas  Based on the semantics of the enter method of RTSJ  This method changes the allocation context of a thread when calling the method  RMAs extend the semantic to a distributed system  Applications invoke on remote memory areas API of a Memory Area in RTSJ 01: public abstract class MemoryArea{ 02: MemoryArea(long size) 03: void enter(Runnable logic) 04: void executeInArea(Runnable logic) 05: Object newInstance(); … 06: } Local JVM Local JVM Remote JVM enter( ) enter( ) enter( ) (1) (2) Local invocation Remote invocation ss.run(); client server Runnable Schedulable
  • 7. Remote Memory Areas: Interface  Based on the semantics of the enter method of RTSJ  This method changes the allocation context of a thread when calling the method  RMAs extend the semantic to a distributed system  Applications may invoke on remote memory areas Remote Memory Area interface 01: RemoteMemoryArea extends java.rmi.Remote{ 02: Schedulable enterSchedulable(Schedulable s) 03: throws RemoteException; 04: void enterAsyncSchedulable(Schedulable s) 05: throws RemoteException; 06:}
  • 8. Remote Memory Areas: Issues  Relationship with CPU  Server defined  Each remote objet has its own scheduling information  Client-propagated Scheduling information  Mainly Priorities  Relationship with the garbage collector  Heap dependant on a  Interaction with the GC  No-heap behavior in applications that do want  No interaction with the GC  Very specific programming model (NhRo-paradigm)
  • 9. Type of application with RMAs  Applications are defined  as runnable objects with scheduling information  Each server  Changes its scheduling parameters  Executes the run method  Restores its previous state 01: public class NormalizerFilter 02: implements Runnable, Serializable, Schedulable{ 03: long samples[1024]; //Input and Output 03: public void run(){ 04: for (int=0;i<1024; i++){ 05: samples[i]=normalize(samples, i); 06: } 07:}
  • 10. Heap remote memory area 00:class RemoteHeapMemory implements 01: RemoteMemoryArea, Schedulable{ 02: public RemoteHeapMemory() { 03: } 04: public Schedulable enterSchedulable(Schedulable ss) 05: { Schedulable th=set_thread_parameters(ss); 06: ss.run(); 07: restore_thead_parameters(th); 08: return ss; 09: } 10: public void enterAsyncSchedulable (Schedulable ss) 11: { RealtimeThread th= threadpool.getThread(); 12: set_thread_parameters(ss); 13: th.runAsync(ss); 12: return; 13: } ... 14:}
  • 11. No-GC Remote Memory Area Implementation Objects allocated in a LTMemory Instance from the LTMemoryAreaPool Objects allocated in a LTMemory Instance from the LTMemoryAreaPool. 00:class RemoteLTMemoryAreaPool implements 01: RemoteMemoryArea, Schedulable{ 02: public RemoteLTMemoryAreaPool(int ltmemory_size, 03: int element_size) { 04: ltmpool= new LTMemoryAreaPool(size,element_size); 05: } 06: public Schedulable enterSchedulable(Schedulable ss) 07: { Schedulable th=set_thread_parameters(ss); 08: ss.run(); 09: restore_thead_parameters(th); 10: return ss; 11: } 11: public void enterAsyncSchedulable (Schedulable ss) 12: { threadpool.getThread().runAsync(ss); 13: return; 14: } ... 15:}
  • 12. Developer Perspective  An industrial inspired use- case  A simple distributed application for control that i) reads data, ii) processes these data, iii) and stores the data End-to-end application deadline ProcessDataReadData WriteOutput input RTSJ-JVM Server1 RTSJ-JVM Server2 RTSJ-JVM Server3 outputprocess SRC RMA PROC RMA DEST RMA RMI RMI RMI RMI Registry SRC RMA PROC RMA DEST RMA RTSJ-JVM Client RMI enteSch enterSch enterSch Step 1 Step 2 Step 3 ThreeStepsApp
  • 13. The application in a single Runnable class  Three is a internal counter (scount) that decides in which step is the application  All public and serializable attributes are transferred from a to the server  (namely: 05: array 04: local 02: scount ) 00: public class ThreeStepsApp 01: extends Schedulable, Serializable{ 02: int scount=0; 03: ... 04: boolean local=true; 05: long[] array= null; 06: ThreeStepsApp(...){ 07: array=new long[1024]; 08: } 09: public void run(){ 10: scount ++; 11: switch(scount) 13: { 14: case 1: //First execution 15: for (int i=0; i<1024; i++) 16: { array[i]=input(); 17: } 18: break; 19: case 2: //Second execution 20: for (int i=0; i<1024; i++) 21: { array[i]=process(array[i]); 22: } 23: case 3: 24: output(array[1023]); 25: break; 26: } 27: private trace(long){ … } 28: }
  • 14. Running the example  Periodically, it runs the three steps application  At a 32 priority which is propagated from client to servers 01:new RealtimeThread(){ 02: public void run(){ 03: setSchedulingParameters 04: (PriorityParamters(32)); 05: ThreeStepsApp tsc= new ThreeStepsApp(); 06: RemoteMemoryArea src=lookupSrc(); 07: RemoteMemoryArea proc=lookupDest(); 08: RemoteMemoryArea dest=lookupRemoteHeap(); 09: tsc.setSchedulingParameters 10: (PriorityParamters(8)); 11: do{ 12: tsc=(TestSchedulable3)src.enterSchedulable(tsc); 12: tsc=(TestSchedulable3)proc.enterSchedulable(tsc); 13: tsc=(TestSchedulable3)dest.enterSchedulable(tsc); 14: waitForTheNextPeriod(); 15: }while(true); 16:}.start();
  • 15. Empirical evaluation  Derived from the previous application  Control benchmark application  The extension  + RMAs  + Lightweight RT-RMI Extensions  Software stack  Oracle’ JRTS.  Two virtual machines running on an 800 MHz processor+100 Mbps Ethernet.  The underlying kernel is a real-time Linux 3.0 rt-patched kernel on a Debian 6.0 distribution RT-RMI extensions Oracle JRTS Debian 3.0 rt-patch Intel 800 Mhz -100 Mbits RMAs Extension Control Application
  • 16. Empirical evaluation results  Parametric benchmark  Array sizes from  100 bytes,  to  1E05 bytes  Not much overhead when compared against traditional RMI  Similar results  Overhead reduces with high data volumes  From [15% to less than 5%] in 100 bytes to 1E5 bytes
  • 17. Conclusions  A new way of performing remote communications was proposed  Remote Memory Area (RMA)s based on runnable objects  More low-level (& flexible than traditional remote invocations)  RMAs was evaluated with a distributed control applications  With an use case three steps application  RMAs empirical evidence showed that  They do not produce too much overhead
  • 18. Ongoing Work  Security issues:  Safe execution of runnable objects in servers  Merging the model with other architectural models  With support from distributable threads  As a means to provide real-time reconfiguration