[Batchserver-cvs] batchserver/src/org/jmonks/batchserver/framework/config BasicJobControllerConfig.j
Brought to you by:
suresh_pragada
From: Suresh <sur...@us...> - 2006-03-10 08:14:55
|
Update of /cvsroot/batchserver/batchserver/src/org/jmonks/batchserver/framework/config In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1421 Modified Files: BasicJobControllerConfig.java framework-config.xml JobConfig.java PoolJobControllerConfig.java Log Message: no message Index: JobConfig.java =================================================================== RCS file: /cvsroot/batchserver/batchserver/src/org/jmonks/batchserver/framework/config/JobConfig.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** JobConfig.java 8 Mar 2006 00:30:49 -0000 1.4 --- JobConfig.java 10 Mar 2006 08:14:51 -0000 1.5 *************** *** 30,34 **** */ protected String jobName=null; ! /** * Controller configuration of the job. --- 30,37 ---- */ protected String jobName=null; ! /** ! * Variable holds the status of the job. True stands for active and flase stands inactive. ! */ ! protected boolean jobStatus = true; /** * Controller configuration of the job. *************** *** 57,63 **** /** * <p> * Returns the string representation of JobConfig class in the format ! * <br> {JobConfig [name = value] [controllerConfig = value]} * </p> * --- 60,78 ---- /** + * Returns whether the job is active or not. + * This information will be found from the instance varaiable jobStatus. + * JobStatus of true indicates active and false indicates inactive. + * + * @return Returns true, if job is active, false otherwise. + */ + public boolean isActive() + { + return this.jobStatus; + } + + /** * <p> * Returns the string representation of JobConfig class in the format ! * <br> {JobConfig [name = value] [status = value] [controllerConfig = value]} * </p> * *************** *** 68,71 **** --- 83,87 ---- StringBuffer stringValue=new StringBuffer("{JobConfig "); stringValue.append("[name = " + this.jobName + "]"); + stringValue.append("[status = " + this.jobStatus + "]"); stringValue.append("[controllerConfig = " + this.jobControllerConfig + "]"); stringValue.append("}"); Index: framework-config.xml =================================================================== RCS file: /cvsroot/batchserver/batchserver/src/org/jmonks/batchserver/framework/config/framework-config.xml,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** framework-config.xml 9 Mar 2006 04:44:07 -0000 1.7 --- framework-config.xml 10 Mar 2006 08:14:51 -0000 1.8 *************** *** 12,17 **** <job-config-reader-config config-reader-class-name="org.jmonks.batchserver.framework.config.DBJobConfigReader"> ! <property key="config-db-jdbc-driver-class-name"></property> ! <property key="config-db-url">jdbc:oracle:thin@hostname:1521:instname</property> <property key="config-db-username">scott</property> <property key="config-db-password">tiger</property> --- 12,17 ---- <job-config-reader-config config-reader-class-name="org.jmonks.batchserver.framework.config.DBJobConfigReader"> ! <property key="config-db-jdbc-driver-class-name">oracle.jdbc.driver.OracleDriver</property> ! <property key="config-db-url">jdbc:oracle:thin:@hostname:1521:instname</property> <property key="config-db-username">scott</property> <property key="config-db-password">tiger</property> Index: BasicJobControllerConfig.java =================================================================== RCS file: /cvsroot/batchserver/batchserver/src/org/jmonks/batchserver/framework/config/BasicJobControllerConfig.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** BasicJobControllerConfig.java 9 Mar 2006 04:44:07 -0000 1.4 --- BasicJobControllerConfig.java 10 Mar 2006 08:14:51 -0000 1.5 *************** *** 38,42 **** */ protected Map basicJobProcessorConfigProps=new HashMap(); ! /** * Gets the basic job processor class name. --- 38,46 ---- */ protected Map basicJobProcessorConfigProps=new HashMap(); ! ! /** ! * Holds the number of instances needs to be created. ! */ ! protected int basicJobProcessorThreadCount=1; /** * Gets the basic job processor class name. *************** *** 96,103 **** /** * <p> * Returns the string representation of BasicJobControllerConfig class in the format * <br> {BasicJobControllerConfig [controllerClassName = value] [controllerConfigProps = value] ! * [basicJobProcessorClassName = value] [basicJobProcessorConfigProps = value]} * </p> * --- 100,118 ---- /** + * Returns the number of basic job processor instances needs to be run to process this job. + * + * @return Returns the number of threads. + */ + public int getBasicJobProcessThreadCount() + { + return this.basicJobProcessorThreadCount; + } + + /** * <p> * Returns the string representation of BasicJobControllerConfig class in the format * <br> {BasicJobControllerConfig [controllerClassName = value] [controllerConfigProps = value] ! * [basicJobProcessorClassName = value] [basicJobProcessorConfigProps = value] ! * [basicJobProcessorThreadCount = value]} * </p> * *************** *** 111,114 **** --- 126,130 ---- stringValue.append("[basicJobProcessorClassName = " + this.basicJobProcessorClassName + "]"); stringValue.append("[basicJobProcessorConfigProps = " + this.basicJobProcessorConfigProps + "]"); + stringValue.append("[basicJobProcessorThreadCount = " + this.basicJobProcessorThreadCount + "]"); stringValue.append("}"); return stringValue.toString(); Index: PoolJobControllerConfig.java =================================================================== RCS file: /cvsroot/batchserver/batchserver/src/org/jmonks/batchserver/framework/config/PoolJobControllerConfig.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** PoolJobControllerConfig.java 9 Mar 2006 04:44:07 -0000 1.4 --- PoolJobControllerConfig.java 10 Mar 2006 08:14:51 -0000 1.5 *************** *** 49,52 **** --- 49,56 ---- protected Map poolJobProcessorConfigProps=new HashMap(); /** + * Holds the number of instances to be created. + */ + protected int poolJobProcessorThreadCount=1; + /** * Pool class name. */ *************** *** 181,184 **** --- 185,198 ---- /** + * Returns the number of instances of pool job processors needs to be created to process this job. + * + * @return Return the number of threads. + */ + public int getPoolJobProcessorThreadCount() + { + return this.poolJobProcessorThreadCount; + } + + /** * <p> * Returns the string representation of PoolJobControllerConfig class in the format *************** *** 186,190 **** * [poolJobProcessorClassName = value] [poolJobProcessorConfigProps = value] * [poolJobLoaderClassName = value] [poolJobLoaderConfigProps = value] ! * [jobPoolClassName = value] [jobPoolConfigProps = value]} * </p> * --- 200,205 ---- * [poolJobProcessorClassName = value] [poolJobProcessorConfigProps = value] * [poolJobLoaderClassName = value] [poolJobLoaderConfigProps = value] ! * [jobPoolClassName = value] [jobPoolConfigProps = value] ! * [poolJobProcessorThreadCount = value]} * </p> * *************** *** 203,206 **** --- 218,222 ---- stringValue.append("[jobPoolClassName = " + this.poolClassName + "]"); stringValue.append("[jobPoolConfigProps = " + this.poolConfigProps + "]"); + stringValue.append("[poolJobProcessorThreadCount = " + this.poolJobProcessorThreadCount + "]"); stringValue.append("}"); |