@Test public void missingMandatoryProfileFile() { expectedException.expect(ProfileConfException.class); expectedException.expectMessage("profile/missingMandatoryProfileFile/pxf-profiles-default.xml was not found in the CLASSPATH"); ProfilesConf profilesConf = getProfilesConf("missingMandatoryProfileFile"); profilesConf.getPlugins("HBase"); }
@Override public Map<String, String> getPlugins(String profileName) { Profile profile = getProfile(profileName); Map<String, String> result = profile.getPluginsMap(); if (result.isEmpty()) { throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, externalProfilesFilename); } return result; }
ProfilesConf implements PluginConf { @Override public Map<String, String> getPlugins(String profileName) { Profile profile = getProfile(profileName); Map<String, String> result = profile.getPluginsMap(); if (result.isEmpty()) { throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, externalProfilesFilename); } return result; } }
ProfilesConf implements PluginConf { @Override public Map<String, String> getPlugins(String profileName) { Profile profile = getProfile(profileName); Map<String, String> result = profile.getPluginsMap(); if (result.isEmpty()) { throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, externalProfilesFilename); } return result; } private  ProfilesConf();   ProfilesConf(String internalProfilesFilename, String externalProfilesFilename); }
ProfilesConf implements PluginConf { @Override public Map<String, String> getPlugins(String profileName) { Profile profile = getProfile(profileName); Map<String, String> result = profile.getPluginsMap(); if (result.isEmpty()) { throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, externalProfilesFilename); } return result; } private  ProfilesConf();   ProfilesConf(String internalProfilesFilename, String externalProfilesFilename); static ProfilesConf getInstance(); @Override Map<String, String> getOptionMappings(String profileName); @Override Map<String, String> getPlugins(String profileName); @Override String getProtocol(String profileName); @Override String getHandler(String profileName); }
ProfilesConf implements PluginConf { @Override public Map<String, String> getPlugins(String profileName) { Profile profile = getProfile(profileName); Map<String, String> result = profile.getPluginsMap(); if (result.isEmpty()) { throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, externalProfilesFilename); } return result; } private  ProfilesConf();   ProfilesConf(String internalProfilesFilename, String externalProfilesFilename); static ProfilesConf getInstance(); @Override Map<String, String> getOptionMappings(String profileName); @Override Map<String, String> getPlugins(String profileName); @Override String getProtocol(String profileName); @Override String getHandler(String profileName);  }