ing
This commit is contained in:
parent
1d03d268d5
commit
53770b8c63
|
@ -9,5 +9,6 @@ public interface MessagePublisher {
|
|||
void publishToMember(final String memberID, final String method, final Object... params);
|
||||
void publishToMemberSession(final String memberSessionID, final String method, final Object... params);
|
||||
|
||||
void publishToNoAuthProbe(final String tempProbeKey, final String method, final Object... params);
|
||||
void publishToProbe(final String probeKey, final String method, final Object... params);
|
||||
}
|
||||
|
|
|
@ -19,6 +19,7 @@ import java.util.Map;
|
|||
@Service
|
||||
public class RedisMessagePublisher implements MessagePublisher {
|
||||
private static final String CHANNEL_WEBAPP = "/webapp";
|
||||
private static final String CHANNEL_NOAUTH_PROBE = "/auth";
|
||||
private static final String CHANNEL_PROBE = "/probe";
|
||||
|
||||
@Autowired
|
||||
|
@ -64,6 +65,13 @@ public class RedisMessagePublisher implements MessagePublisher {
|
|||
this.publish(CHANNEL_WEBAPP, message, method, params);
|
||||
}
|
||||
|
||||
public void publishToNoAuthProbe(final String tempProbeKey, final String method, final Object... params) {
|
||||
PublishMessage message = new PublishMessage();
|
||||
message.setTargetType(PublishMessage.TargetType.PROBE);
|
||||
message.addTarget(tempProbeKey);
|
||||
this.publish(CHANNEL_NOAUTH_PROBE, message, method, params);
|
||||
}
|
||||
|
||||
public void publishToProbe(final String probeKey, final String method, final Object... params) {
|
||||
PublishMessage message = new PublishMessage();
|
||||
message.setTargetType(PublishMessage.TargetType.PROBE);
|
||||
|
|
Loading…
Reference in New Issue
Block a user