aboutsummaryrefslogtreecommitdiffstats
path: root/documentapi/src/main/java/com/yahoo/documentapi/messagebus/MessageBusSession.java
blob: a1fb93ed07ce40787e360cca2bd1e4d226a7ad9b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.documentapi.messagebus;

/**
 * This class defines a common interface for message bus sessions.
 *
 * @author Simon Thoresen Hult
 */
public interface MessageBusSession {

    /**
     * Returns the route to send all messages to when sending through this session.
     *
     * @return The route string.
     */
    String getRoute();

    /**
     * Sets the route to send all messages to when sending through this session.
     *
     * @param route The route string.
     */
    void setRoute(String route);

    /**
     * Returns the trace level used when sending messages through this session.
     *
     * @return The trace level.
     */
    int getTraceLevel();

    /**
     * Sets the trace level used when sending messages through this session.
     *
     * @param traceLevel The trace level to set.
     */
    void setTraceLevel(int traceLevel);
}