|   | 
	 
  
    | 
RSS Feed - WebSphere MQ Support
 | 
RSS Feed - Message Broker Support
 |   
 
  
	     | 
	 | 
   
 
  
	|  restrict message through out terminal of compute node | 
	« View previous topic :: View next topic »  | 
   
  
  	
	  
		
		
		  | Author | 
		  Message
		 |  
		
		  | rohank84 | 
		  
		    
			  
				 Posted: Wed Jan 07, 2009 1:41 am    Post subject: restrict message through out terminal of compute node | 
				     | 
			   
			 
		   | 
		 
		
		   Centurion
 
 Joined: 31 Dec 2008 Posts: 109
  
  | 
		  
		    
			  
				hi 
 
 
how can i restrict message passing through OUT terminal of compute node. I have read few forums which suggest to add RETURN FALSE in esql. i have included this but message still flows through this terminal. Below is my code
 
 
CREATE FUNCTION Main() RETURNS BOOLEAN
 
	BEGIN
 
		
 
		declare loopnumber character;
 
		
 
		SET Environment.Variables.EMAILBL.EMAIL[] = (Select COALESCE(emp.email,'') as MYEMAIL from Database.EMP_DETAILS as emp WHERE emp.name = 'nikhil');
 
		SET  loopnumber = Environment.Variables.EMAILBL.EMAIL[1].MYEMAIL;
 
		Insert into Database.EMP_DETAILS(name,email) values (loopnumber,'test'); --to be deleted later
 
		
 
		IF loopnumber = 'out1' THEN
 
			
 
		
 
		
 
		SET OutputRoot = InputRoot;
 
		PROPAGATE DELETE NONE;
 
		PROPAGATE TO TERMINAL 'out1'; 
 
		RETURN FALSE;
 
			
 
		ELSE
 
			
 
		
 
		SET OutputRoot = InputRoot;
 
		PROPAGATE DELETE NONE;
 
		PROPAGATE TO TERMINAL 'out2'; 
 
		RETURN FALSE;
 
			
 
		END IF;
 
		
 
		
 
		-- CALL CopyMessageHeaders();
 
		-- CALL CopyEntireMessage();
 
		RETURN FALSE;
 
	END;
 
 
 
 
Thanks | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | elvis_gn | 
		  
		    
			  
				 Posted: Wed Jan 07, 2009 1:47 am    Post subject: Re: restrict message through out terminal of compute node | 
				     | 
			   
			 
		   | 
		 
		
		    Padawan
 
 Joined: 08 Oct 2004 Posts: 1905 Location: Dubai 
  | 
		  
		    
			  
				Hi rohank84,
 
   
	| rohank84 wrote: | 
   
  
	
   
	| Code: | 
   
  
	SET OutputRoot = InputRoot;
 
PROPAGATE DELETE NONE;
 
PROPAGATE TO TERMINAL 'out1'; 
 
RETURN FALSE;
 
         
 
ELSE
 
         
 
      
 
SET OutputRoot = InputRoot;
 
PROPAGATE DELETE NONE;
 
PROPAGATE TO TERMINAL 'out2'; 
 
RETURN FALSE;
 
         
 
END IF; | 
   
 
 | 
   
 
Why two propagates ? The first one without a terminal name will by default send it to OUT.
 
 
Regards. | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | rohank84 | 
		  
		    
			  
				 Posted: Tue Jan 27, 2009 3:15 am    Post subject:  | 
				     | 
			   
			 
		   | 
		 
		
		   Centurion
 
 Joined: 31 Dec 2008 Posts: 109
  
  | 
		  
		    
			  
				hi elvis 
 
 
i have to do a load balancing kind of stuff ...so thats y using every terminal of compute node.....the code will be same at all mthe terminals but each terminal will be used from time to time (round robbin format) | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | Vitor | 
		  
		    
			  
				 Posted: Tue Jan 27, 2009 3:20 am    Post subject:  | 
				     | 
			   
			 
		   | 
		 
		
		    Grand High Poobah
 
 Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA 
  | 
		  
		    
			  
				
   
	| rohank84 wrote: | 
   
  
	| i have to do a load balancing kind of stuff | 
   
 
 
 
Why not use a WMQ cluster, which is quite good at this sort of thing, rather than trying to build it in broker? Even if the output going to a non-WMQ protocol there are a number of external load balancing solutions that don't require you to reinvent this wheel. _________________ Honesty is the best policy.
 
Insanity is the best defence. | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | 
		    
		   | 
		 
	   
	 | 
   
 
  
	     | 
	 | 
	Page 1 of 1 | 
   
 
 
 
  
  	
	  
		
		  
 
  | 
		  You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
  | 
  		 
	   
	 | 
   
 
  	 | 
	  |