转自:http://6221123.blog.51cto.com/6211123/1112619

这里讲述的是基于JDK1.5的RMI程序搭建,更简单的说是一个 HelloWorld RMI。

1. 这里是基于JDK1.5的,节省了繁琐的手工编译(生成桩和骨架)。不像1.4之前的RMI。

2. 这里是把客户端和服务器端的两个程序,分布在两个独立的程序里面,而不是同一个package下面。是真正的分布式。

3. 这里不过多阐述原理,这只是一个Hello World!!

好,以下是步骤:

1. 在Eclipse里面创建一个server 端的project。然后,创建一个接口,这个接口是你要向client端开放的方法定义。它叫做:UserManagerInterface,而且必须继承Remote接口。

  1. package dataserver.rmi.stub;
  2. import java.rmi.Remote;
  3. import java.rmi.RemoteException;
  4. import dataserver.rmi.bean.Account;
  5. public interface UserManagerInterface extends Remote{
  6. public String getUserName() throws RemoteException;
  7. public Account getAdminAccount() throws RemoteException;
  8. }

2. 为了证明RMI中,“面向对象”或者是“无缝传递JAVA Object”是何等简单,我们需要定义一个Account类,该类是一个Bean,必须实现implements Serializable序列化接口。这是一个可以在client和server传输的可序列化对象。

  1. package dataserver.rmi.bean;
  2. import java.io.Serializable;
  3. public class Account implements Serializable,Cloneable{
  4. /**
  5. *
  6. */
  7. private static final long serialVersionUID = -1858518369668584532L;
  8. private String username;
  9. private String password;
  10. public String getUsername() {
  11. return username;
  12. }
  13. public void setUsername(String username) {
  14. this.username = username;
  15. }
  16. public String getPassword() {
  17. return password;
  18. }
  19. public void setPassword(String password) {
  20. this.password = password;
  21. }
  22. }

3. 此时,需要实现你已经开放的接口:

  1. package dataserver.rmi;
  2. import java.rmi.RemoteException;
  3. import dataserver.rmi.bean.Account;
  4. import dataserver.rmi.stub.UserManagerInterface;
  5. public class UserManagerImpl implements UserManagerInterface {
  6. public UserManagerImpl() throws RemoteException {
  7. //super();
  8. // TODO Auto-generated constructor stub
  9. //UnicastRemoteObject.exportObject(this);
  10. }
  11. /**
  12. *
  13. */
  14. private static final long serialVersionUID = -3111492742628447261L;
  15. public String getUserName() throws RemoteException {
  16. // TODO Auto-generated method stub
  17. return "Tommy Lee";
  18. }
  19. public Account getAdminAccount() throws RemoteException {
  20. // TODO Auto-generated method stub
  21. Account account=new Account();
  22. account.setUsername("admin");
  23. account.setPassword("admin");
  24. return account;
  25. }
  26. }

4. 定义一个主程序入口,注册你已经实现的RMI接口,包括开放端口等。其实很简单:

把我们的接口名称,命名为“userManager”,方便client进行调用

  1. package dataserver.entry;
  2. import java.rmi.AlreadyBoundException;
  3. import java.rmi.RemoteException;
  4. import java.rmi.registry.LocateRegistry;
  5. import java.rmi.registry.Registry;
  6. import java.rmi.server.UnicastRemoteObject;
  7. import dataserver.rmi.UserManagerImpl;
  8. import dataserver.rmi.stub.UserManagerInterface;
  9. public class Entry {
  10. public static void main(String []args) throws AlreadyBoundException, RemoteException{
  11. UserManagerImpl userManager=new UserManagerImpl();
  12. UserManagerInterface userManagerI=(UserManagerInterface)UnicastRemoteObject.exportObject(userManager,0);
  13. // Bind the remote object's stub in the registry
  14. Registry registry = LocateRegistry.createRegistry(2001);
  15. registry.rebind("userManager", userManagerI);
  16. System.out.println("server is ready");
  17. }
  18. }

