mirror of
				https://github.com/openimsdk/open-im-server.git
				synced 2025-10-31 08:29:33 +08:00 
			
		
		
		
	* fix: GroupApplicationAcceptedNotification * fix: GroupApplicationAcceptedNotification * fix: NotificationUserInfoUpdate * cicd: robot automated Change * fix: component * fix: getConversationInfo * feat: cron task * feat: cron task * feat: cron task * feat: cron task * feat: cron task * fix: minio config url recognition error * update gomake version * update gomake version * fix: seq conversion bug * fix: redis pipe exec * fix: ImportFriends * fix: A large number of logs keysAndValues length is not even * feat: mark read aggregate write * feat: online status supports redis cluster * feat: online status supports redis cluster * feat: online status supports redis cluster * merge * merge * read seq is written to mongo * read seq is written to mongo * fix: invitation to join group notification * fix: friend op_user_id * feat: optimizing asynchronous context * feat: optimizing memamq size * feat: add GetSeqMessage * feat: GroupApplicationAgreeMemberEnterNotification * feat: GroupApplicationAgreeMemberEnterNotification * feat: go.mod * feat: go.mod * feat: join group notification and get seq --------- Co-authored-by: withchao <withchao@users.noreply.github.com>
		
			
				
	
	
		
			64 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			64 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			Go
		
	
	
	
	
	
| // Copyright © 2023 OpenIM. All rights reserved.
 | |
| //
 | |
| // 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 msggateway
 | |
| 
 | |
| import "time"
 | |
| 
 | |
| const (
 | |
| 	WsUserID                = "sendID"
 | |
| 	CommonUserID            = "userID"
 | |
| 	PlatformID              = "platformID"
 | |
| 	ConnID                  = "connID"
 | |
| 	Token                   = "token"
 | |
| 	OperationID             = "operationID"
 | |
| 	Compression             = "compression"
 | |
| 	GzipCompressionProtocol = "gzip"
 | |
| 	BackgroundStatus        = "isBackground"
 | |
| 	SendResponse            = "isMsgResp"
 | |
| )
 | |
| 
 | |
| const (
 | |
| 	WebSocket = iota + 1
 | |
| )
 | |
| 
 | |
| const (
 | |
| 	// Websocket Protocol.
 | |
| 	WSGetNewestSeq        = 1001
 | |
| 	WSPullMsgBySeqList    = 1002
 | |
| 	WSSendMsg             = 1003
 | |
| 	WSSendSignalMsg       = 1004
 | |
| 	WSPullMsg             = 1005
 | |
| 	WSPushMsg             = 2001
 | |
| 	WSKickOnlineMsg       = 2002
 | |
| 	WsLogoutMsg           = 2003
 | |
| 	WsSetBackgroundStatus = 2004
 | |
| 	WsSubUserOnlineStatus = 2005
 | |
| 	WSDataError           = 3001
 | |
| )
 | |
| 
 | |
| const (
 | |
| 	// Time allowed to write a message to the peer.
 | |
| 	writeWait = 10 * time.Second
 | |
| 
 | |
| 	// Time allowed to read the next pong message from the peer.
 | |
| 	pongWait = 30 * time.Second
 | |
| 
 | |
| 	// Send pings to peer with this period. Must be less than pongWait.
 | |
| 	pingPeriod = (pongWait * 9) / 10
 | |
| 
 | |
| 	// Maximum message size allowed from peer.
 | |
| 	maxMessageSize = 51200
 | |
| )
 |