Package org.jboss.as.network

Examples of org.jboss.as.network.SocketBindingManager


            if (connectorPropertiesOptionMap != null) {
                builder.addAll(connectorPropertiesOptionMap);
            }
            builder.addAll(rsp.getOptionMap());
            streamServer = networkServerProvider.createServer(getSocketAddress(), builder.getMap(), sap, rsp.getXnioSsl());
            SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
            if (sbm != null) {
                managedBinding = registerSocketBinding(sbm);
            }
            log.infof("Listening on %s", getSocketAddress());
View Full Code Here


    }

    @Override
    public void stop(StopContext context) {
        IoUtils.safeClose(streamServer);
        SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
        if (sbm != null && managedBinding != null) {
            unregisterSocketBinding(managedBinding, sbm);
        }
    }
View Full Code Here

            OptionMap resultingMap = builder.getMap();
            if (log.isTraceEnabled()) {
                log.tracef("Resulting OptionMap %s", resultingMap.toString());
            }
            streamServer = networkServerProvider.createServer(getSocketAddress(), resultingMap, sap, rsp.getXnioSsl());
            SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
            if (sbm != null) {
                managedBinding = registerSocketBinding(sbm);
            }
            ROOT_LOGGER.listeningOnSocket(getSocketAddress());
View Full Code Here

    }

    @Override
    public void stop(StopContext context) {
        IoUtils.safeClose(streamServer);
        SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
        if (sbm != null && managedBinding != null) {
            unregisterSocketBinding(managedBinding, sbm);
        }
    }
View Full Code Here

    @Test
    public void getAddress() throws UnknownHostException {
        InetAddress expected = InetAddress.getLocalHost();
        NetworkInterfaceBinding interfaceBinding = new NetworkInterfaceBinding(Collections.<NetworkInterface>emptySet(), expected);
        SocketBindingManager bindingManager = mock(SocketBindingManager.class);
        SocketBinding binding = new SocketBinding("socket", 1, true, null, 0, interfaceBinding, bindingManager, Collections.<ClientMapping>emptyList());
        InjectedValue<SocketBinding> bindingValue = new InjectedValue<SocketBinding>();

        bindingValue.inject(binding);
        when(this.listener.getBinding()).thenReturn(bindingValue);
View Full Code Here

    @Test
    public void getPort() throws UnknownHostException {
        int expected = 10;
        NetworkInterfaceBinding interfaceBinding = new NetworkInterfaceBinding(Collections.<NetworkInterface>emptySet(), InetAddress.getLocalHost());
        SocketBindingManager bindingManager = mock(SocketBindingManager.class);
        SocketBinding binding = new SocketBinding("socket", expected, true, null, 0, interfaceBinding, bindingManager, Collections.<ClientMapping>emptyList());
        InjectedValue<SocketBinding> bindingValue = new InjectedValue<SocketBinding>();

        bindingValue.inject(binding);
        when(this.listener.getBinding()).thenReturn(bindingValue);
View Full Code Here

            OptionMap resultingMap = builder.getMap();
            if (log.isTraceEnabled()) {
                log.tracef("Resulting OptionMap %s", resultingMap.toString());
            }
            streamServer = networkServerProvider.createServer(getSocketAddress(), resultingMap, sap, rsp.getXnioSsl());
            SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
            if (sbm != null) {
                managedBinding = registerSocketBinding(sbm);
            }
            ROOT_LOGGER.listeningOnSocket(NetworkUtils.formatAddress(getSocketAddress()));
View Full Code Here

    }

    @Override
    public void stop(StopContext context) {
        IoUtils.safeClose(streamServer);
        SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
        if (sbm != null && managedBinding != null) {
            unregisterSocketBinding(managedBinding, sbm);
        }
    }
View Full Code Here

            if (connectorPropertiesOptionMap != null) {
                builder.addAll(connectorPropertiesOptionMap);
            }
            builder.addAll(rsp.getOptionMap());
            streamServer = networkServerProvider.createServer(getSocketAddress(), builder.getMap(), sap, rsp.getXnioSsl());
            SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
            if (sbm != null) {
                managedBinding = registerSocketBinding(sbm);
            }
            ROOT_LOGGER.listeningOnSocket(getSocketAddress());
View Full Code Here

    }

    @Override
    public void stop(StopContext context) {
        IoUtils.safeClose(streamServer);
        SocketBindingManager sbm = socketBindingManagerValue.getOptionalValue();
        if (sbm != null && managedBinding != null) {
            unregisterSocketBinding(managedBinding, sbm);
        }
    }
View Full Code Here

TOP

Related Classes of org.jboss.as.network.SocketBindingManager

Copyright © 2018 www.massapicom. 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.