5. Server端的代码已经全部写完,但是还要把bean类(Account)和接口类(UserMangerInterface)打包成jar,以便可以在下面导入进client端的项目中。

项目--》右键--》导出--》jar--》选择bean和interface--》命名为RmiServerInterface.jar--》finish

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAbQAAAIjCAIAAADk3Xl3AAAgAElEQVR4nO2d+38UZZ7v66/Yl+e89sw5s7MrOxdZUemVKGd2XzvjjDPnzIxncABF0q7Ss86sQ5gRcWRAQSDBWxoU0MEERBGwBUQkXBUBCfeQQAIhnZB0buTSHZok3XaAbJ8fqqvqqXq+T1V1p/qaz/v1vKBT9Vyru96ppyr9faQwAAAADinbHQAAgFwEcgQAAALIEQAACDg5+txSArePLuJzS67SGqc64GxtAADgDHo51pS6VCfWlJbSdkxKZ2RmdmOByTHrw8l6BwAoEPRytHVmQY4mZH04We8AAAWCYVrtc0vcuVVT6tJNtJnTz7jLsEmb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HAEAgAByBAAAgv8PW4bSYrMZ4/wAAAAASUVORK5CYII=" alt="" style="padding: 0px; margin: 0px; vertical-align: top; width: 370px; height: 466px;" />

6.  开始创建client端的程序。新建一个project。创建完成后,把刚才jar包导入进client的项目中。

7.  导入我们的接口jar以后,可以开始编写一个client端的主程序,并调用server端的方法。

  1. package weiblog.rmi;
  2. import java.rmi.NotBoundException;
  3. import java.rmi.RemoteException;
  4. import java.rmi.registry.LocateRegistry;
  5. import java.rmi.registry.Registry;
  6. import dataserver.rmi.stub.UserManagerInterface;
  7. public class Entry2 {
  8. public static void main(String []args){
  9. try {
  10. Registry registry = LocateRegistry.getRegistry("localhost",2001);
  11. UserManagerInterface userManager = (UserManagerInterface) registry.lookup("userManager");
  12. System.out.println(""+userManager.getAdminAccount().getUsername()
  13. +userManager.getAdminAccount().getPassword());
  14. } catch (RemoteException e) {
  15. // TODO Auto-generated catch block
  16. e.printStackTrace();
  17. } catch (NotBoundException e) {
  18. // TODO Auto-generated catch block
  19. e.printStackTrace();
  20. }
  21. }
  22. }

8. 启动server端的主程序,然后启动client端的主程序。

server控制台打印:server is ready

client控制台打印:adminadmin

大功告成!!

