12 changed files with 223 additions and 37 deletions
-
2.gitignore
-
5src/main/java/com/corundumstudio/socketio/HandshakeData.java
-
7src/main/java/com/corundumstudio/socketio/SocketIOChannelInitializer.java
-
53src/main/java/com/corundumstudio/socketio/handler/AuthorizeHandler.java
-
2src/main/java/com/corundumstudio/socketio/store/RedisPubSubStore.java
-
5src/main/java/com/corundumstudio/socketio/store/RedisStoreFactory.java
-
3src/main/java/com/corundumstudio/socketio/store/StoreFactory.java
-
62src/main/java/com/corundumstudio/socketio/store/pubsub/BaseStoreFactory.java
-
38src/main/java/com/corundumstudio/socketio/store/pubsub/ConnectMessage.java
-
38src/main/java/com/corundumstudio/socketio/store/pubsub/DisconnectMessage.java
-
38src/main/java/com/corundumstudio/socketio/store/pubsub/HandshakeMessage.java
-
7src/main/java/com/corundumstudio/socketio/store/pubsub/PubSubStore.java
@ -0,0 +1,38 @@ |
|||
/** |
|||
* Copyright 2012 Nikita Koksharov |
|||
* |
|||
* Licensed under the Apache License, Version 2.0 (the "License"); |
|||
* you may not use this file except in compliance with the License. |
|||
* You may obtain a copy of the License at |
|||
* |
|||
* http://www.apache.org/licenses/LICENSE-2.0 |
|||
* |
|||
* Unless required by applicable law or agreed to in writing, software |
|||
* distributed under the License is distributed on an "AS IS" BASIS, |
|||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|||
* See the License for the specific language governing permissions and |
|||
* limitations under the License. |
|||
*/ |
|||
package com.corundumstudio.socketio.store.pubsub; |
|||
|
|||
import java.util.UUID; |
|||
|
|||
public class ConnectMessage extends PubSubMessage { |
|||
|
|||
private static final long serialVersionUID = 3108918714495865101L; |
|||
|
|||
private UUID sessionId; |
|||
|
|||
public ConnectMessage() { |
|||
} |
|||
|
|||
public ConnectMessage(UUID sessionId) { |
|||
super(); |
|||
this.sessionId = sessionId; |
|||
} |
|||
|
|||
public UUID getSessionId() { |
|||
return sessionId; |
|||
} |
|||
|
|||
} |
@ -0,0 +1,38 @@ |
|||
/** |
|||
* Copyright 2012 Nikita Koksharov |
|||
* |
|||
* Licensed under the Apache License, Version 2.0 (the "License"); |
|||
* you may not use this file except in compliance with the License. |
|||
* You may obtain a copy of the License at |
|||
* |
|||
* http://www.apache.org/licenses/LICENSE-2.0 |
|||
* |
|||
* Unless required by applicable law or agreed to in writing, software |
|||
* distributed under the License is distributed on an "AS IS" BASIS, |
|||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|||
* See the License for the specific language governing permissions and |
|||
* limitations under the License. |
|||
*/ |
|||
package com.corundumstudio.socketio.store.pubsub; |
|||
|
|||
import java.util.UUID; |
|||
|
|||
public class DisconnectMessage extends PubSubMessage { |
|||
|
|||
private static final long serialVersionUID = -2763553673397520368L; |
|||
|
|||
private UUID sessionId; |
|||
|
|||
public DisconnectMessage() { |
|||
} |
|||
|
|||
public DisconnectMessage(UUID sessionId) { |
|||
super(); |
|||
this.sessionId = sessionId; |
|||
} |
|||
|
|||
public UUID getSessionId() { |
|||
return sessionId; |
|||
} |
|||
|
|||
} |
@ -0,0 +1,38 @@ |
|||
/** |
|||
* Copyright 2012 Nikita Koksharov |
|||
* |
|||
* Licensed under the Apache License, Version 2.0 (the "License"); |
|||
* you may not use this file except in compliance with the License. |
|||
* You may obtain a copy of the License at |
|||
* |
|||
* http://www.apache.org/licenses/LICENSE-2.0 |
|||
* |
|||
* Unless required by applicable law or agreed to in writing, software |
|||
* distributed under the License is distributed on an "AS IS" BASIS, |
|||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
|||
* See the License for the specific language governing permissions and |
|||
* limitations under the License. |
|||
*/ |
|||
package com.corundumstudio.socketio.store.pubsub; |
|||
|
|||
import java.util.UUID; |
|||
|
|||
public class HandshakeMessage extends PubSubMessage { |
|||
|
|||
private static final long serialVersionUID = 5767127795325210150L; |
|||
|
|||
private UUID sessionId; |
|||
|
|||
public HandshakeMessage() { |
|||
} |
|||
|
|||
public HandshakeMessage(UUID sessionId) { |
|||
super(); |
|||
this.sessionId = sessionId; |
|||
} |
|||
|
|||
public UUID getSessionId() { |
|||
return sessionId; |
|||
} |
|||
|
|||
} |
Write
Preview
Loading…
Cancel
Save
Reference in new issue