* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2020-2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
package org.onap.policy.drools.apps.controller.usecases;
-public class UsecasesConstants {
+import lombok.AccessLevel;
+import lombok.NoArgsConstructor;
+
+@NoArgsConstructor(access = AccessLevel.PRIVATE)
+public final class UsecasesConstants {
public static final String GET_TARGET_ENTITY_ACTOR = "pseudo/getTargetEntity";
public static final String GET_TARGET_ENTITY_OPERATION = "pseudo/getTargetEntity";
// additional properties that the Operations may need
public static final String AAI_DEFAULT_GENERIC_VNF = "AAI/default/genericVnf";
-
- private UsecasesConstants() {
- super();
- }
}
package org.onap.policy.controlloop.eventmanager;
-public class ActorConstants {
+import lombok.AccessLevel;
+import lombok.NoArgsConstructor;
+
+@NoArgsConstructor(access = AccessLevel.PRIVATE)
+public final class ActorConstants {
public static final String CL_TIMEOUT_ACTOR = "-CL-TIMEOUT-";
public static final String LOCK_ACTOR = "LOCK";
public static final String LOCK_OPERATION = "Lock";
public static final String UNLOCK_OPERATION = "Unlock";
public static final String PAYLOAD_KEY_VF_COUNT = "vfCount";
-
-
- private ActorConstants() {
- // do nothing
- }
}
/*-
* ============LICENSE_START=======================================================
- * Copyright (C) 2019-2020 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2019-2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
package org.onap.policy.controlloop.utils;
+import lombok.AccessLevel;
+import lombok.NoArgsConstructor;
import org.onap.policy.controlloop.ControlLoopException;
import org.onap.policy.controlloop.drl.legacy.ControlLoopParams;
import org.onap.policy.controlloop.processor.ControlLoopProcessor;
/**
* Control Loop Utils.
*/
-public class ControlLoopUtils {
+@NoArgsConstructor(access = AccessLevel.PRIVATE)
+public final class ControlLoopUtils {
public static final Logger logger = LoggerFactory.getLogger(ControlLoopUtils.class);
- private ControlLoopUtils() {
- super();
- }
-
/**
* Get a Control Loop Parameters object from a Tosca Policy.
*/
import java.util.Objects;
import java.util.UUID;
import java.util.concurrent.TimeUnit;
+import lombok.Getter;
+import lombok.Setter;
import org.apache.commons.collections4.CollectionUtils;
import org.onap.policy.controlloop.ControlLoopNotificationType;
import org.onap.policy.controlloop.ControlLoopOperation;
private static final Logger logger = LoggerFactory.getLogger(CacheBasedControlLoopMetricsManager.class);
private LoadingCache<UUID, VirtualControlLoopNotification> cache;
+
+ @Getter
private long cacheSize = ControlLoopMetricsFeature.CL_CACHE_TRANS_SIZE_DEFAULT;
+ @Getter
+ @Setter
private long transactionTimeout = ControlLoopMetricsFeature.CL_CACHE_TRANS_TIMEOUT_SECONDS_DEFAULT;
/**
.setResponseDescription("EVICTED").setStatusCode(false).metric().resetTransaction();
}
- @Override
- public long getCacheSize() {
- return this.cacheSize;
- }
-
@Override
public void setMaxCacheSize(long cacheSize) {
this.cacheSize = cacheSize;
}
- @Override
- public long getTransactionTimeout() {
- return this.transactionTimeout;
- }
-
- @Override
- public void setTransactionTimeout(long transactionTimeout) {
- this.transactionTimeout = transactionTimeout;
- }
-
@Override
public long getCacheOccupancy() {
return this.cache.size();
* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2019, 2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
package org.onap.policy.drools.apps.controlloop.feature.trans;
+import lombok.AccessLevel;
import lombok.Getter;
+import lombok.NoArgsConstructor;
/**
* Control Loop Metrics Tracker.
*/
+@NoArgsConstructor(access = AccessLevel.PRIVATE)
public class ControlLoopMetricsManager {
/**
*/
@Getter
private static final ControlLoopMetrics manager = new CacheBasedControlLoopMetricsManager();
-
- private ControlLoopMetricsManager() {
- // do nothing
- }
}
* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2020-2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
*/
public class HttpClients {
- /**
- * Constructs the object.
- */
- public HttpClients() {
- super();
- }
-
-
/**
* Adds Http Clients specified in the property file.
*
* ============LICENSE_START=======================================================
* ONAP
* ================================================================================
- * Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
+ * Copyright (C) 2020-2021 AT&T Intellectual Property. All rights reserved.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@Getter(AccessLevel.PROTECTED)
private final List<HttpServletServer> servers = new LinkedList<>();
- /**
- * Constructs the object.
- */
- public Simulators() {
- super();
- }
-
/**
* Invokes the given functions to start the simulators. Destroys <i>all</i> of the
* simulators if any fail to start.
*/
private final List<Listener<?>> listeners = new LinkedList<>();
-
- /**
- * Constructs the object.
- */
- public Topics() {
- super();
- }
-
/**
* Unregisters all of the listeners.
*/