SlideShare une entreprise Scribd logo
1  sur  22
BHARATI VIDYAPEETH COLLEGE OF ENGINEERING,
SECTOR NO.7,C.B.D. NAVI MUMBAI-400614
A Report On
“STUDENT DATABASE HANDLING USING
RMI”
Under Guidance Of
Prof. SHILPA M. SATRE
Department of INFORMATION TECHNOLOGY
Submitted By
Department Of Information Technology Engineering(2016-17)
Roll No. Name of Students
41 Sonali Mali
42 Shraddha Mane
43 Amey Mhatre
44 Omkar Mhatre
Date Of Submission :-
BHARATI VIDYAPEETH COLLEGE OF ENGINEERING,
SECTOR NO.7,C.B.D. NAVI MUMBAI-400614
CERTIFICATE
This is to certify that the following students of third year Information Technology
department have successfully completed the report on "STUDENT DATABASE
HANDLING USING RMI” in partial fulfillment of the course Distributed system as
prescribed by the University Of Mumbai.
Roll No. Name of Students
41 Sonali Mali
42 Shraddha Mane
43 Amey Mhatre
44 Omkar Mhatre
Prof.S.M.Satre Prof. S.M. Patil Dr. M.Z. Shaikh
(Project Guide) (Head Of Department) (Principal)
BHARATI VIDYAPEETH COLLEGE OF ENGINEERING,
NAVI MUMBAI.
Vision:
The vision of our project is to study a client-server based application
using RMI.
Mission :
The mission of our project is to insert the record through interactiveforms
and easy to retrieve which store into database.
DECLARATION
I declare that final semester report entitled “ STUDENT DATABASE HANDLING USING
RMI” is my own work conducted under the supervision of the guide Mrs. Shilpa Satre from
Bharati Vidyapeeth College of Engineering.
Also I declare that following student also worked in this project:
1) Shraddha Mane
2) Sonali Mali
3) Amey Mhatre
4) Omkar Mhatre
Information Technology Department, Bharati Vidyapeeth Collage of Engineering.
Submitted To:
Department of Information Technology,
Bharati Vidyapeeth College of Engineering
Mumbai University, Kharghar.
State: Maharashtra.
ACKNOWLEDGEMENT
We express esteemed gratitude and sincere thanks to our worthy project
guide Prof. Shilpa Satre madam, our vocabulary is yet to find suitable words
benefiting to high standard of knowledge set by her and extreme sincerity and
affection with which she has regularly encourage us to put heart and soul in this
work.
We are much obliged to our honourable H.O.D Prof. S. M. Patil sir whose
support and co-operation was always helpful and encouraging.
We also convey great thanks to our honourable principal Dr.M. Z. Shaikh
sir. Our parents who always bear with us in every critical situation and provide
the support whenever required.
As we give expression to our love and appreciation our heart is fill. And
we in sincere appreciation of your valuable help. Please accept our respect and
gratitude.
ABSTRACT
Java RMI is a mechanism to allow the invocation of methods that reside
on different Java Virtual Machines (JVMs). The JVMs may be on different
machines or they could be on the same machine. In either case, the method runs
in a different address space than the calling process.
Java RMI is an object-oriented remote procedure call mechanism.
In this article a server-client application is described, which is realised
with an Java server and Java client using Java RMI. The application is about a
student record. The client can:
 insert a data: The client can add a record of student into database and
server stores this data into database.
 get a record: The client requests for a particular record. The server returns
a available data related to that student to the client.
 delete a record: The client sends a roll no to the server, which will delete
the corresponding record.
TABLE OF CONTENTS
1. Introduction.
2. Methodology.
1. Architecture.
2. How tobuild it.
3. ProposedMethodology.
1. Hardware and Software Requirement.
1.1 Hardware Requirements.
1.2 Software Requirements.
4. Result andAnalysis.
1. Performance Evaluation.
2. Graphical User Interface.
5. Future Work.
6. Conclusion.
7. References.
List of figures:
Figure No. Title Page NO.
1. Architecture of RMI.
2.
3.
INTRODUCTION
This project is very introductory, they only introduce the basic idea of RMI in Java
and present a very simple example. They do not look at the more interesting and
complicated ideas of generating and returning objects from the remote server, calling
back functions in the client or anything more than the basic calling of remote
functions. For more information you should refer to a longer tutorial or book.
The Java RMI is Java’s native scheme for creating and using remote objects.
 Java RMI provides the following elements:
