public void processOtherEvent(Sim_event ev){
        switch(ev.get_tag()){
	    	// receives the application and submits each one of its
	        // gridlets (jobs) to the broker.
           	case GridSimTags.EXPERIMENT:
        		// Requesting the GridInformationService
                // to send a list of resources
       	        resourceIDList = super.getGridResourceList();
       	        auctionsClient = (LinkedList)((LinkedList)ev.get_data());
            	jobsReturned = new GridletList();

                // Set Gridlets OwnerID as the BrokerID so that Resources
                // knows where to return them.
                this.userID = ev.get_src();

                long seed = 11L*13*17*19*23+1;

            	// To avoid a bunch of reply messages to the auctions,
            	// we add a delay between auctions
                Sim_uniform_obj genDelay = new Sim_uniform_obj("delay",60 * 6, 60 * 60 * 1, seed);

            	try{
            		for(int i=0; i<auctionsClient.size(); i++){
            			OneSidedAuction auction = (OneSidedAuction)auctionsClient.get(i);

            			auction.setAuctioneerID(this.get_id());
            			auction.setOutputPort(this.output);

            			auction.setBidders((LinkedList)resourceIDList.clone());

				        super.send(super.get_id(), GridSimTags.SCHEDULE_NOW, AuctionTags.AUCTION_POST, auction);
				        super.send(super.get_id(), genDelay.sample(),
					              		AuctionTags.AUCTION_START, new Integer(auction.getAuctionID()));

				        System.out.println(super.get_name() + " " +
				        		"starting the auction " + auction.getAuctionID() + " to acquire resource to execute job " +
					        		((Gridlet)auction.getAttribute("job")).getGridletID() + " from user " + userID);
					}
            	}
            	catch(Exception ex){
            			ex.printStackTrace();
            	}
                break;

                // deal with gridlet return
                case GridSimTags.GRIDLET_RETURN:
                	Gridlet result = (Gridlet)ev.get_data();
                	result.setUserID(this.userID);
                	jobsReturned.add(result);
                	this.finishedJobs++;
                	// sends a check experiment event to itself
               		super.send(super.get_id(), GridSimTags.SCHEDULE_NOW,
               				Broker.CHECK_EXPERIMENT, null);
                break;

                // verifies if all the jobs of the experiment have been finished
                case Broker.CHECK_EXPERIMENT:
                	if( (this.finishedJobs + this.notSubmittedJobs) == auctionsClient.size() ){
                		super.send(this.userID, GridSimTags.SCHEDULE_NOW,
                				GridSimTags.EXPERIMENT, jobsReturned);
                	}
                break;

            	default:
            		break;
            }
	}