code: protected void readParamsFromFile()
     {
        if (initParams != null)
        {
           nodeType =
              initParams.getValuesParam("nodetype") != null ? initParams.getValueParam("nodetype").getValue()
                 : DEFAULT_NODETYPE;
  
           ObjectParameter param = initParams.getObjectParam("observation.config");
           observationListenerConfiguration = (ObservationListenerConfiguration)param.getObject();
        }
        else
        {
           nodeType = DEFAULT_NODETYPE;
        }
  
        LOG.info("NodeType from configuration file: " + getNodeType());
        if (observationListenerConfiguration != null)
        {
           LOG.info("Repository name from configuration file: "
              + (observationListenerConfiguration.getRepository() != null ? observationListenerConfiguration
                 .getRepository() : "not configured, will be used the current one"));
  
           LOG.info("List of workspaces from configuration file: " + observationListenerConfiguration.getWorkspaces());
        }
     }
docs: Read parameters from file.