1. Remote object implementations.
2. Client interfaces, or stubs, to remote objects.
3. A remote object registry for finding objects on the network.
4. A network protocol for communication between remote objects and their
client (this protocol is JRMP, i.e. Java Remote Method Protocol).
5. A facility for automatically creating (activating) remote objects on-demand.
Each of these elements (except the last one) has a Java interface defined for it in the
java.rmi package and its subclasses. RMI is part of the core Java API and has been enhanced
for JDK 1.2 (Java 2 platform) in recognition of the critical need for support for distributed
objects in distributed-application development.
 With RMI, you can get a reference to an object that “lives” in a remote process on
remote hosts and invoke methods on it as if it were a local object running within the
same Java virtual machine as your code.
 Each remote object implements a remote interface that specifies which of its methods
can be invoked by clients.
Prior to RMI, a distributed application involved socket programming, where a raw
communication channel was used to pass messages and data between two remote
processes. The programmer needed to define a low-level message protocol and data
transmission format between processes in the distributed application.
 With RMI, you can “export” an object as a remote object, so that other remote
processes/agents can access it directly as a Java object. RMI handles all the
underlying networking needed to make your remote method calls work.
 RMI is a Java-only distributed object scheme; the distributed objects in an RMI-based
distributed application have to be implemented in Java. This could be a problem when
interfacing with legacy applications.
 CORBA, on the other hand, is a language-independent distributed object scheme. It is
