WebSphere Extended Deployment, Version 6.0.x
             Operating Systems: AIX, HP-UX, Linux, Solaris, Windows, z/OS


Adding sample partitions

About this task

Add the following variable to the partition stateless session bean (PSSB):

PartitionManager ivRuntime;

You also need to add the following import:

import com.ibm.websphere.wpf.*;

Update your setSessionContext method to look like the following:
public void setSessionContext(javax.ejb.SessionContext ctx) {
		mySessionCtx = ctx;
		try
		{
			InitialContext ic = new InitialContext();
			ivRuntime = (PartitionManager)ic.lookup(PartitionManager.JNDI_NAME);
			
		}
		catch(Exception e)
		{
			throw new EJBException("Problem initializing PSSB", e);
		}
	}
This retrieves the PartitionManager service that is used to create data structures needed for partitioning.



Related tasks
Using WSAD 5.1 with a new partitioned application
Related reference
Update the getPartitions method
Task topic    

Terms of Use | Feedback

Last updated: Oct 16, 2009 11:11:31 AM EDT
http://publib.boulder.ibm.com/infocenter/wxdinfo/v6r0/index.jsp?topic=/com.ibm.websphere.xd.doc/info/WPF51/twpfaddsampparts.html