Remote Method Invocation-
Distributed Application Architecture
Presented by,
C.Dhivyasri
I-M.Sc(Computer Science)
Nadar Saraswathi College of Arts and Science
Definition of RMI
• Remote Method Invocation (RMI) is a Java-based technology that allows an
object running in one Java Virtual Machine (JVM) to invoke methods on an object
running in another JVM, typically on a different physical machine.
• Remote Method Invocation (RMI) is a mechanism that enables the invocation of
methods that reside on a remote object (i.e., an object located on another computer
in a network) as if they were local to the calling program.
Key Characteristics
• Distributed Computing: Enables building distributed applications in Java.
• Transparency: Remote objects can be used as if they were local objects.
• Stubs and Skeletons: Uses stub (client-side proxy) and skeleton (server-
side handler, in older RMI versions) to handle communication.
• Serialization: Parameters and return values must be serializable for
network transmission.
Example: Java RMI -
Hello Service
We’ll create:
• A Remote Interface
• A Remote Implementation
• A Server to register the remote object
• A Client to invoke the remote method
Diagram for RMI
Client
Stub
RRL
Transport
Layer
Server
Skeleton
RRL
Transport
Layer
Virtual
Connection
Network
Connection
Important of RMI Components
• Client: Looks up remote objects and invokes their methods.
• Server: Registers with the RMI registry and handles client method calls.
• RMI Registry: Provides remote object lookup; can run on the server host or
elsewhere, and may be a JNDI server.
• Web Server: Hosts remote object classes for client download via HTTP.
Definition of Distributed
Application Architecture
Distributed Application Architecture in Java refers to the design and
development of Java applications where different components (such as user
interfaces, business logic, and data storage) run on multiple networked computers
but work together as a single system. These components communicate over a
network using Java-based technologies. It involves breaking down an application
into smaller, independent parts that execute concurrently on different machines
and communicate to achieve a unified outcome.
Types of Architecture
Three Types Of
Architecture
Multi-tier
Architecture
Client-Sever
Architecture
Microservices
Architecture
1.Client-Server Architecture
• Description: The most fundamental model, where clients request services from
a central server.
• Java Example: A web application using Spring Boot (server-side) and a
browser (client-side) interacting via HTTP. The Spring Boot application handles
business logic and data access, serving dynamic content to the client.
2.Multi-tier Architecture(e.g.,
Three-tier)
• Description: Extends client-server by separating concerns into distinct layers:
presentation (UI), application logic (business rules), and data access (database).
• Java Example: An e-commerce system where:
Presentation Tier
Application Tier
Data Tier
3.Microservices Architecture
• Description: An application is composed of small, independent, and loosely
coupled services, each running in its own process and communicating via
lightweight mechanisms (e.g., REST, message queues).
• Java Example: An online banking system broken down into:
• AccountService: Manages user accounts and balances.
• TransactionService: Handles financial transactions.
• NotificationService: Sends email/SMS notifications.
Advantages in Java
• Platform-independent (thanks to JVM)
• Rich libraries for networking, security, and threading
• Scalable and modular
• Strong community and framework support
Working for Distributed System
Distributed
Application
Computer
Computer
Computer
Middleware
Network
THANK YOU

Remote Method Invocation-Distributed Application Architecture

  • 1.
    Remote Method Invocation- DistributedApplication Architecture Presented by, C.Dhivyasri I-M.Sc(Computer Science) Nadar Saraswathi College of Arts and Science
  • 2.
    Definition of RMI •Remote Method Invocation (RMI) is a Java-based technology that allows an object running in one Java Virtual Machine (JVM) to invoke methods on an object running in another JVM, typically on a different physical machine. • Remote Method Invocation (RMI) is a mechanism that enables the invocation of methods that reside on a remote object (i.e., an object located on another computer in a network) as if they were local to the calling program.
  • 3.
    Key Characteristics • DistributedComputing: Enables building distributed applications in Java. • Transparency: Remote objects can be used as if they were local objects. • Stubs and Skeletons: Uses stub (client-side proxy) and skeleton (server- side handler, in older RMI versions) to handle communication. • Serialization: Parameters and return values must be serializable for network transmission.
  • 4.
    Example: Java RMI- Hello Service We’ll create: • A Remote Interface • A Remote Implementation • A Server to register the remote object • A Client to invoke the remote method
  • 5.
  • 6.
    Important of RMIComponents • Client: Looks up remote objects and invokes their methods. • Server: Registers with the RMI registry and handles client method calls. • RMI Registry: Provides remote object lookup; can run on the server host or elsewhere, and may be a JNDI server. • Web Server: Hosts remote object classes for client download via HTTP.
  • 7.
    Definition of Distributed ApplicationArchitecture Distributed Application Architecture in Java refers to the design and development of Java applications where different components (such as user interfaces, business logic, and data storage) run on multiple networked computers but work together as a single system. These components communicate over a network using Java-based technologies. It involves breaking down an application into smaller, independent parts that execute concurrently on different machines and communicate to achieve a unified outcome.
  • 8.
    Types of Architecture ThreeTypes Of Architecture Multi-tier Architecture Client-Sever Architecture Microservices Architecture
  • 9.
    1.Client-Server Architecture • Description:The most fundamental model, where clients request services from a central server. • Java Example: A web application using Spring Boot (server-side) and a browser (client-side) interacting via HTTP. The Spring Boot application handles business logic and data access, serving dynamic content to the client.
  • 10.
    2.Multi-tier Architecture(e.g., Three-tier) • Description:Extends client-server by separating concerns into distinct layers: presentation (UI), application logic (business rules), and data access (database). • Java Example: An e-commerce system where: Presentation Tier Application Tier Data Tier
  • 11.
    3.Microservices Architecture • Description:An application is composed of small, independent, and loosely coupled services, each running in its own process and communicating via lightweight mechanisms (e.g., REST, message queues). • Java Example: An online banking system broken down into: • AccountService: Manages user accounts and balances. • TransactionService: Handles financial transactions. • NotificationService: Sends email/SMS notifications.
  • 12.
    Advantages in Java •Platform-independent (thanks to JVM) • Rich libraries for networking, security, and threading • Scalable and modular • Strong community and framework support
  • 13.
    Working for DistributedSystem Distributed Application Computer Computer Computer Middleware Network
  • 14.