however, more complex to work with than RMI.
There are three entities involved in running a program that uses RMI:
client: this is the program that you write to access remote methods
server: this is the program that you write to implement the remote methods - clients connect
to the server and request that a method be executed. The remote methods to the client are
local methods to the server.
Object registry: this is a program that you use. The object registry runs on a known port
(1099 by default) A server, upon starting, registers its objects with a textual name with the
object registry. A client, before performing invoking a remote method, must first contact
the object registry to obtain access to the remote object.
METHODOLOGY
RMI Architecture
The RMI runtime architecture
There are three layers that comprise the basic remote-object communication facilities in RMI:
1. The stub/skeleton layer, which provides the interface that client and server application
objects use to interact with each other.
2. The remote reference layer, which is the middleware between the stub/skeleton layer
and the underlying transport protocol.
3. The transport protocol layer, which is the binary data protocol that sends remote
object requests over the wire.
In the figure, the server is the application that provides remotely accessible objects, while the
client is any remote application that communicates with these server objects.
Description of the architecture:
1. The client uses the client-side stub to make a request of the remote object. The
server object receives this request from a server-side object skeleton.
2. A client initiates an RMI invocation by calling a method on a stub object. The
stub maintains an internal reference to the remote object it represents and forwards
the method invocation request through the remote reference layer by marshaling
the method arguments into serialized form and asking the remote reference layer
to forward the method request and arguments to the appropriate remote object.
3. Marshaling involves converting local objects into portable form so that they can
be transmitted to a remote process. Each object (e.g. a String object, an array
object, or a user defined object) is checked as it is marshaled, to determine
whether it implements the java.rmi.Remote interface. If it does, its remote
reference is used as its marshaled data. If it isn’t a Remote object but is rather a
Serializable object, the object is serialized into bytes that are sent to the remote
host and reconstructed into a copy of the local object. If the object is neither
Remote nor Serializable, the stub throws a java.rmi.MarshalException back to the
client.
4. If the marshaling of method arguments succeeds, the client-side remote reference
layer receives the remote reference and marshaled arguments from the stub.
5. The remote reference layer converts the client request into low-level RMI
transport requests, i.e., into a single network-level request and sends it over the
wire to the sole remote object (since in Java 2 the communication style supported
is the point-to-point object references) that corresponds to the remote reference
passed along with the request.
6. On the server, the server-side remote reference layer receives the transport-level
request and converts it into a request for the server skeleton that matches the
referenced object.
7. The skeleton converts the remote request into the appropriate method call on the
actual server object. This involves unmarshaling the method arguments into the
server environment and passing them to the server object. Arguments sent as
remote references are converted into local stubs on the server, and arguments sent
as serialized objects are converted into local copies of the originals.
8. If the method calls generates a return value or an exception, the skeleton marshals
the object for transport back to the client and forwards it through the server
reference layer.
9. The result is sent back using the appropriate transport protocol (e.g. Socket API
using TCP/IP), where it passes through the client reference layer and stub, is
unmarshaled by the stub, and is finally handed back to the client thread that
invoked the remote method.
How to build it and run it
So far the concept has been introduced and example programs presented but it is important to
put these together in the correct order. The following is a brief summary:
• first write the interface and compile it:
javac RemoteAccount.java
• compile the object implementation:
javac RemoteAccountImpl.java
• now in order to generate stubs that are linked to to client code to enable it to call the object,
it is necessary to run the rmic program:
rmic RemoteAccountImpl
this generates RemoteAccountImp_Stub.class, this file must be copied to the directory on the
client machine where the client programs will be compiled.
• now compile the client program:
javac RemAccTest.java
• everything should be compiled, now start the rmiregistry program on the server machine:
rmiregistry
• now start the remote object server program:
java RemoteAccountImpl 1000
note that this one needs a command-line argument giving the initial balance in the account,
• now run the client program and it should work (?):
java RemAccTest plink.feis.herts.ac.uk
this program needs a command-line argument that is the name of the computer on which the
server program is running.
Later versions of Java don’t need the program rmic to be run explicitly. Also earlier versions
still provide for the automatic downloading of the stub files from the server to the client.
However I have spelt out each step to ensure that it will work under any circumstances and
because, although a bit longer, it is probably simpler.
PROPOSED METHODLOGY
The project is about to handle all the information of the student regarding their
personal information. Also it manages resources which were managed and handled by
manpower previously. The main purpose of the project is to integrate distinct sections of the
organization into consistent manner so that complex functions can be handled smoothly by
any technical or non-technical persons.
3. HARDWARE AND SOFTWARE REQUIREMENTS
The following are minimum hardware and requirements that should be present to run the
project successfully.
Table 3.1 Tools and Technology
Development technologies SQL server, visual studio
Development tools SQL server, visual studio
Database SQL
Operating system Windows XP Profession Edition, Windows Vista
Enterprise Edition
Hardware P-IV 2.4, 1 GB RAM, 80 GB HDD
 Hardware Requirements
Table 3.2 Hardware Requirement
Client Configuration
Pentium IV, 750 MHz, 20GB HDD
Operating System: Windows XP/2000 onwords
RAM: 256 MB minimum
400MB Minimum Free Space on Drive
Server Configuration
Operating System: Windows XP onwords
RAM: 512MB Minimum
40GB Minimum Free Space on Drive
750MHz
 Software Requirements
Table 3.3 Software Requirement
System Software
JDK v1.8.0
Eclipse v4.4
RESULTS
Performance evaluation:
Graphical User Interface:
FUTURE WORK

CONCLUSION
RMI provides a solid platform for truly object oriented distributed computing. You
can use RMI to connect to Java components or to existing components written in other
languages. As Java proves itself in your environment, you can expand your Java use and
get all the benefits-no porting, low maintenance costs, and a safe, secure environment.
RMI gives you a platform to expand Java into any part your system in an incremental
fashion, adding new Java servers and clients when it makes sense. As you add Java, its
full benefits flow through all the Java in your system. RMI makes this easy, secure, and
powerful.
REFERENCES
 Wikipedia
 http://www.corba.org
 www.slideshare.net

Contenu connexe

Tendances

Chapter 2 - Network Models
Chapter 2 - Network ModelsChapter 2 - Network Models
Chapter 2 - Network Models
Wayne Jones Jnr
 
Corba introduction and simple example
Corba introduction and simple example Corba introduction and simple example
Corba introduction and simple example
Alexia Wang
 
Distributed document based system
Distributed document based systemDistributed document based system
Distributed document based system
Chetan Selukar
 
