diff --git a/deployments/templates/openim.yaml b/deployments/templates/openim.yaml index 801c6bb50..ff2fa896d 100644 --- a/deployments/templates/openim.yaml +++ b/deployments/templates/openim.yaml @@ -314,189 +314,189 @@ iosPush: callback: url: "" beforeSendSingleMsg: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterSendSingleMsg: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeSendGroupMsg: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterSendGroupMsg: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} msgModify: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} userOnline: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} userOffline: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} userKickOff: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} offlinePush: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} onlinePush: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} superGroupOnlinePush: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeAddFriend: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeUpdateUserInfo: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeCreateGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterCreateGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeMemberJoinGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeSetGroupMemberInfo: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterSetGroupMemberInfo: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} setMessageReactionExtensions: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} quitGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} killGroupMember: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} dismissGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} joinGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} groupMsgRead: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} singleMsgRead: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} updateUserInfo: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeUserRegister: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterUserRegister: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} transferGroupOwner: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeSetFriendRemark: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterSetFriendRemark: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterGroupMsgRead: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterGroupMsgRevoke: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} afterJoinGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} beforeInviteUserToGroup: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} joinGroupAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} setGroupInfoAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} setGroupInfoBefore: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} revokeMsgAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} addBlackBefore: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} addFriendAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} addFriendAgreeBefore: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} deleteFriendAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} importFriendsBefore: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} importFriendsAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} removeBlackAfter: - enable: false - timeout: 5 - failedContinue: true + enable: ${CALLBACK_ENABLE} + timeout: ${CALLBACK_TIMEOUT} + failedContinue: ${CALLBACK_FAILED_CONTINUE} ###################### Prometheus ###################### # Prometheus configuration for various services # The number of Prometheus ports per service needs to correspond to rpcPort diff --git a/docs/contrib/environment.md b/docs/contrib/environment.md index 8de602d99..b82ec0f45 100644 --- a/docs/contrib/environment.md +++ b/docs/contrib/environment.md @@ -500,6 +500,9 @@ This section involves setting up additional configuration variables for Websocke | TOKEN_EXPIRE | "90" | Token Expiry Time | | FRIEND_VERIFY | "false" | Friend Verification Enable | | IOS_PUSH_SOUND | "xxx" | iOS | +| CALLBACK_ENABLE | "false" | Enable callback | +| CALLBACK_TIMEOUT | "5" | Maximum timeout for callback call | +| CALLBACK_FAILED_CONTINUE| "true" | fails to continue to the next step | ### 2.20. Prometheus Configuration This section involves configuring Prometheus, including enabling/disabling it and setting up ports for various services. diff --git a/scripts/install/environment.sh b/scripts/install/environment.sh index 6a87b44a6..b0fd1b65c 100755 --- a/scripts/install/environment.sh +++ b/scripts/install/environment.sh @@ -376,7 +376,10 @@ def "FRIEND_VERIFY" "false" # 朋友验证 def "IOS_PUSH_SOUND" "xxx" # IOS推送声音 def "IOS_BADGE_COUNT" "true" # IOS徽章计数 def "IOS_PRODUCTION" "false" # IOS生产 - +# callback 配置 +def "CALLBACK_ENABLE" "false" # 是否开启 Callback +def "CALLBACK_TIMEOUT" "5" # 最长超时时间 +def "CALLBACK_FAILED_CONTINUE" "true" # 失败后是否继续 ###################### Prometheus 配置信息 ###################### # 是否启用 Prometheus readonly PROMETHEUS_ENABLE=${PROMETHEUS_ENABLE:-'false'}