flex 与java通信出有关问题,头大

flex 与java通信出问题,头大
出现的错误
[FaultEvent fault=[RPC Fault faultString="Send failed" faultCode="Client.Error.MessageSend" faultDetail="Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url: 'http://localhost:8080/flexandjava/messagebroker/amf'"] messageId="91E6625B-047F-90B1-4739-AB33CE987D85" type="fault" bubbles=false cancelable=true eventPhase=2]

MXML代码
XML code

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" minWidth="955" minHeight="600"
    creationComplete="init();">
    <mx:Script>
        <![CDATA[
            import mx.controls.Alert;
            import mx.rpc.events.ResultEvent;
            import mx.rpc.events.FaultEvent;
            [Bindable]
            private var employeeList:Object;
            private function init():void
            {
                employeeServiceRO.getList();
            }
            private function resultHandler(event:ResultEvent):void
            {
                employeeList=event.result;
            }
            private function faultHandler(event:FaultEvent):void
            {
                Alert.show(event.toString(),'error');
            }
        ]]>
    </mx:Script>
    <mx:RemoteObject id="employeeServiceRO" destination="employeeServiceDest" result="resultHandler(event)" fault="faultHandler(event)"
         endpoint="/flexandjava/messagebroker/amf"/>
    <mx:DataGrid width="450" dataProvider="{employeeList}">
        <mx:columns>
            <mx:DataGridColumn dataField="Name" headerText="name"/>
            <mx:DataGridColumn dataField="Age" headerText="age"/>
            <mx:DataGridColumn dataField="Email" headerText="email"/>
        </mx:columns>
    </mx:DataGrid>
</mx:Application>



Java code
package com.sample;

import java.util.ArrayList;

public class EmployeeService {

    public ArrayList<Employee> getList() {
        ArrayList<Employee> tempList = new ArrayList<Employee>();

        for (int i = 1; i <= 30; i++) {
            tempList.add(new Employee("Smith" + i, 20 + i, "smith" + i
                    + "@test.com"));
        }
        return tempList;
    }
}


Java code
package com.sample;

public class Employee {
    private String name;
    private int age;
    private String email;

    public Employee(String name, int age, String email) {
        this.name = name;
        this.age = age;
        this.email = email;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

}


不知道是配置问题还是环境没配好?


------解决方案--------------------
单独在网页中打开“http://localhost:8080/flexandjava/messagebroker/amf” 可以看到一片空白那就是配置正确了,反之出错。
------解决方案--------------------
上面贴得代码没什么问题。
------解决方案--------------------
看一下你的配置!还有就是在java端输出打印一下!走到哪呢!