Internetworking
InternetworkingInternetworking
Internetworking
Raghu nath
 
network monitoring system ppt
network monitoring system pptnetwork monitoring system ppt
network monitoring system ppt
ashutosh rai
 

Tendances (20)

Deductive databases
Deductive databasesDeductive databases
Deductive databases
 
Java RMI
Java RMIJava RMI
Java RMI
 
Remote Method Invocation (RMI)
Remote Method Invocation (RMI)Remote Method Invocation (RMI)
Remote Method Invocation (RMI)
 
Database backup and recovery
Database backup and recoveryDatabase backup and recovery
Database backup and recovery
 
Database recovery
Database recoveryDatabase recovery
Database recovery
 
Tcp/ip
Tcp/ipTcp/ip
Tcp/ip
 
Coda file system
Coda file systemCoda file system
Coda file system
 
Chapter 2 - Network Models
Chapter 2 - Network ModelsChapter 2 - Network Models
Chapter 2 - Network Models
 
Corba introduction and simple example
Corba introduction and simple example Corba introduction and simple example
Corba introduction and simple example
 
open system interconnection
open system interconnectionopen system interconnection
open system interconnection
 
Distributed document based system
Distributed document based systemDistributed document based system
Distributed document based system
 
Internetworking
InternetworkingInternetworking
Internetworking
 
File Transfer Protocol
File Transfer ProtocolFile Transfer Protocol
File Transfer Protocol
 
Unicast multicast & broadcast
Unicast multicast & broadcastUnicast multicast & broadcast
Unicast multicast & broadcast
 
RPC: Remote procedure call
RPC: Remote procedure callRPC: Remote procedure call
RPC: Remote procedure call
 
Java rmi
Java rmiJava rmi
Java rmi
 
Distributed database
Distributed databaseDistributed database
Distributed database
 
network monitoring system ppt
network monitoring system pptnetwork monitoring system ppt
network monitoring system ppt
 
Multiprotocol label switching (mpls) - Networkshop44
Multiprotocol label switching (mpls)  - Networkshop44Multiprotocol label switching (mpls)  - Networkshop44
Multiprotocol label switching (mpls) - Networkshop44
 
Multimedia Database
Multimedia Database Multimedia Database
Multimedia Database
 

Similaire à Report on mini project(Student database handling using RMI)

Similaire à Report on mini project(Student database handling using RMI) (20)

Remote method invocation
Remote method invocationRemote method invocation
Remote method invocation
 
Module 3 remote method invocation-2
Module 3   remote method  invocation-2Module 3   remote method  invocation-2
Module 3 remote method invocation-2
 
DS R16 - UNIT-3.pdf
DS R16 - UNIT-3.pdfDS R16 - UNIT-3.pdf
DS R16 - UNIT-3.pdf
 
Remote Method Innovation (RMI) In JAVA
Remote Method Innovation (RMI) In JAVARemote Method Innovation (RMI) In JAVA
Remote Method Innovation (RMI) In JAVA
 
Remote Method Invocation
Remote Method InvocationRemote Method Invocation
Remote Method Invocation
 
Distributed Objects and Remote Invocation
Distributed Objects and Remote InvocationDistributed Objects and Remote Invocation
Distributed Objects and Remote Invocation
 
005281271.pdf
005281271.pdf005281271.pdf
005281271.pdf
 
RMI (Remote Method Invocation)
RMI (Remote Method Invocation)RMI (Remote Method Invocation)
RMI (Remote Method Invocation)
 
Oracle docs rmi applications
Oracle docs rmi applicationsOracle docs rmi applications
Oracle docs rmi applications
 
Remote method invocatiom
Remote method invocatiomRemote method invocatiom
Remote method invocatiom
 
Javarmi 130925082348-phpapp01
Javarmi 130925082348-phpapp01Javarmi 130925082348-phpapp01
Javarmi 130925082348-phpapp01
 
Java rmi
Java rmiJava rmi
Java rmi
 
Remote Method Invocation in JAVA
Remote Method Invocation in JAVARemote Method Invocation in JAVA
Remote Method Invocation in JAVA
 
