发表于: 2017-11-29 23:23:22

1 617


今天完成的事情:

将原有的Spring RMI更改为Tuscany的RMI,WEB端更改为Tuscany的调用方式,

部署两台Service,在WEB中随机访问任意一台Service。

这些本地都跑通了..贴上部分代码

public class RmiServer {
public static void main(String[] args) throws Exception {
Node node = NodeFactory.newInstance().createNode("Calculator.composite");
           node.start();
           Object lock = new Object();
           synchronized (lock){
lock.wait();
           }

<component name="ServiceComponent">
   <implementation.spring location="applicationContext.xml" />
   <service name="StudentService">
       <tuscany:binding.rmi uri="rmi://127.0.0.1:8002/StudentService2"/>
   </service>
</component>
<sca:service name="StudentService" target="studentServiceImpl" />

注意一定要在接口家注解

@Remotable



明天计划:

解决最后一个BUG提交任务9.


遇到的困难:

主要的问题,一个下面这个报错,有注解却报错 注解丢失,,是因为jar包缺失的问题.

第二个问题.卡了几个小时的问题..打jar包之后本地可以运行,也可以跑通,服务器上面没有报错.Service报错日志没有,,web报错日志也没有,都可以启动,却无法跑通.报错503..

判断首先不是war包和jar包的问题,因为本地跑的通 ,,服务器也可以运行,然后只剩数据传输了,,,,阿里端口也已经打开.


收获:

学习如何在spring配置Tuscany


任务进度:任务9步骤4

任务开始时间:2017-11-28

预计demo时间:2017-11-30

是否有延期风险:暂无

禅道:http://task.ptteng.com/zentao/task-view-14243.html




返回列表 返回列表
评论

    分享到