private void startMonitor(){		
		try{
			// Create a new selector
			Selector selector = Selector.open();
			
			// Create a new non-blocking server socket channel
			ServerSocketChannel serverChannel = ServerSocketChannel.open();
			serverChannel.configureBlocking(false);
			
			InetSocketAddress isa = new InetSocketAddress(this.port);
			serverChannel.socket().bind(isa);			
						
			// Register the server socket channel, indicating an interest in 
			// accepting new connections
			serverChannel.register(selector, SelectionKey.OP_ACCEPT);
			
			log.info("服务器准备就绪，等待请求到来");
			while(noStopRequested){
				try {					
					int num = 0;
					// Wait for an event one of the registered channels
					num = selector.select(100);
					if (num > 0) {
						// Iterate over the set of keys for which events are available
						Iterator selectedKeys = selector.selectedKeys().iterator();
						while (selectedKeys.hasNext()) {
							SelectionKey key = (SelectionKey) selectedKeys.next();
							selectedKeys.remove();
							
							if (!key.isValid()) {
								continue;
							}
		
							// Check what event is available and deal with it
							if (key.isAcceptable()) {
								this.accept(key,false);
							}
						}
					}					
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
			
			serverChannel.close();// 关闭服务器
			
		}catch(Exception e){
			e.printStackTrace();
			System.out.println("Server start up fail");
		}
	}