Java RMI Detailed Tutorial
Java RMI Detailed TutorialJava RMI Detailed Tutorial
Java RMI Detailed Tutorial
 
Java rmi tutorial
Java rmi tutorialJava rmi tutorial
Java rmi tutorial
 
Java RMI(Remote Method Invocation)
Java RMI(Remote Method Invocation)Java RMI(Remote Method Invocation)
Java RMI(Remote Method Invocation)
 
Java rmi
Java rmiJava rmi
Java rmi
 
Rmi
RmiRmi
Rmi
 
Remote method invocation
Remote method invocationRemote method invocation
Remote method invocation
 
009693652.pdf
009693652.pdf009693652.pdf
009693652.pdf
 

Plus de shraddha mane

Plus de shraddha mane (16)

Software project management
Software project managementSoftware project management
Software project management
 
Road Accident Alert System
Road Accident Alert SystemRoad Accident Alert System
Road Accident Alert System
 
Dhrupal Installation steps
Dhrupal Installation stepsDhrupal Installation steps
Dhrupal Installation steps
 
Dmbi project doc2
Dmbi project doc2Dmbi project doc2
Dmbi project doc2
 
Dmbi project doc
Dmbi project docDmbi project doc
Dmbi project doc
 
Rural issues and development
Rural issues and developmentRural issues and development
Rural issues and development
 
Clickstream Mining visualization for Ecommerce
Clickstream Mining visualization for EcommerceClickstream Mining visualization for Ecommerce
Clickstream Mining visualization for Ecommerce
 
Business intelligence
Business intelligenceBusiness intelligence
Business intelligence
 
IP security
IP securityIP security
IP security
 
Rural issues in india
Rural issues in indiaRural issues in india
Rural issues in india
 
Face recognition system
Face recognition systemFace recognition system
Face recognition system
 
Data Mining Technology and its application in CRM of commercial banks
Data Mining Technology and its application in CRM of commercial banksData Mining Technology and its application in CRM of commercial banks
Data Mining Technology and its application in CRM of commercial banks
 
Distribution transparency and Distributed transaction
Distribution transparency and Distributed transactionDistribution transparency and Distributed transaction
Distribution transparency and Distributed transaction
 
RPC communication,thread and processes
RPC communication,thread and processesRPC communication,thread and processes
RPC communication,thread and processes
 
Distributed system
Distributed systemDistributed system
Distributed system
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network security
 

Dernier

1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
AldoGarca30
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
jaanualu31
 
Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
Epec Engineered Technologies
 

Dernier (20)

Wadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptxWadi Rum luxhotel lodge Analysis case study.pptx
Wadi Rum luxhotel lodge Analysis case study.pptx
 
1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
1_Introduction + EAM Vocabulary + how to navigate in EAM.pdf
 
A Study of Urban Area Plan for Pabna Municipality
A Study of Urban Area Plan for Pabna MunicipalityA Study of Urban Area Plan for Pabna Municipality
A Study of Urban Area Plan for Pabna Municipality
 
Unleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leapUnleashing the Power of the SORA AI lastest leap
Unleashing the Power of the SORA AI lastest leap
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - V
 
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced LoadsFEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
 
Online electricity billing project report..pdf
Online electricity billing project report..pdfOnline electricity billing project report..pdf
Online electricity billing project report..pdf
 
Hostel management system project report..pdf
Hostel management system project report..pdfHostel management system project report..pdf
Hostel management system project report..pdf
 
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills KuwaitKuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
Kuwait City MTP kit ((+919101817206)) Buy Abortion Pills Kuwait
 
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptxS1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
S1S2 B.Arch MGU - HOA1&2 Module 3 -Temple Architecture of Kerala.pptx
 
Standard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power PlayStandard vs Custom Battery Packs - Decoding the Power Play
Standard vs Custom Battery Packs - Decoding the Power Play
 
School management system project Report.pdf
School management system project Report.pdfSchool management system project Report.pdf
School management system project Report.pdf
 
data_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfdata_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdf
 
Thermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.pptThermal Engineering -unit - III & IV.ppt
Thermal Engineering -unit - III & IV.ppt
 
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
COST-EFFETIVE  and Energy Efficient BUILDINGS ptxCOST-EFFETIVE  and Energy Efficient BUILDINGS ptx
COST-EFFETIVE and Energy Efficient BUILDINGS ptx
 
