* @throws ServletException
* @throws KafkaConsumerCacheException
* @throws ConfigDbException
+ * @throws KeyExistsException
*/
@Autowired
public ConfigurationReader(@Qualifier("propertyReader") rrNvReadable settings,
*/
@Qualifier("dMaaPAuthenticatorImpl") DMaaPAuthenticator<NsaSimpleApiKey> fSecurityManager
)
- throws missingReqdSetting, invalidSettingValue, ServletException, KafkaConsumerCacheException, ConfigDbException {
+ throws missingReqdSetting, invalidSettingValue, ServletException, KafkaConsumerCacheException, ConfigDbException, KeyExistsException {
this.fMetrics = fMetrics;
this.zk = zk;
}
protected void servletSetup()
- throws rrNvReadable.missingReqdSetting, rrNvReadable.invalidSettingValue, ServletException, ConfigDbException {
+ throws rrNvReadable.missingReqdSetting, rrNvReadable.invalidSettingValue, ServletException, ConfigDbException, KeyExistsException {
try {
fMetrics.toJson();
if ( adminSecret != null && adminSecret.length () > 0 )
{
- try
- {
final NsaApiDb<NsaSimpleApiKey> adminDb = new BaseNsaApiDbImpl<NsaSimpleApiKey> ( new MemConfigDb(), new NsaSimpleApiKeyFactory() );
adminDb.createApiKey ( "admin", adminSecret );
- //nsaSecurityManager.addAuthenticator ( new OriginalUebAuthenticator<NsaSimpleApiKey> ( adminDb, 10*60*1000 ) );
+
fSecurityManager.addAuthenticator ( new DMaaPOriginalUebAuthenticator<NsaSimpleApiKey> ( adminDb, 10*60*1000 ) );
- }
- catch ( KeyExistsException e )
- {
- throw new RuntimeException ( "This key can't exist in a fresh in-memory DB!", e );
- }
}
// setup a backend
- //final String type = settings.getString(CambriaConstants.kBrokerType, CambriaConstants.kBrokerType_Kafka);
+
String type = com.att.ajsc.filemonitor.AJSCPropertiesMap.getProperty(CambriaConstants.msgRtr_prop,CambriaConstants.kBrokerType);
if (type==null) type = CambriaConstants.kBrokerType_Kafka;
if (CambriaConstants.kBrokerType_Kafka.equalsIgnoreCase(type)) {