blob: 2a5e2a371d2d86f90e5bf9e2fc399309b027e9a3 (
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
|
package com.yahoo.container.jdisc.messagebus;
import com.yahoo.component.AbstractComponent;
import com.yahoo.component.annotation.Inject;
import com.yahoo.document.DocumentTypeManager;
import com.yahoo.documentapi.messagebus.protocol.DocumentProtocol;
import com.yahoo.messagebus.ConfigAgent;
import com.yahoo.messagebus.MessagebusConfig;
/**
* This Exists only to update a session cache with the latest and greatest config, across container generations.
* <p>
* There is currently no way to force that this precedes other users of the SessionCache, without also forcing their
* recreation when this is recreated, which is, again, the whole point of this component.
* If we end up using an incomplete SessionCache, there will be trouble. We would need an additional mechanism in
* the graph setup framework to solve this problem – something like {@code @Before/@After/@ImmediatelyAfter}.
*
* @author jonmv
*/
public class MbusConfigurator extends AbstractComponent {
@Inject
public MbusConfigurator(SessionCache cache, DocumentTypeManager manager, MessagebusConfig messagebusConfig) {
cache.configure(new DocumentProtocol(manager), messagebusConfig);
}
}
|