Engineering Drawing focus on projection of planes
Engineering Drawing focus on projection of planesEngineering Drawing focus on projection of planes
Engineering Drawing focus on projection of planes
 
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
Bhubaneswar🌹Call Girls Bhubaneswar ❤Komal 9777949614 💟 Full Trusted CALL GIRL...
 
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLEGEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
GEAR TRAIN- BASIC CONCEPTS AND WORKING PRINCIPLE
 
PE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and propertiesPE 459 LECTURE 2- natural gas basic concepts and properties
PE 459 LECTURE 2- natural gas basic concepts and properties
 
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptxHOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
HOA1&2 - Module 3 - PREHISTORCI ARCHITECTURE OF KERALA.pptx
 

Report on mini project(Student database handling using RMI)

  • 1. BHARATI VIDYAPEETH COLLEGE OF ENGINEERING, SECTOR NO.7,C.B.D. NAVI MUMBAI-400614 A Report On “STUDENT DATABASE HANDLING USING RMI” Under Guidance Of Prof. SHILPA M. SATRE Department of INFORMATION TECHNOLOGY Submitted By Department Of Information Technology Engineering(2016-17) Roll No. Name of Students 41 Sonali Mali 42 Shraddha Mane 43 Amey Mhatre 44 Omkar Mhatre Date Of Submission :-
  • 2. BHARATI VIDYAPEETH COLLEGE OF ENGINEERING, SECTOR NO.7,C.B.D. NAVI MUMBAI-400614 CERTIFICATE This is to certify that the following students of third year Information Technology department have successfully completed the report on "STUDENT DATABASE HANDLING USING RMI” in partial fulfillment of the course Distributed system as prescribed by the University Of Mumbai. Roll No. Name of Students 41 Sonali Mali 42 Shraddha Mane 43 Amey Mhatre 44 Omkar Mhatre Prof.S.M.Satre Prof. S.M. Patil Dr. M.Z. Shaikh (Project Guide) (Head Of Department) (Principal)
  • 3. BHARATI VIDYAPEETH COLLEGE OF ENGINEERING, NAVI MUMBAI. Vision: The vision of our project is to study a client-server based application using RMI. Mission : The mission of our project is to insert the record through interactiveforms and easy to retrieve which store into database.
  • 4. DECLARATION I declare that final semester report entitled “ STUDENT DATABASE HANDLING USING RMI” is my own work conducted under the supervision of the guide Mrs. Shilpa Satre from Bharati Vidyapeeth College of Engineering. Also I declare that following student also worked in this project: 1) Shraddha Mane 2) Sonali Mali 3) Amey Mhatre 4) Omkar Mhatre Information Technology Department, Bharati Vidyapeeth Collage of Engineering. Submitted To: Department of Information Technology, Bharati Vidyapeeth College of Engineering Mumbai University, Kharghar. State: Maharashtra.
  • 5. ACKNOWLEDGEMENT We express esteemed gratitude and sincere thanks to our worthy project guide Prof. Shilpa Satre madam, our vocabulary is yet to find suitable words benefiting to high standard of knowledge set by her and extreme sincerity and affection with which she has regularly encourage us to put heart and soul in this work. We are much obliged to our honourable H.O.D Prof. S. M. Patil sir whose support and co-operation was always helpful and encouraging. We also convey great thanks to our honourable principal Dr.M. Z. Shaikh sir. Our parents who always bear with us in every critical situation and provide the support whenever required. As we give expression to our love and appreciation our heart is fill. And we in sincere appreciation of your valuable help. Please accept our respect and gratitude.
  • 6. ABSTRACT Java RMI is a mechanism to allow the invocation of methods that reside on different Java Virtual Machines (JVMs). The JVMs may be on different machines or they could be on the same machine. In either case, the method runs in a different address space than the calling process. Java RMI is an object-oriented remote procedure call mechanism. In this article a server-client application is described, which is realised with an Java server and Java client using Java RMI. The application is about a student record. The client can:  insert a data: The client can add a record of student into database and server stores this data into database.  get a record: The client requests for a particular record. The server returns a available data related to that student to the client.  delete a record: The client sends a roll no to the server, which will delete the corresponding record.
  • 7. TABLE OF CONTENTS 1. Introduction. 2. Methodology. 1. Architecture. 2. How tobuild it. 3. ProposedMethodology. 1. Hardware and Software Requirement. 1.1 Hardware Requirements. 1.2 Software Requirements. 4. Result andAnalysis. 1. Performance Evaluation. 2. Graphical User Interface. 5. Future Work. 6. Conclusion. 7. References. List of figures: Figure No. Title Page NO. 1. Architecture of RMI. 2. 3.
  • 8. INTRODUCTION This project is very introductory, they only introduce the basic idea of RMI in Java and present a very simple example. They do not look at the more interesting and complicated ideas of generating and returning objects from the remote server, calling back functions in the client or anything more than the basic calling of remote functions. For more information you should refer to a longer tutorial or book. The Java RMI is Java’s native scheme for creating and using remote objects.  Java RMI provides the following elements: 1. Remote object implementations. 2. Client interfaces, or stubs, to remote objects. 3. A remote object registry for finding objects on the network. 4. A network protocol for communication between remote objects and their client (this protocol is JRMP, i.e. Java Remote Method Protocol). 5. A facility for automatically creating (activating) remote objects on-demand. Each of these elements (except the last one) has a Java interface defined for it in the java.rmi package and its subclasses. RMI is part of the core Java API and has been enhanced for JDK 1.2 (Java 2 platform) in recognition of the critical need for support for distributed objects in distributed-application development.  With RMI, you can get a reference to an object that “lives” in a remote process on remote hosts and invoke methods on it as if it were a local object running within the same Java virtual machine as your code.  Each remote object implements a remote interface that specifies which of its methods can be invoked by clients.
  • 9. Prior to RMI, a distributed application involved socket programming, where a raw communication channel was used to pass messages and data between two remote processes. The programmer needed to define a low-level message protocol and data transmission format between processes in the distributed application.  With RMI, you can “export” an object as a remote object, so that other remote processes/agents can access it directly as a Java object. RMI handles all the underlying networking needed to make your remote method calls work.  RMI is a Java-only distributed object scheme; the distributed objects in an RMI-based distributed application have to be implemented in Java. This could be a problem when interfacing with legacy applications.  CORBA, on the other hand, is a language-independent distributed object scheme. It is however, more complex to work with than RMI. There are three entities involved in running a program that uses RMI: client: this is the program that you write to access remote methods server: this is the program that you write to implement the remote methods - clients connect to the server and request that a method be executed. The remote methods to the client are local methods to the server. Object registry: this is a program that you use. The object registry runs on a known port (1099 by default) A server, upon starting, registers its objects with a textual name with the object registry. A client, before performing invoking a remote method, must first contact the object registry to obtain access to the remote object.
  • 10. METHODOLOGY RMI Architecture The RMI runtime architecture There are three layers that comprise the basic remote-object communication facilities in RMI: 1. The stub/skeleton layer, which provides the interface that client and server application objects use to interact with each other. 2. The remote reference layer, which is the middleware between the stub/skeleton layer and the underlying transport protocol. 3. The transport protocol layer, which is the binary data protocol that sends remote object requests over the wire. In the figure, the server is the application that provides remotely accessible objects, while the client is any remote application that communicates with these server objects. Description of the architecture: 1. The client uses the client-side stub to make a request of the remote object. The server object receives this request from a server-side object skeleton. 2. A client initiates an RMI invocation by calling a method on a stub object. The stub maintains an internal reference to the remote object it represents and forwards the method invocation request through the remote reference layer by marshaling the method arguments into serialized form and asking the remote reference layer to forward the method request and arguments to the appropriate remote object.
  • 11. 3. Marshaling involves converting local objects into portable form so that they can be transmitted to a remote process. Each object (e.g. a String object, an array object, or a user defined object) is checked as it is marshaled, to determine whether it implements the java.rmi.Remote interface. If it does, its remote reference is used as its marshaled data. If it isn’t a Remote object but is rather a Serializable object, the object is serialized into bytes that are sent to the remote host and reconstructed into a copy of the local object. If the object is neither Remote nor Serializable, the stub throws a java.rmi.MarshalException back to the client. 4. If the marshaling of method arguments succeeds, the client-side remote reference layer receives the remote reference and marshaled arguments from the stub. 5. The remote reference layer converts the client request into low-level RMI transport requests, i.e., into a single network-level request and sends it over the wire to the sole remote object (since in Java 2 the communication style supported is the point-to-point object references) that corresponds to the remote reference passed along with the request. 6. On the server, the server-side remote reference layer receives the transport-level request and converts it into a request for the server skeleton that matches the referenced object. 7. The skeleton converts the remote request into the appropriate method call on the actual server object. This involves unmarshaling the method arguments into the server environment and passing them to the server object. Arguments sent as remote references are converted into local stubs on the server, and arguments sent as serialized objects are converted into local copies of the originals. 8. If the method calls generates a return value or an exception, the skeleton marshals the object for transport back to the client and forwards it through the server reference layer. 9. The result is sent back using the appropriate transport protocol (e.g. Socket API using TCP/IP), where it passes through the client reference layer and stub, is unmarshaled by the stub, and is finally handed back to the client thread that invoked the remote method.
  • 12. How to build it and run it So far the concept has been introduced and example programs presented but it is important to put these together in the correct order. The following is a brief summary: • first write the interface and compile it: javac RemoteAccount.java • compile the object implementation: javac RemoteAccountImpl.java • now in order to generate stubs that are linked to to client code to enable it to call the object, it is necessary to run the rmic program: rmic RemoteAccountImpl this generates RemoteAccountImp_Stub.class, this file must be copied to the directory on the client machine where the client programs will be compiled. • now compile the client program: javac RemAccTest.java • everything should be compiled, now start the rmiregistry program on the server machine: rmiregistry • now start the remote object server program: java RemoteAccountImpl 1000 note that this one needs a command-line argument giving the initial balance in the account, • now run the client program and it should work (?): java RemAccTest plink.feis.herts.ac.uk this program needs a command-line argument that is the name of the computer on which the server program is running. Later versions of Java don’t need the program rmic to be run explicitly. Also earlier versions still provide for the automatic downloading of the stub files from the server to the client. However I have spelt out each step to ensure that it will work under any circumstances and because, although a bit longer, it is probably simpler.
  • 13. PROPOSED METHODLOGY The project is about to handle all the information of the student regarding their personal information. Also it manages resources which were managed and handled by manpower previously. The main purpose of the project is to integrate distinct sections of the organization into consistent manner so that complex functions can be handled smoothly by any technical or non-technical persons. 3. HARDWARE AND SOFTWARE REQUIREMENTS The following are minimum hardware and requirements that should be present to run the project successfully. Table 3.1 Tools and Technology Development technologies SQL server, visual studio Development tools SQL server, visual studio Database SQL Operating system Windows XP Profession Edition, Windows Vista Enterprise Edition Hardware P-IV 2.4, 1 GB RAM, 80 GB HDD  Hardware Requirements Table 3.2 Hardware Requirement Client Configuration Pentium IV, 750 MHz, 20GB HDD Operating System: Windows XP/2000 onwords RAM: 256 MB minimum 400MB Minimum Free Space on Drive Server Configuration Operating System: Windows XP onwords RAM: 512MB Minimum 40GB Minimum Free Space on Drive 750MHz
  • 14.  Software Requirements Table 3.3 Software Requirement System Software JDK v1.8.0 Eclipse v4.4
  • 16.
  • 17.
  • 19.
  • 21. CONCLUSION RMI provides a solid platform for truly object oriented distributed computing. You can use RMI to connect to Java components or to existing components written in other languages. As Java proves itself in your environment, you can expand your Java use and get all the benefits-no porting, low maintenance costs, and a safe, secure environment. RMI gives you a platform to expand Java into any part your system in an incremental fashion, adding new Java servers and clients when it makes sense. As you add Java, its full benefits flow through all the Java in your system. RMI makes this easy, secure, and powerful.