container/router/src/main/java/org/mobicents/slee/runtime/eventrouter/mapping/RoundRobinEventRouterExecutorMapper.java
private int getNextIndex() {
		for (;;) {
            int current = index.get();
            int next = (current == executors.length ? 1 : current + 1);
            if (index.compareAndSet(current, next))
                return next-1;
        }
	}
private int getNextIndex() {
		for (;;) {
            int current = index.get();
            int next = (current == executors.length ? 1 : current + 1);
            if (index.compareAndSet(current, next))
                return next-1;
        }
	}
Computes the index of the next executor to retrieve. Adaptation of the {@link AtomicInteger} incrementAndGet() code.

@return