|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.swing.tree.DefaultMutableTreeNode PIRL.PVL.Parameter PIRL.Messenger.Message PIRL.Conductor.Maestro.Conductor_Definition
public class Conductor_Definition
A Conductor_Definition contains the information that defines a Conductor instance.
A Conductor_Definition encapsulates the information necessary to instantiate a Conductor object.
The name
of the definition is used to refer to the
entire definition.Typically this name is expected to be unique in a
set of Conductor_Definition objects such that if refers to a
combination of definition parameter values that does not match
the combination of parameter values in any
other Conductor_Definition object of the set.
A Conductor_Defintion may contain the following parameters:
PIPELINE_PARAMETER_NAME
CONFIGURATION_PARAMETER_NAME
CONFIGURATION_SOURCE_PARAMETER_NAME
or, if this is not present, the
DEFAULT_CONFIGURATION_FILENAME
for its value.
SERVER_PARAMETER_NAME
CATALOG_PARAMETER_NAME
Conductor
,
Serialized FormField Summary | |
---|---|
static String |
ACTION_PARAMETER_NAME
The name of the parameter that specifies the Start_Conductor_Message(boolean, int) action. |
static String |
CATALOG_PARAMETER_NAME
The name of the parameter that specifies the database catalog containing the pipeline tables. |
static String |
CONFIGURATION_PARAMETER_NAME
The name of the parameter that specifies the Configuration source. |
static String |
CONFIGURATION_SOURCE_PARAMETER_NAME
The name of the parameter that specifies the Configuration source in a Conductor Conductor.Identity() . |
static String |
COUNT_PARAMETER_NAME
The name of the parameter used to specify the number of Conductor instances to run in a Stage_Manger Start_Conductor_Message(boolean, int) . |
static String |
DEFAULT_CONFIGURATION_FILENAME
The default Configuration source filename. |
static String |
ID
Class identification name with source code version and date. |
static String |
PIPELINE_PARAMETER_NAME
The name of the parameter that specifies the pipeline name. |
static String |
SERVER_PARAMETER_NAME
The name of the parameter that specifies the database server access information parameters group name in the Configuration source . |
static String |
START_CONDUCTORS_ACTION
The value of the ACTION_PARAMETER_NAME parameter. |
static String |
WAIT_TO_START_PARAMETER_NAME
The name of the parameter that is used to tell a Conductor instantiation to wait to start. |
Fields inherited from class PIRL.Messenger.Message |
---|
ACK_ACTION, CLASS_ID_PARAMETER_NAME, CONTENT_AMOUNT_PARAMETER_NAME, DONE_ACTION, ERROR_MESSAGE_MARKER, IDENTIFY_ACTION, IDENTITY_ACTION, NACK_ACTION, NAME_PARAMETER_NAME, ROUTE_FROM_PARAMETER_NAME, ROUTE_TO_PARAMETER_NAME, START_MARKER, START_MARKER_DELIMITER, START_MARKER_END |
Fields inherited from class PIRL.PVL.Parameter |
---|
AGGREGATE, ASSIGNMENT, BEGIN_GROUP, BEGIN_OBJECT, END, END_AGGREGATE, END_GROUP, END_OBJECT, END_PVL, GROUP, HIGHEST_BIT, LOWEST_BIT, MASK, OBJECT, TOKEN, UNKNOWN |
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode |
---|
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject |
Constructor Summary | |
---|---|
Conductor_Definition(Message message)
Creates a Conductor_Definition from a Message. |
|
Conductor_Definition(Parameter parameter)
Creates a Conductor_Definition from a Parameter. |
|
Conductor_Definition(String pipeline)
Creates a Conductor_Definition from a pipeline name. |
Method Summary | |
---|---|
boolean |
Matches(Message message)
Test if a Conductor Definition Message matches this Conductor_Definition. |
Message |
Start_Conductor_Message(boolean wait_to_start,
int count)
Generate a Message used by the Stage_Manager to instantiate a Conductor. |
Message |
Start_Conductor_Message(boolean wait_to_start,
Integer count)
Generate a Message used by the Stage_Manager to instantiate a Conductor. |
void |
Validate()
Validate this Conductor_Definition. |
Methods inherited from class PIRL.Messenger.Message |
---|
Action, Action, Add, Add, Clear_Route_From, Clear_Route_To, Content_Amount, Content_String, Content, Destination_Address, Done, From, From, Get, Identify, Identity, Identity, Matching, NACK, Packet_Label, Packet, Pop_From, Pop_To, PVL_Lister, PVL_Parser, PVL, Remove_All, Remove, Reply_To, Route_From_Count, Route_From, Route_From, Route_To_Count, Route_To, Route_To, Route_To, Routing, Set_Token, Set_Token, Set, Set, Set, Set, Set, Set, Set, Set, Source_Address, To, To, toString, Unescape, Valid_Route, Value_of_Matching, Value_of |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String ID
public static final String PIPELINE_PARAMETER_NAME
public static final String CONFIGURATION_PARAMETER_NAME
CONFIGURATION_SOURCE_PARAMETER_NAME
,
Constant Field Valuespublic static final String CONFIGURATION_SOURCE_PARAMETER_NAME
Conductor.Identity()
.
CONFIGURATION_PARAMETER_NAME
,
Constant Field Valuespublic static final String DEFAULT_CONFIGURATION_FILENAME
public static final String SERVER_PARAMETER_NAME
Configuration source
.
public static final String CATALOG_PARAMETER_NAME
public static final String ACTION_PARAMETER_NAME
Start_Conductor_Message(boolean, int)
action.
public static final String START_CONDUCTORS_ACTION
ACTION_PARAMETER_NAME
parameter.
public static final String WAIT_TO_START_PARAMETER_NAME
The Conductor will remain in the Conductor.WAITING
.processing
state if this parameter is included in the Conductor_Definition; otherwise
it will immediately enter the Conductor.RUNNING
processing
state.
public static final String COUNT_PARAMETER_NAME
Start_Conductor_Message(boolean, int)
.
N.B.: This parameter is not a Conductor command line option.
Constructor Detail |
---|
public Conductor_Definition(Message message) throws PVL_Exception, IllegalArgumentException
The Message parameters and name are copied and then the contents
are validated
.
message
- A Message containg Conductor definition parameters.
PVL_Exception
- If the definition could not be copied into
this object and validated
.
IllegalArgumentException
- If the Message content does not
produce a valid
Conductor_Definition.public Conductor_Definition(Parameter parameter) throws PVL_Exception, IllegalArgumentException
If the Parameter is an Assignment it becomes the sole
Parameter in this Message. If it is an Aggregate its Parameter list
becomes the list of Parameters in this Message and its name
becomes the name of this Message.
The contents of the new Conductor_Definition are validated
.
PVL_Exception
- If the Parameter could not be copied into
this object and validated
.
IllegalArgumentException
- If the Parameter content does not
produce a valid
Conductor definition.public Conductor_Definition(String pipeline) throws IllegalArgumentException
The resulting definition will have its name
and
PIPELINE_PARAMETER_NAME
parameter value set to the pipeline
name. The CONFIGURATION_PARAMETER_NAME
will be set with the
DEFAULT_CONFIGURATION_FILENAME
value. No other parameters
will be present.
pipeline
- The name of the Conductor pipeline.
IllegalArgumentException
- If the pipeline name is null, empty
or the special Parser.CONTAINER_NAME
.Method Detail |
---|
public boolean Matches(Message message)
The match criteria are:
If the PIPELINE_PARAMETER_NAME
parameter is present in the
message its value must match the value of the same parameter in this
Conductor_Definition. If it is not present in the message the message
name
must match the parameter value in this
Conductor_Definition. The Conductor_Definition will always contain
this parameter; the Message must either contain the parameter with
the same value or be named the same.
If the CONFIGURATION_PARAMETER_NAME
or CONFIGURATION_SOURCE_PARAMETER_NAME
parameter is present in
the message its value must match the value of the same parameter in
this Conductor_Definition. If it is not present in the message the
parameter value in this Conductor_Definition must be DEFAULT_CONFIGURATION_FILENAME
. The Conductor_Definition will
always contain this parameter; it is optional for the Message.
If the SERVER_PARAMETER_NAME
parameter is present in the
message the same parameter must be present in this
Conductor_Definition with the same value. If the parameter is not
present in the message it must not be present in this
Conductor_Definition. This parameter is optional for both the
Conductor_Definition and the Message.
If the CATALOG_PARAMETER_NAME
parameter is present in the
message the same parameter must be present in this
Conductor_Definition with the same value. If the parameter is not
present in the message it must not be present in this
Conductor_Definition. This parameter is optional for both the
Conductor_Definition and the Message.
N.B.: The name
of the Message does not need
to match the name of this Conductor_Definition. Also, the Message
may contain additional parameters other than those used to determine
the match; the match is only against the Conductor_Definition
parameters.
message
- A Message. If null, false is returned.
public Message Start_Conductor_Message(boolean wait_to_start, int count) throws IllegalArgumentException, PVL_Exception
A validated
copy of this Conductor_Definition is
filtered for use as a Stage_Manager Conductor start request Message.
The Conductor_Definition must contain a PIPELINE_PARAMETER_NAME
parameter. The new Message will have an
ACTION_PARAMETER_NAME
set to START_CONDUCTORS_ACTION
.
wait_to_start
- If true a WAIT_TO_START_PARAMETER_NAME
token parameter will be included
in the returned Message.count
- If the value of this integer is greater than 1 a
COUNT_PARAMETER_NAME
parameter having the count value
will be included in the returned Message.
IllegalArgumentException
- If this Conductor_Description
is not valid
.
PVL_Exception
- If this Conductor_Definition could not be
copied into a new Message.public Message Start_Conductor_Message(boolean wait_to_start, Integer count) throws PVL_Exception, IllegalArgumentException
This is a convenience interface to the Start_Conductor_Message(boolean, int)
method.
wait_to_start
- If true a WAIT_TO_START_PARAMETER_NAME
token parameter will be included
in the returned Message.count
- If the value of this Integer is greater than 1 a
COUNT_PARAMETER_NAME
parameter having the count value
will be included in the returned Message.
PVL_Exception
- If this Conductor_Definition could not be
copied into a new Message.
IllegalArgumentException
- If this Conductor_Description
does not contain a PIPELINE_PARAMETER_NAME
parameter.Start_Conductor_Message(boolean, int)
public void Validate() throws IllegalArgumentException
The values of all Conductor definition parameters are obtained and checked for definition rule violations:
Each Conductor_Definition parameter, if present, must have a non-empty value.
If the PIPELINE_PARAMETER_NAME
parameter is not present the
name
of the definition must not be the Parser.CONTAINER_NAME
or empty. The default value for this required
parameter is the name of the definition so the name must be valid if
the parameter is not present.
All of the current parameters are then removed and the Conductor definition parameters are set to appropriate values:
If the PIPELINE_PARAMETER_NAME
parameter was not present it
is set to the definition name; the default value for this required
parameter is the name of the definition. If the parameter was present
and the name of the defintion is the Parser.CONTAINER_NAME
or
empty the definition name is set to the value of the parameter. This
parameter will be the first entry in the Conductor_Definition.
If neither the CONFIGURATION_PARAMETER_NAME
parameter nor
CONFIGURATION_SOURCE_PARAMETER_NAME
parameter was present
the CONFIGURATION_PARAMETER_NAME
parameter is set to the
DEFAULT_CONFIGURATION_FILENAME
. This parameter will be the
third entry in the Conductor_Definition.
If the SERVER_PARAMETER_NAME
and CATALOG_PARAMETER_NAME
parameters were present they are restored.
They are not entered if they were not originally present.
N.B.: Any other parameters are not relevant to a Conductor_Definition and so are removed.
IllegalArgumentException
- If the PIPELINE_PARAMETER_NAME
parameter isn't present and the name
of the definition is the Parser.CONTAINER_NAME
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |