Ds Part C Sanjana
Ds Part C Sanjana
3. Common Facilities
These are pre-made, shared services that many apps can use.
Example: Printing service, sending email, file handling, etc.
Instead of writing these again and again, CORBA gives ready-made tools
here.
These also connect to the ORB to share their functions.
4. Domain Interface
These are services made for specific industries or domains.
Example: A hospital system may need patient records or appointment
services. A bank may need a transaction or account check service.
These are custom services that fit a certain field.
5. Object Interface
This is the actual interface of the object (like a class with functions) that
defines what the object can do.
It’s written in IDL (Interface Definition Language) so that any language
(Java, C++, Python) can understand and use it.
The ORB uses this to find and call the right function on the right object.
Components of IDL
1. Module
A container used to group related interfaces together.
Similar to packages in Java or namespaces in C++.
Helps avoid name conflicts.
2. Interface
Defines the object and the services (methods) it offers.
It’s like a class that only has function declarations, not the logic.
3. Operations (Methods)
These are the functions or services that the object provides.
Defined inside the interface.
Can have input (in), output (out), or inout parameters.
4. Parameters (in, out, inout)
Define how data flows through the method.
5. Data Types
IDL supports both:
Basic types: short, long, float, double, char, boolean, string
Complex types (custom-made):
o struct
o enum
o typedef
o sequence
6. Exceptions
You can define custom error types.
Used for error handling
7. Attributes
Like variables or properties.
You can define them with get/set automatically.
float getBalance();
};
Explanation:
IDL Compilation
After writing the interface in IDL, it is compiled using an
IDL compiler.
Ans….
The CORBA Naming Service helps different programs in a distributed system
find each other by name, just like how we use domain names (like google.com)
instead of IP addresses.
The Naming Service acts like a telephone directory or contact list:
Each service or object has a name.
The Naming Service maps that name to the actual location of the object.
1. Resource Sharing
Users can access hardware, software, or data from anywhere in the
system.
You can use files, printers, or databases from other computers in the
network.
No need to have everything on your own system.
It saves cost and improves efficiency.
2. Openness
The system supports extensions and improvements, and its components
can be openly developed and shared.
Anyone can add or upgrade parts of the system easily.
3. Concurrency
Multiple users can perform tasks at the same time, even from different
locations, each with their own system.
Improves performance and productivity
4. Scalability
The system can grow by adding more machines or users without losing
performance.
Still works fast and smoothly even at a large scale.
5. Fault Tolerance
Even if hardware or software fails, the system keeps running properly with
minimal impact.
The system can recover from errors automatically.
It ensures the system is always reliable.
6. Transparency
The system hides complexity from users, making it appear as a single,
unified system.
All resources appear as if they’re from one system.
Makes the system easier and safer to use.
3. Scalability
Easy to add more machines or users without redesigning the entire
system.
Suitable for growing businesses or apps with increasing users.
Can scale horizontally (add more nodes) or vertically (upgrade nodes).
4. Fault Tolerance
Even if one part fails, the rest of the system keeps working smoothly.
Backup systems can take over automatically.
Minimizes downtime and ensures high availability.
5. Cost-Effective
Uses low-cost computers connected together instead of buying one
powerful machine.
Saves money on hardware and energy.
6. Location Independence
Users can access resources and services from anywhere in the system.
Helpful in systems like cloud computing and online banking.
Supports remote work and global access.
7. Concurrent Access
Multiple users can access the system at the same time without conflict.
Ensures consistency when many users read/write data.
Essential for collaborative tools like Google Docs.
2. Complexity
o Distributed systems are complicated to build and manage.
o Developers have to handle things like communication, failure, and
data splitting.
3. Security
o More nodes mean more chances for attacks like hacking or data
leaks.
o Needs strong encryption, passwords, and access controls.
4. Synchronization
o Keeping actions and data in sync across different computers is tough.
o Example: Making sure two users don’t book the same seat in a ticket
system.
5. Resource Management
o Hard to efficiently manage CPU, memory, or servers across the
network.
o Needs good load balancing and scheduling.
📂 Types of RPC:
🔁 1. Callback RPC
Both client and server can act as each other.
Server can call back a function in the client.
Used in interactive or event-driven applications.
Handles deadlocks that may occur during callbacks.
Allows peer-to-peer interaction between processes.
📣 2. Broadcast RPC
The client’s request is sent to all servers in the network.
All servers that can handle the request respond.
Reduces the need for the client to contact each server individually.
Useful when the response can come from any server, not just one.
Can reduce load on the network if used properly.
📦 3. Batch-mode RPC
Multiple RPC requests are collected on the client side.
They are sent together in one batch to the server.
Reduces network overhead (fewer messages).