Game server updating method and device, and storage medium
By using automated message interaction components and task robots, combined with the trust relationship between the jump server and the Erlang game server, efficient updates of the game server are achieved, solving the problems of complexity and time-consuming manual operation in existing technologies, improving update efficiency and reducing costs.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- XIAMEN WOOBEST INTERACTIVE NETWORK TECH CO LTD
- Filing Date
- 2022-08-15
- Publication Date
- 2026-05-15
AI Technical Summary
Current hot updates for game servers rely on manual operation, which is difficult, complex, and time-consuming, resulting in low update efficiency.
By acquiring message interaction components generated from user needs, creating Jenkins tasks using task robots, and combining the trust relationship between the jump server and the Erlang game server, the update script is executed automatically, achieving automated hot updates of the Erlang server.
It saves server update operation time, reduces labor costs, improves the efficiency of game server updates, and enables real-time acquisition of update progress.
Smart Images

Figure CN115344294B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, and in particular to a method, apparatus and storage medium for updating a game server. Background Technology
[0002] In game operation, upgrading and updating game servers is a crucial aspect. Using hot updates for game servers can shorten the time it takes for users to obtain the latest client version and improve the user experience.
[0003] Existing hot updates for game servers typically involve the following steps: pulling the code repository, compiling and packaging, uploading the update file, downloading the update file to the game server, triggering the Erlang server hot update, and detecting the Erlang server hot update result. Current hot update technologies suffer from the following problems: Firstly, deploying server-side hot updates relies on manual operation by developers, requiring specialized personnel, resulting in a high barrier to entry, complex steps, and high time costs. Secondly, only one package can be built at a time during the compilation and packaging process, consuming significant time.
[0004] Therefore, there is an urgent need for a more efficient and lower-cost method for updating game servers.
[0005] It should be noted that the information disclosed in the background section above is only used to enhance the understanding of the background of this disclosure, and therefore may include information that does not constitute prior art known to those skilled in the art. Summary of the Invention
[0006] The purpose of this disclosure is to provide a game server update method, apparatus, and storage medium, which at least to some extent overcomes the problem of low game server update efficiency due to related technologies.
[0007] Other features and advantages of this disclosure will become apparent from the following detailed description, or may be learned in part from practice of this disclosure.
[0008] According to one aspect of this disclosure, a game server update method is provided, applied to a device terminal, comprising:
[0009] Obtain message interaction components generated based on user needs;
[0010] Receive user actions on the message interaction component and generate server update commands;
[0011] Create a Jenkins task via the task bot based on the server update command;
[0012] The update script is invoked based on the parameter data of the message interaction component;
[0013] The update script is executed via the Jenkins task, uploading the update file to the jump server. The jump server then uploads the update file to the Erlang game server, which performs an update based on the update file. The jump server and the Erlang game server have a pre-established trust relationship.
[0014] The update script sends the update progress of the Erlang game server to a webhook address, wherein the webhook address is generated by the task bot and is pre-configured in the update script.
[0015] In one embodiment of this disclosure, obtaining the message interaction component generated based on user needs includes:
[0016] Obtain the style code corresponding to the interface style of the message interaction component based on user needs;
[0017] Send the style code to the message group;
[0018] The message interaction component interface is displayed in the message group.
[0019] In one embodiment of this disclosure, receiving a user operation on the message interaction component and generating a server update command includes:
[0020] The message interaction component interface is used to receive user operations and determine the server update method.
[0021] The server update command is generated based on the parameter data of the message interaction component corresponding to the server update method.
[0022] In one embodiment of this disclosure, creating a Jenkins task via a task bot based on the server update command includes:
[0023] Receive user operation feedback from the message interaction component through message groups;
[0024] After the task robot monitors the user's operation feedback, it invokes the task robot's code information.
[0025] Create a Jenkins task based on the code information.
[0026] In one embodiment of this disclosure, the jump server and the Erlang game server pre-establish a Secure Shell Protocol (SSH) trust relationship, and execute the rsync command of the Erlang game server to synchronize the update file to the Erlang game server.
[0027] According to another aspect of this disclosure, a game server update method is provided, applied to an Erlang server, comprising:
[0028] Establish a trust relationship with the scaffolding machine;
[0029] The update file is obtained through the jump server. The update file is generated after the device terminal receives the message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through the task robot according to the server update command, calls the update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update file to the jump server, and then the jump server uploads it to the Erlang game server.
[0030] Update the Erlang game server according to the update file;
[0031] The corresponding Erlang game server interface is called through the pre-configured Erlang server management node;
[0032] The Erlang game server is notified to check the version file via the interface.
[0033] If an older version of the file exists, delete the older version file.
[0034] In one embodiment of this disclosure, the method further includes:
[0035] The Erlang server management node calls the Erlang game server to verify the beam file in the directory;
[0036] Determine whether the MD5 value of the beam file matches that of the memory beam module;
[0037] If they match, then the Erlang game server update is successful.
[0038] According to another aspect of this disclosure, a game server update apparatus is provided, comprising:
[0039] The component acquisition module is used to acquire message interaction components generated based on user needs.
[0040] The command generation module is used to receive user operations on the message interaction component and generate server update commands;
[0041] The task creation module is used to create Jenkins tasks via a task robot based on the server update command.
[0042] The script invocation module is used to invoke the update script based on the parameter data of the message interaction component;
[0043] A script execution module is used to execute the update script via the Jenkins task, uploading the update file to the jump server, so that the jump server uploads the update file to the Erlang game server, and the Erlang game server updates according to the update file. The jump server and the Erlang game server have a pre-established trust relationship.
[0044] The progress acquisition module is used to send the update progress of the Erlang game server to the webhook address through the update script. The webhook address is generated by the task robot and is pre-configured in the update script.
[0045] According to another aspect of this disclosure, a game server update apparatus is provided, comprising:
[0046] The trust establishment module is used to establish a trust relationship with the jump server;
[0047] The file acquisition module is used to acquire update files through the jump server. The update files are generated after the device terminal receives a message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through a task robot according to the server update command, calls an update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update files to the jump server, which then uploads them to the Erlang game server.
[0048] The version update module is used to update the Erlang game server according to the update file.
[0049] The interface call module is used to call the corresponding Erlang game server's interface through the pre-configured Erlang server management node;
[0050] The version check module is used to notify the Erlang game server to check the version file through the interface;
[0051] The old version deletion module is used to delete the old version file when an old version of the current version file exists.
[0052] According to another aspect of this disclosure, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the game server update method described above.
[0053] This disclosure provides a game server update method applied to a device terminal. First, it obtains a message interaction component generated based on user needs; receives user operations on the message interaction component and generates a server update command; creates a Jenkins task via a task robot according to the server update command; calls an update script based on parameter data from the message interaction component; executes the update script through the Jenkins task, uploading the update file to a jump server, so that the jump server uploads the update file to the Erlang game server, and the Erlang game server updates according to the update file. The jump server and the Erlang game server have a pre-established trust relationship; and the update script sends the update progress of the Erlang game server to a webhook address, where the webhook address is generated by the task robot and pre-configured in the update script. This achieves automated hot updates of the Erlang server, saving server update operation time, reducing labor costs, and improving the efficiency of game server updates.
[0054] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0055] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure. It is obvious that the drawings described below are merely some embodiments of this disclosure, and those skilled in the art can obtain other drawings based on these drawings without any inventive effort.
[0056] Figure 1 This diagram illustrates a flowchart of a game server update method according to one embodiment of the present disclosure;
[0057] Figure 2 This diagram illustrates a flowchart of a game server update method according to yet another embodiment of this disclosure;
[0058] Figure 3 This diagram illustrates a flowchart of a game server update method according to another embodiment of the present disclosure;
[0059] Figure 4 This diagram illustrates the structure of a game server update method according to one embodiment of the present disclosure.
[0060] Figure 5 This diagram illustrates a flowchart of a game server update method in another embodiment of the present disclosure;
[0061] Figure 6This diagram illustrates the structure of a game server update method according to yet another embodiment of the present disclosure.
[0062] Figure 7 A flowchart illustrating the judgment process of a game server update method in one embodiment of this disclosure is shown.
[0063] Figure 8 This diagram illustrates a game server update apparatus according to one embodiment of the present disclosure; and
[0064] Figure 9 A schematic diagram of a game server update device is shown in yet another embodiment of this disclosure. Detailed Implementation
[0065] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided so that this disclosure will be more comprehensive and complete, and will fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0066] Furthermore, the accompanying drawings are merely illustrative of this disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and therefore repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.
[0067] The solution provided in this application relates to game server update technology, which is specifically illustrated through the following embodiments:
[0068] like Figure 1 The illustrated flowchart of the game server update method, in one embodiment of this disclosure, provides a game server update method applied to a device terminal, including:
[0069] S101, Obtain the message interaction component generated based on user needs;
[0070] Specifically, on the device terminal of this embodiment, a message interaction component is first obtained according to the user's needs. This component displays an interactive interface to the user and receives simple interactions from the user. The content and display style of the message interaction component can be set according to the user's actual business needs, thereby obtaining a message interaction component corresponding to the application scenario. Optionally, the message interaction component provided in this embodiment can be a message card from the Lark application platform. A message card is a message type that can carry rich text and image content and interactive behaviors.
[0071] S102, Receive user operation on the message interaction component and generate server update command;
[0072] The server update commands can include: package and hot update, package only, hot update only, and rollback update.
[0073] In this embodiment, the server update command can be determined based on the received user operation. That is, the server update method can be customized, and the parameters of the message interaction component can be converted into corresponding commands. The command format is: hotupdate / pack / update_version / roll_back china release-1. The meanings of the command operations are as follows: hotupdate means packaging and hot update, pack means packaging only, update_version means hot update only, roll_back means rollback update, china means China server, release means the released version, and -1 means the released version number is automatically incremented.
[0074] S103, Create a Jenkins task via the task robot according to the server update command;
[0075] Specifically, after receiving the server update command, a Jenkins task is created via a task bot, which then executes the subsequent processing tasks. In this embodiment, the task bot can be Lark. The specific creation method involves logging into the Jenkins backend using the python-jenkins third-party library and creating a Jenkins task. Jenkins is a continuous integration tool developed based on Java, used to monitor repetitive tasks. It provides an open and easy-to-use software platform that enables continuous integration of software projects.
[0076] S104, Invoke the update script based on the parameter data of the message interaction component;
[0077] Optionally, this embodiment uses a batch file (.bat) to write an update script for the game server packaging machine. The update script is stored in the server packaging machine, and a Jenkins task remotely calls the update script. The update script contains a series of automated processes. Through the script, the Jenkins task can be controlled to perform operations such as pulling the code repository, compiling and packaging, uploading update files, remotely calling the game server to download update files, triggering Erlang server hot updates, and Erlang server hot update result detection. Automating the packaging and update script can save labor costs, save server update operation time, and lower the threshold for using server updates, making it simpler and easier to implement.
[0078] S105, the update script is executed through the Jenkins task to upload the update file to the jump server, so that the jump server uploads the update file to the Erlang game server, and the Erlang game server updates according to the update file. The jump server and the Erlang game server have a pre-established trust relationship.
[0079] Specifically, a Jenkins task remotely executes the update script on the server-side packaging machine. This update script encompasses a series of automated processing steps. The Jenkins task is responsible for pulling the code repository, compiling and packaging, and uploading the update files. The update files are first uploaded to a jump server; in this embodiment, a Linux jump server is optionally used. Since the jump server has a pre-established trust relationship with the Erlang game server, the update files are then uploaded to the Erlang game server via the jump server, allowing the Erlang game server to obtain the update files and perform a hot update.
[0080] S106, The update progress of the Erlang game server is sent to the webhook address through the update script, wherein the webhook address is generated by the task robot and the webhook address is pre-configured in the update script.
[0081] Specifically, taking the Lark platform as an example, the webhook address is generated by the Lark robot and stored in the update script. When the update script is executed, the game server's update progress is sent to the webhook address. This enables real-time synchronization of hot update progress via the webhook address provided by the task robot, and sends the packaging progress to the Lark group. Real-time push notifications of the Erlang game server's update progress can be achieved by configuring the webhook address provided by the Lark robot in the update script.
[0082] This disclosure provides a game server update method applied to a device terminal. First, a message interaction component generated based on user needs is obtained; user operations on the message interaction component are received, and a server update command is generated; a Jenkins task is created via a task robot according to the server update command; an update script is generated based on parameter data from the message interaction component; the update script is executed via the Jenkins task, uploading the update file to a jump server, which then uploads the update file to an Erlang game server. The Erlang game server updates according to the update file, wherein the jump server and the Erlang game server have a pre-established trust relationship; and the update progress of the Erlang game server is sent to a webhook address via the update script, wherein the webhook address is generated by the task robot and pre-configured in the update script. This method achieves automated hot updates of the Erlang server, saving server update operation time, reducing labor costs, and improving the efficiency of game server updates. It also enables real-time acquisition of the game server update progress.
[0083] like Figure 2 The diagram illustrates a game server update method. In this embodiment, obtaining the message interaction component generated based on user needs includes:
[0084] S201, Obtain the style code corresponding to the interface style of the message interaction component based on user needs;
[0085] S202, the style code is sent to the message group;
[0086] S203, Display the message interaction component interface in the message group.
[0087] Specifically, taking the Lark platform as an example in this embodiment, users can set the message cards in advance according to the actual operation needs, obtain the corresponding style code according to the interface style required by the user, and then send the style code to the Lark group through the Lark interface. The effect interface of the Lark message card can be displayed in the Lark group.
[0088] By providing a visual panel through the message interaction component interface, the operational threshold for R&D personnel can be lowered, providing an operable interface that is simpler, more efficient, and reduces the error rate.
[0089] In this embodiment of the disclosure, receiving user operations on the message interaction component and generating a server update command includes: receiving user operations through the message interaction component interface, determining the server update method, and generating the server update command based on the parameter data of the message interaction component corresponding to the server update method.
[0090] Specifically, server update methods can include: packaged and hot update, packaged only, hot update only, and rollback update. The corresponding server update commands correspond one-to-one with each of these update methods. When a user selects a server update method, the message interaction component contains the corresponding parameter data, which is then converted into the appropriate server update command, with the command format as described above.
[0091] like Figure 3 The diagram illustrates a game server update method. In this embodiment, the step of creating a Jenkins task via a task bot based on the server update command includes:
[0092] S301, Receive user operation feedback from the message interaction component through the message group;
[0093] S302, after the task robot monitors the user's operation feedback, it calls the code information of the task robot;
[0094] S303, Create a Jenkins task based on the code information.
[0095] Specifically, taking the Lark platform as an example, after a Lark card receives a user's action, it will generate user feedback and send a command in the Lark group. When the Lark robot detects this command, it will call its relevant code information and then use the python-jenkins third-party library to log in to the Jenkins backend to create a task. This embodiment creates a Jenkins task so that the Jenkins task can subsequently execute various processing tasks.
[0096] In this embodiment of the disclosure, the jump server and the Erlang game server establish a Secure Shell Protocol (SSH) trust relationship in advance, and execute the rsync command of the Erlang game server to synchronize the update file to the Erlang game server.
[0097] Specifically, such as Figure 4The diagram illustrates a structural approach for updating a game server, comprising a device terminal 410, a jump server 420, and an Erlang game server 430. Device terminal 410 uploads the update file to jump server 420, which then synchronizes the update file to Erlang game server 430. The SSH (Secure Shell) trust relationship refers to a user on a server trusting a user on a client, allowing that user to log in without a password; this is also known as public_key_auth, essentially certificate trust. The rsync command is a remote data synchronization tool that can quickly synchronize files between multiple hosts. It uses the rsync algorithm to synchronize files between local and remote hosts, transmitting only the different parts of the files instead of the entire file each time, resulting in significant speed. This embodiment sets up a Linux jump server, establishes an SSH trust relationship between the jump server and the game server, and remotely executes the rsync command on the game server via the jump server to download the update file to the game server. Using a jump server allows for more efficient and faster file uploads to the Erlang game server, while also improving security.
[0098] like Figure 5 The diagram illustrates a game server update method. In another embodiment of this disclosure, a game server update method is provided, applied to an Erlang server, comprising:
[0099] S501 establishes a trust relationship with the scaffolding machine;
[0100] Specifically, the Erlang game server establishes an SSH trust relationship with the jump server so that the game server's rsync command can be executed remotely via the jump server to download update files to the game server.
[0101] S502, the update file is obtained through the jump server. The update file is generated after the device terminal obtains the message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through the task robot according to the server update command, generates an update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update file to the jump server, which then uploads it to the Erlang game server.
[0102] The game server's rsync command is executed remotely via a jump server to download the update file to the game server. The update file is generated on the terminal as described in the above embodiment.
[0103] S503, Update the Erlang game server according to the update file;
[0104] Implement hot updates on the Erlang game server.
[0105] S504 calls the corresponding Erlang game server interface through a pre-configured Erlang server management node;
[0106] Pre-set up an Erlang server management node, and enable the same cookie for the server node, such as... Figure 6 The diagram illustrates the structure of the server management node and the game server, establishing a connection between the Erlang server management node 610 and the Erlang game server 620. The number of Erlang game servers is determined based on the actual application scenario, allowing remote calls to the API of any Erlang game server. Secure calls to the Erlang game server are achieved by setting the same cookie.
[0107] S505, The Erlang game server is notified to check the version file through the interface;
[0108] Specifically, in this embodiment, the Erlang server management node is used to notify the Erlang game server to check for differences in version files.
[0109] S506, If an older version of the file exists, delete the older version file.
[0110] Then, when an older version is discovered, the `code:soft_purge` interface in the Erlang standard library is used to remove these older version files, thus achieving a hot update effect for the Erlang game server.
[0111] The game server update method provided in this embodiment establishes a trust relationship with a jump server on the Erlang server side, corresponding to the above embodiment. It obtains the update file through the jump server and then updates the Erlang game server according to the update file. The method involves calling the corresponding Erlang game server interface through a pre-configured Erlang server management node, notifying the Erlang game server to check the version file through the interface, and deleting the old version file if an old version exists. This achieves hot updates for the game server, significantly improving the efficiency of hot updates and reducing the consumption of manpower and resources.
[0112] like Figure 7 The diagram illustrates a judgment process for a game server update method. In this embodiment of the disclosure, the method further includes:
[0113] S701, the Erlang server management node calls the Erlang game server to verify the beam file in the directory;
[0114] S702, determine whether the MD5 value of the beam file is consistent with that of the memory beam module;
[0115] S703, if consistent, then the Erlang game server update is successful.
[0116] Specifically, the Erlang server management node notifies the Erlang game server to verify whether the MD5 hash of the beam file in the directory matches that of the memory beam module, thus verifying the hot update result. Each file has a unique MD5 value, which is generally used to compare whether two files are the same. If the MD5 values are different, the two files are considered different. When the MD5 values match, the hot update of the game server is verified as successful. (See attached...) Figure 7 If there is no consistency in step S704, it is determined that the Erlang game server update has failed. Appropriate measures can be taken, such as attempting to update again.
[0117] In yet another embodiment of this disclosure, a game server update device 800 is provided, comprising:
[0118] The component acquisition module 801 is used to acquire message interaction components generated based on user needs;
[0119] Command generation module 802 is used to receive user operations on the message interaction component and generate server update commands;
[0120] Task creation module 803 is used to create Jenkins tasks via a task robot based on the server update command;
[0121] The script invocation module 804 is used to invoke the update script based on the parameter data of the message interaction component;
[0122] Script execution module 805 is used to execute the update script through the Jenkins task, upload the update file to the jump server, so that the jump server uploads the update file to the Erlang game server, and the Erlang game server updates according to the update file, wherein the jump server and the Erlang game server have a pre-established trust relationship; and
[0123] The progress acquisition module 806 is used to send the update progress of the Erlang game server to the webhook address through the update script, wherein the webhook address is generated by the task robot and the webhook address is pre-configured in the update script.
[0124] The game server update device 800 provided in this embodiment includes a component acquisition module 801, a command generation module 802, a task creation module 803, a script calling module 804, a script execution module 805, and a progress acquisition module 806. It can realize automated hot updates of Erlang servers, saving server update operation time, reducing labor costs, and improving the efficiency of game server updates. Furthermore, it enables real-time acquisition of the game server update progress.
[0125] In another embodiment of this disclosure, a game server update device 900 is provided, comprising:
[0126] Trust establishment module 901 is used to establish a trust relationship with the jump server;
[0127] The file acquisition module 902 is used to acquire update files through the jump server. The update files are generated after the device terminal acquires a message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through a task robot according to the server update command, calls an update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update files to the jump server, which then uploads them to the Erlang game server.
[0128] Version update module 903 is used to update the Erlang game server according to the update file;
[0129] Interface call module 904 is used to call the interface of the corresponding Erlang game server through the pre-configured Erlang server management node;
[0130] Version checking module 905 is used to notify the Erlang game server to check the version file through the interface;
[0131] The old version deletion module 906 is used to delete the old version file when an old version of the version file exists.
[0132] The game server update device 900 provided in this embodiment includes a trust establishment module 901, a file acquisition module 902, a version update module 903, an interface call module 904, a version check module 905, and an old version deletion module 906, which realizes hot update of the game server, greatly improves the hot update efficiency of the game server, and reduces the consumption of manpower and resources.
[0133] In yet another embodiment of this disclosure, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the game server update method described above.
[0134] This embodiment provides a computer-readable storage medium, and a computer program executed by a processor can implement the above-described game server update method one by one, thereby improving the efficiency of game server updates.
[0135] I will not go into details here.
[0136] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, terminal device, or network device, etc.) to execute the methods according to the embodiments of this disclosure.
[0137] In exemplary embodiments of this disclosure, a computer-readable storage medium is also provided, on which a program product capable of implementing the methods described above is stored. In some possible embodiments, various aspects of the invention may also be implemented as a program product comprising program code that, when the program product is run on a terminal device, causes the terminal device to perform the steps of the various exemplary embodiments of the invention described in the "Exemplary Methods" section of this specification.
[0138] A program product for implementing the above-described method according to embodiments of the present invention is described. This product may employ a portable compact disc read-only memory (CD-ROM) and include program code, and may run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited thereto. In this document, the readable storage medium may be any tangible medium containing or storing a program that may be used by or in conjunction with an instruction execution system, apparatus, or device.
[0139] The program product may employ any combination of one or more readable media. A readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.
[0140] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A readable signal medium may also be any readable medium other than a readable storage medium, capable of sending, propagating, or transmitting programs for use by or in conjunction with an instruction execution system, apparatus, or device.
[0141] The program code contained on the readable medium may be transmitted using any suitable medium, including but not limited to wireless, wired, optical fiber, RF, etc., or any suitable combination thereof.
[0142] Program code for performing the operations of this invention can be written in any combination of one or more programming languages, including object-oriented programming languages such as Java and C++, and conventional procedural programming languages such as C or similar languages. The program code can execute entirely on the user's computing device, partially on the user's device, as a standalone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In cases involving remote computing devices, the remote computing device can be connected to the user's computing device via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computing device (e.g., via the Internet using an Internet service provider).
[0143] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to embodiments of this disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.
[0144] Furthermore, although the steps of the method in this disclosure are described in a specific order in the accompanying drawings, this does not require or imply that the steps must be performed in that specific order, or that all the steps shown must be performed to achieve the desired result. Additional or alternative steps may be omitted, multiple steps may be combined into one step, and / or a step may be broken down into multiple steps.
[0145] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware. Therefore, the technical solutions according to the embodiments of this disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, USB flash drive, external hard drive, etc.) or on a network, including several instructions to cause a computing device (such as a personal computer, server, mobile terminal, or network device, etc.) to execute the methods according to the embodiments of this disclosure.
[0146] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the appended claims.
Claims
1. A method for updating a game server, characterized in that, Applied to device terminals, including: Obtain message interaction components generated based on user needs; Receive user actions on the message interaction component and generate server update commands; Create a Jenkins task via the task bot based on the server update command; The update script is invoked based on the parameter data of the message interaction component; The update script is executed via the Jenkins task, uploading the update file to the jump server. The jump server then uploads the update file to the Erlang game server, which performs an update based on the update file. The jump server and the Erlang game server have a pre-established trust relationship. The update script sends the update progress of the Erlang game server to a webhook address, wherein the webhook address is generated by the task bot and is pre-configured in the update script.
2. The game server update method according to claim 1, characterized in that, The process of obtaining message interaction components generated based on user needs includes: Obtain the style code corresponding to the interface style of the message interaction component based on user needs; Send the style code to the message group; The message interaction component interface is displayed in the message group.
3. The game server update method according to claim 1, characterized in that, The step of receiving user operations on the message interaction component and generating server update commands includes: The message interaction component interface is used to receive user operations and determine the server update method. The server update command is generated based on the parameter data of the message interaction component corresponding to the server update method.
4. The game server update method according to claim 1, characterized in that, The step of creating a Jenkins task via a task bot based on the server update command includes: Receive user operation feedback from the message interaction component through message groups; After the task robot monitors the user's operation feedback, it invokes the task robot's code information. Create a Jenkins task based on the code information.
5. The game server update method according to claim 1, characterized in that, The jump server establishes a Secure Shell (SSH) trust relationship with the Erlang game server in advance, and executes the rsync command of the Erlang game server to synchronize the update file to the Erlang game server.
6. A method for updating a game server, characterized in that, Applied to Erlang servers, including: Establish a trust relationship with the scaffolding machine; The update file is obtained through the jump server. The update file is generated after the device terminal receives the message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through the task robot according to the server update command, generates an update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update file to the jump server, which then uploads it to the Erlang game server. Update the Erlang game server according to the update file; The corresponding Erlang game server interface is called through the pre-configured Erlang server management node; The Erlang game server is notified to check the version file via the interface. If an older version of the file exists, delete the older version file.
7. The game server update method according to claim 6, characterized in that, The method further includes: The Erlang server management node calls the Erlang game server to verify the beam file in the directory; Determine whether the MD5 value of the beam file matches that of the memory beam module; If they match, then the Erlang game server update is successful.
8. A game server update device, characterized in that, include: The component acquisition module is used to acquire message interaction components generated based on user needs. The command generation module is used to receive user operations on the message interaction component and generate server update commands; The task creation module is used to create Jenkins tasks via a task robot based on the server update command. The script invocation module is used to invoke the update script based on the parameter data of the message interaction component; A script execution module is used to execute the update script via the Jenkins task, uploading the update file to the jump server, so that the jump server uploads the update file to the Erlang game server, and the Erlang game server updates according to the update file. The jump server and the Erlang game server have a pre-established trust relationship. The progress acquisition module is used to send the update progress of the Erlang game server to the webhook address through the update script. The webhook address is generated by the task robot and is pre-configured in the update script.
9. A game server update device, characterized in that, include: The trust establishment module is used to establish a trust relationship with the jump server; The file acquisition module is used to acquire update files through the jump server. The update files are generated after the device terminal receives a message interaction component generated based on user needs, receives user operations on the message interaction component, generates a server update command, creates a Jenkins task through a task robot according to the server update command, calls an update script according to the parameter data of the message interaction component, and then executes the update script through the Jenkins task to upload the update files to the jump server, which then uploads them to the Erlang game server. The version update module is used to update the Erlang game server according to the update file. The interface call module is used to call the corresponding Erlang game server's interface through the pre-configured Erlang server management node; The version check module is used to notify the Erlang game server to check the version file through the interface; The old version deletion module is used to delete the old version file when an old version of the current version file exists.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the game server update method according to any one of claims 1 to 7.