SlideShare una empresa de Scribd logo
1 de 19
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/

Más contenido relacionado

Similar a Remote Memory Areas for distributed real-time Java

Shree krishna 20140214
Shree krishna 20140214Shree krishna 20140214
Shree krishna 20140214
Shree Shrestha
 
Embedded Mirror Maker
Embedded Mirror MakerEmbedded Mirror Maker
Embedded Mirror Maker
Simon Suo
 
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
 
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
 
Distributes objects and Rmi
Distributes objects and RmiDistributes objects and Rmi
Distributes objects and Rmi
Mayank Jain
 
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 a 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...
 
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
 
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
 
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
 

Más de 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
 

Último

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 

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