Uploaded image for project: 'Codehaus Cargo'
  1. Codehaus Cargo
  2. CARGO-446

ConfigurationFactory and ConfigurationCapabilityFactory APIs should take a ContainerType as parameter

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8
    • Fix Version/s: 0.9
    • Component/s: Generic
    • Labels:
      None

      Description

      We need to allow the possibility to register a given configuration/configuration capability only for a given container. A container is uniquely identified by 2 parameters: id and type.

      Right now the APIs only takes the container id, which means that all current implementations must support all container types which is not right.

      Here's what the new API will look like:

      public interface ConfigurationFactory
      {
      void registerConfiguration(String containerId, ContainerType containerType,
      ConfigurationType configurationType, Class configurationClass);
      
      Class getConfigurationClass(String containerId, ContainerType containerType,
      ConfigurationType configurationType);
      
      boolean isConfigurationRegistered(String containerId, ContainerType containerType,
      ConfigurationType configurationType);
      
      Configuration createConfiguration(String containerId, ContainerType containerType,
      ConfigurationType configurationType);
      
      Configuration createConfiguration(String containerId, ContainerType containerType,
      ConfigurationType configurationType, String home);
      }
      

      And

      public interface ConfigurationCapabilityFactory
      {
      void registerConfigurationCapability(String containerId, ContainerType containerType,
      ConfigurationType configurationType, Class configurationCapabilityClass);
      
      ConfigurationCapability createConfigurationCapability(String containerId,
      ContainerType containerType, ConfigurationType configurationType);
      }
      

        Gliffy Diagrams

          Attachments

            Activity

            There are no comments yet on this issue.

              People

              • Assignee:
                vincentmassol Vincent Massol
                Reporter:
                vincentmassol Vincent Massol
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: