public static void main(String[] args) throws IOException, InterruptedException {

			bb = new BananaBank("accounts.txt");

				
			allAccounts = bb.getAllAccounts();
			
					
	    	int portNumber = 2000;

	    	ServerSocket serverSocket= new ServerSocket(portNumber);
	    	serverSocket.setSoTimeout(100);
	    	
	    	
	    	
	    	
	    	try {
	    		while (!shutdown){

	    			try{
	    				Socket clientSocket = serverSocket.accept();
	    				BananaBankServerWorkerThread bbswt = new BananaBankServerWorkerThread(clientSocket);
		    			bbswt.start();
	    			}catch (SocketTimeoutException e){
	    				//if server timed out, do nothing
	    			}
	    			
	    		}
	        } catch (IOException e) {
	        	
	        	e.printStackTrace();
	        }
	    	
	    	while (available.availablePermits() != max_permits){}//waits for threads to stop
	    	
	    	bb.save("accounts.foo");
	    	
	    	serverSocket.close();
	    
		}