Examples of PhysicalAddress


Examples of org.jgroups.PhysicalAddress

    protected Object handleDownEvent(Event evt) {
        Object ret=super.handleDownEvent(evt);
        if(evt.getType() == Event.VIEW_CHANGE) {
            Set<Address> physical_mbrs=new HashSet<Address>();
            for(Address addr: members) {
                PhysicalAddress physical_addr=getPhysicalAddressFromCache(addr);
                if(physical_addr != null)
                    physical_mbrs.add(physical_addr);
            }
            retainAll(physical_mbrs); // remove all connections which are not members
        }
View Full Code Here

Examples of org.jgroups.PhysicalAddress

        return true;
    }

    public void sendGetMembersRequest(String cluster_name, Promise promise, boolean return_views_only) throws Exception{
        //  Mcast GET_MBRS_REQ message
        PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
        PingData data=new PingData(local_addr, null, false, UUID.get(local_addr), physical_addrs);
        PingHeader hdr=new PingHeader(PingHeader.GET_MBRS_REQ, data, cluster_name);
        hdr.return_view_only=return_views_only;
        Message msg=new Message(null)// mcast msg
View Full Code Here

Examples of org.jgroups.PhysicalAddress

    }


    protected void connect(String group, Address logical_addr) {
        String logical_name=org.jgroups.util.UUID.get(logical_addr);
        PhysicalAddress physical_addr=(PhysicalAddress)down_prot.down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        List<PhysicalAddress> physical_addrs=physical_addr != null? new ArrayList<PhysicalAddress>() : null;
        if(physical_addr != null)
            physical_addrs.add(physical_addr);

        int num_faulty_conns=0;
View Full Code Here

Examples of org.jgroups.PhysicalAddress



    public void sendGetMembersRequest(String cluster_name, Promise promise, boolean return_views_only) throws Exception{
        List<PingData> existing_mbrs=readAll(cluster_name);
        PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
        PingData data=new PingData(local_addr, null, false, UUID.get(local_addr), physical_addrs);

        // If we don't find any files, return immediately
        if(existing_mbrs.isEmpty()) {
View Full Code Here

Examples of org.jgroups.PhysicalAddress

    protected Object handleDownEvent(Event evt) {
        Object ret=super.handleDownEvent(evt);
        if(evt.getType() == Event.VIEW_CHANGE) {
            Set<Address> physical_mbrs=new HashSet<Address>();
            for(Address addr: members) {
                PhysicalAddress physical_addr=getPhysicalAddressFromCache(addr);
                if(physical_addr != null)
                    physical_mbrs.add(physical_addr);
            }
            retainAll(physical_mbrs); // remove all connections from the ConnectionTable which are not members
        }
View Full Code Here

Examples of org.jgroups.PhysicalAddress



    public void sendGetMembersRequest(String cluster_name, Promise promise, boolean return_views_only) throws Exception{
        List<PingData> existing_mbrs=readAll(cluster_name);
        PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
        PingData data=new PingData(local_addr, null, false, UUID.get(local_addr), physical_addrs);

        // If we don't find any files, return immediately
        if(existing_mbrs.isEmpty()) {
View Full Code Here

Examples of org.jgroups.PhysicalAddress



    public void sendGetMembersRequest(String cluster_name, Promise promise) throws Exception{
        List<PingData> existing_mbrs=readAll(cluster_name);
        PhysicalAddress physical_addr=(PhysicalAddress)down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        List<PhysicalAddress> physical_addrs=Arrays.asList(physical_addr);
        PingData data=new PingData(local_addr, null, false, UUID.get(local_addr), physical_addrs);

        // If we don't find any files, return immediately
        if(existing_mbrs.isEmpty()) {
View Full Code Here

Examples of org.jgroups.PhysicalAddress

        if(evt.getType() == Event.VIEW_CHANGE) {
            suspected_mbrs.clear();

            Set<Address> physical_mbrs=new HashSet<Address>();
            for(Address addr: members) {
                PhysicalAddress physical_addr=getPhysicalAddressFromCache(addr);
                if(physical_addr != null)
                    physical_mbrs.add(physical_addr);
            }
            retainAll(physical_mbrs); // remove all connections from the ConnectionTable which are not members
        }
View Full Code Here

Examples of org.jgroups.PhysicalAddress

        super.start();
        initial_hosts = Util.parseCommaDelimetedHosts(hosts, port_range);      
    }
   
    public void sendGetMembersRequest(String cluster_name, Promise promise) throws Exception{
        PhysicalAddress physical_addr=(PhysicalAddress)down_prot.down(new Event(Event.GET_PHYSICAL_ADDRESS, local_addr));
        PingData data=new PingData(local_addr, null, false, UUID.get(local_addr), Arrays.asList(physical_addr));
        PingHeader hdr=new PingHeader(PingHeader.GET_MBRS_REQ, data, cluster_name);
        for(final Address addr: initial_hosts) {
            if(addr.equals(physical_addr))
                continue;
View Full Code Here

Examples of org.jgroups.PhysicalAddress

                            if (log.isTraceEnabled()) {
                                log.trace("Reconnecting " + stub);
                            }

                            String logical_name = org.jgroups.util.UUID.get(logicalAddress);
                            PhysicalAddress physical_addr = (PhysicalAddress) owner.down(new Event(
                                            Event.GET_PHYSICAL_ADDRESS, logicalAddress));
                            List<PhysicalAddress> physical_addrs = Arrays.asList(physical_addr);
                            stub.connect(channelName, logicalAddress, logical_name, physical_addrs);
                            if (log.isTraceEnabled()) {
                                log.trace("Reconnected " + stub);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.