org.cougaar.pizza.plugin
Class MatchmakerPlugin

java.lang.Object
  extended byorg.cougaar.util.GenericStateModelAdapter
      extended byorg.cougaar.core.blackboard.BlackboardClientComponent
          extended byorg.cougaar.core.plugin.ComponentPlugin
              extended byorg.cougaar.servicediscovery.plugin.SimpleMatchmakerPlugin
                  extended byorg.cougaar.pizza.plugin.MatchmakerPlugin
All Implemented Interfaces:
org.cougaar.core.blackboard.BlackboardClient, org.cougaar.core.component.Component, org.cougaar.util.GenericStateModel, org.cougaar.core.plugin.PluginBase

public class MatchmakerPlugin
extends org.cougaar.servicediscovery.plugin.SimpleMatchmakerPlugin

The Matchmaker is responsible for taking service discovery requests (MMQueryRequests) from the SDClientPlugin, and issuing asynchronous queries to the YP to find matching providers. When one (or more) is found, send the scored results back the SDClient on the MMQueryRequest.

This version extends the SimpleMatchmakerPlugin, specifying that the Role requested will be in the pizza constants Constants.UDDIConstants.COMMERCIAL_SERVICE_SCHEME. As noted in the base class, it allows the YP to handle walking up YP communities as necessary. It does not handle quiescence, is not guaranteed to work with kills/restarts (persistence), only works with a distributed YP (using communities, not a single static instance), etc.

System Property:
org.cougaar.servicediscovery.plugin.SimpleMatchmakerQueryGracePeriod(in minutes, default is 2) specifies how long to wait before YP query errors should be logged at ERROR instead of DEBUG.

Nested Class Summary
 
Nested classes inherited from class org.cougaar.servicediscovery.plugin.SimpleMatchmakerPlugin
org.cougaar.servicediscovery.plugin.SimpleMatchmakerPlugin.QueryAlarm
 
Nested classes inherited from class org.cougaar.core.blackboard.BlackboardClient
org.cougaar.core.blackboard.BlackboardClient.Local
 
Field Summary
 
Fields inherited from class org.cougaar.core.blackboard.BlackboardClientComponent
agentId, agentIdentificationService, alarmService, blackboard, blackboardClientName
 
Fields inherited from interface org.cougaar.core.plugin.PluginBase
INSERTION_POINT
 
Fields inherited from interface org.cougaar.util.GenericStateModel
ACTIVE, IDLE, LOADED, UNINITIALIZED, UNLOADED
 
Fields inherited from interface org.cougaar.core.blackboard.BlackboardClient
current
 
Constructor Summary
MatchmakerPlugin()
           
 
Method Summary
protected  java.lang.String getServiceSchemeForRoles()
          Return the UDDI Service Scheme that contains the Roles we will look for.
 
Methods inherited from class org.cougaar.servicediscovery.plugin.SimpleMatchmakerPlugin
execute, getWarningCutoffTime, handleException, handleResponse, load, setRegistryQueryService, setupSubscriptions, unload
 
Methods inherited from class org.cougaar.core.plugin.ComponentPlugin
getConfigFinder
 
Methods inherited from class org.cougaar.core.blackboard.BlackboardClientComponent
currentTimeMillis, cycle, getAgentIdentifier, getAlarmService, getBindingSite, getBlackboardClientName, getBlackboardService, getMessageAddress, getParameter, getParameters, getServiceBroker, halt, precycle, requestCycle, resume, setAgentIdentificationService, setAlarmService, setBindingSite, setBlackboardService, setParameter, setSchedulerService, setServiceBroker, setSuicideService, shouldExecute, start, stop, suspend, toString, wasAwakened
 
Methods inherited from class org.cougaar.util.GenericStateModelAdapter
getModelState, initialize, transitState
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.cougaar.util.GenericStateModel
getModelState, halt, initialize, resume, start, stop, suspend
 

Constructor Detail

MatchmakerPlugin

public MatchmakerPlugin()
Method Detail

getServiceSchemeForRoles

protected java.lang.String getServiceSchemeForRoles()
Return the UDDI Service Scheme that contains the Roles we will look for. In this case, that is the Constants.UDDIConstants.COMMERCIAL_SERVICE_SCHEME.

This method is the only one we need to over-ride.

Returns:
UDDI Service Scheme to find Roles in