blob: 9f8880de7409545f8a584e1486b0683297405fa0 [file] [log] [blame]
Ray Milkey2d572dd2017-04-14 10:01:24 -07001/*
Brian O'Connora09fe5b2017-08-03 21:12:30 -07002 * Copyright 2016-present Open Networking Foundation
Ray Milkey2d572dd2017-04-14 10:01:24 -07003 *
Shravan Ambati1e8471e2016-07-13 14:03:17 -07004 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
Ray Milkey2d572dd2017-04-14 10:01:24 -07007 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
Shravan Ambati1e8471e2016-07-13 14:03:17 -070010 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package org.onosproject.kafkaintegration.api;
17
18import org.onosproject.kafkaintegration.api.dto.OnosEvent;
19
20/**
21 * APIs to insert and delete into a local store. This store is used to keep
22 * track of events that are being published.
23 */
24public interface KafkaEventStorageService {
25
26 /**
Shravan Ambatia4875d82017-01-09 13:06:51 -080027 * Inserts the Onos Event into Distributed Work Queue.
Shravan Ambati1e8471e2016-07-13 14:03:17 -070028 *
29 * @param e the ONOS Event
Shravan Ambati1e8471e2016-07-13 14:03:17 -070030 */
Shravan Ambatia4875d82017-01-09 13:06:51 -080031 void publishEvent(OnosEvent event);
Shravan Ambati1e8471e2016-07-13 14:03:17 -070032
33 /**
Shravan Ambatia4875d82017-01-09 13:06:51 -080034 * Removes the Onos Event from the Distributed Work Queue.
Shravan Ambati1e8471e2016-07-13 14:03:17 -070035 *
Shravan Ambatia4875d82017-01-09 13:06:51 -080036 * @return the Onos Event
Shravan Ambati1e8471e2016-07-13 14:03:17 -070037 */
Shravan Ambatia4875d82017-01-09 13:06:51 -080038 OnosEvent consumeEvent();
Shravan Ambati1e8471e2016-07-13 14:03:17 -070039}