RMI分布式议程服务学习的更多相关文章

  1. 一脸懵逼学习Zookeeper(动物园管理员)---》高度可靠的分布式协调服务

    1:Zookeeper是一个分布式协调服务:就是为用户的分布式应用程序提供协调服务 A.zookeeper是为别的分布式程序服务的 B.Zookeeper本身就是一个分布式程序(只要有半数以上节点存活 ...

  2. ElasticSearch 5学习(6)——分布式集群学习分享1

    在使用中我们把文档存入ElasticSearch,但是如果能够了解ElasticSearch内部是如何存储的,将会对我们学习ElasticSearch有很清晰的认识.本文中的所使用的ElasticSe ...

  3. 基于netty轻量的高性能分布式RPC服务框架forest<上篇>

    工作几年,用过不不少RPC框架,也算是读过一些RPC源码.之前也撸过几次RPC框架,但是不断的被自己否定,最近终于又撸了一个,希望能够不断迭代出自己喜欢的样子. 顺便也记录一下撸RPC的过程,一来作为 ...

  4. 分布式协调服务Zookeeper集群监控JMX和ZkWeb应用对比

    分布式协调服务Zookeeper集群监控JMX和ZkWeb应用对比 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. JMX是用来远程监控Java应用的框架,这个也可以用来监控其他的J ...

  5. 集群/分布式/微服务/SOA 转

    https://www.cnblogs.com/Java3y/p/9479410.html 二.集群/分布式/微服务/SOA是什么? 像我这种技术小白,看到这些词(集群/分布式/微服务/SOA)的时候 ...

  6. SpringCloud微服务学习笔记

    SpringCloud微服务学习笔记 项目地址: https://github.com/taoweidong/Micro-service-learning 单体架构(Monolithic架构) Mon ...

  7. 【须弥SUMERU】分布式安全服务编排实践

    一.概要 1.分布式安全服务编排概念 2.须弥(Sumeru)关键实现思路 3.应用场景 二.前言 在笔者看来,安全防御的本质之一是增加攻击者的攻击成本,尤其是时间成本.那么从防御的角度来说,如何尽早 ...

  8. 18家大厂Java面试题整理了350道(分布式+微服务+高并发)

    一.性能调优系列 1.Tomcat性能调优 JVM参数调优: -Xms 表示JVM初始化堆的大小, -Xmx表示JVM堆的最大值.这两个值的大小一般根据需要进行设置. 当应用程序需要的内存超出堆的最大 ...

  9. Spring Cloud微服务学习笔记

    Spring Cloud微服务学习笔记 SOA->Dubbo 微服务架构->Spring Cloud提供了一个一站式的微服务解决方案 第一部分 微服务架构 1 互联网应用架构发展 那些迫使 ...

随机推荐

  1. bzoj 2200: [Usaco2011 Jan]道路和航线【spfa】

    直接跑最短路就行了--还不用判负环 #include<iostream> #include<cstdio> #include<queue> using namesp ...

  2. bzoj 2100: [Usaco2010 Dec]Apple Delivery【spfa】

    洛谷数据好强啊,普通spfa开o2都过不了,要加双端队列优化 因为是双向边,所以dis(u,v)=dis(v,u),所以分别以pa1和pa2为起点spfa一遍,表示pb-->pa1-->p ...

  3. codevs1669(dfs)子集和目标值

    1692 子集和的目标值  时间限制: 1 s  空间限制: 128000 KB  题目等级 : 钻石 Diamond   题目描述 Description 给定n个整数in和目标值T,求某一非空子集 ...

  4. FPGA基础入门篇(四) 边沿检测电路

    FPGA基础入门篇(四)--边沿检测电路 一.边沿检测 边沿检测,就是检测输入信号,或者FPGA内部逻辑信号的跳变,即上升沿或者下降沿的检测.在检测到所需要的边沿后产生一个高电平的脉冲.这在FPGA电 ...

  5. jQuery——表单应用(3)

    HTML: <!--表单-多行文本框应用-滚动条高度变化--> <!DOCTYPE html> <html> <head> <meta chars ...

  6. 窗体基础WINFORM

    winform 1.窗体: 造窗体界面: 窗体设计界面: 窗体类名不能重复! 属性: acceptbutton:回车是默认点击按钮 cancelbutton:按esc按键式默认的按钮 backcolo ...

  7. SQL数据库基础————委托

    委托:也称为代理,事件也是一种委托:定义在类的最外面 1.定义委托关键字:delegate函数签名:签名和函数保持一致定义委托的时候要根据函数来定义public delegate int First( ...

  8. [ SPOJ RESTACK ] Restacking haybales

    \(\\\) Description 给出一个环,每个位置有一个初值 \(A_i\),有一个目标值 \(B_i\),保证 \(\sum A_i=\sum B_i\) 每个位置只能把值分给隔壁的,每次分 ...

  9. Android 知识Tips

    有一些Android很小的知识点,不值得单独写出来做为一篇博客.都在这个博客里面进行总结 1.ImageButton控件,中间图片的放置效果可以用scaleType来设置,如下: <ImageB ...

  10. cookie的应用——浏览记录

    实体类 package entity; public class Product { private String id; private String proName; private String ...