public void run() {
		try {
			while (true) {
				int n = selector.select();
				if (n == 0) {
					continue;
				}
				keys = selector.selectedKeys();
				Iterator<SelectionKey> iter = keys.iterator();

				while (iter.hasNext()) {
					SelectionKey key = iter.next();
					iter.remove();
					if (key.isValid()) {
						/**config*/
						if (count.compareAndSet(0, 1)) {
							validOperation(key);
						}
						if (key.isReadable()) {
							readOperation(key);
						}else if(key.isWritable()){
							
						}
					}
				}

			}
		} catch (Exception e) {
			e.printStackTrace();
		}
	}