public ChordNodeImpl(IChordNode knownPeer, String _rmiURL, String _chordName)
            throws RemoteException, NoSuchAlgorithmException {
        super();

        isActive = false;
        predecessor = null;
        nextFinger = 0;

        String tmpURL = _rmiURL + _chordName;
        chordId = HashUtil.hash(tmpURL.getBytes(), HashUtil.SHA_ALGO, KeyImpl.KEY_MAX);
        this.rmiURL = _rmiURL + chordId;

        if (knownPeer == null) {
            createGroup();
        } else {
            joinGroup(knownPeer);
        }

        isActive = true;

        // Runnable nested class for stablizing
        Runnable stabalizer = new Runnable() {
            @Override
            public void run() {
                try {
                    stablize();
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        };

        // Runnable nested class for fixing fingers
        Runnable fingerFixer = new Runnable() {
            @Override
            public void run() {
                try {
                    fixFingers();
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        };

        // Runnable nested class for checking predecessor
        Runnable predecessorChecker = new Runnable() {
            @Override
            public void run() {
                try {
                    checkPredecessor();
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        };

        // Runnable nested class for updating successor list
        Runnable successorListUpdator = new Runnable() {
            @Override
            public void run() {
                try {
                    updateSuccessorList(getSuccessor().getSuccessorList());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        };

        scheduler.scheduleAtFixedRate(stabalizer, 1, 1, TimeUnit.SECONDS);
        scheduler.scheduleAtFixedRate(fingerFixer, 1, 1, TimeUnit.SECONDS);
        scheduler.scheduleAtFixedRate(predecessorChecker, 1, 1, TimeUnit.SECONDS);
        scheduler.scheduleAtFixedRate(successorListUpdator, 1, 1, TimeUnit.SECONDS);
    }