Method and apparatus for sending medical messages

By using two cache databases in the medical message sending method, and flexibly handling delays based on message type and time difference, the problem of low efficiency in processing timed or excessively long delayed messages in existing technologies is solved, achieving more efficient and accurate message sending.

CN116821188BActive Publication Date: 2026-03-20KANG JIAN INFORMATION TECH (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-04
Publication Date
2026-03-20

AI Technical Summary

Technical Problem

Existing methods for sending medical messages cannot flexibly handle timeouts or extremely long delays, resulting in low message processing efficiency and poor accuracy.

Method used

By combining two cache databases (a first cache database and a second cache database), messages are stored and sent with different delay durations based on the type of medical message and the time difference between their transmission, enabling flexible processing of ultra-long delay messages.

Benefits of technology

It improves the efficiency and accuracy of message processing and delivery on the medical platform, meeting the needs of sending different messages.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116821188B_ABST
    Figure CN116821188B_ABST
Patent Text Reader

Abstract

The application discloses a kind of sending method and device of medical message, it is related to digital medical technology field, main purpose is to solve the problem of poor accuracy of existing medical message sending. Including: determining the message type of medical message to be sent, and the sending time of the medical message is converted to time format based on the message type, obtain executable time;If the difference between the executable time and target time is greater than the preset time threshold, the medical message is stored in the first cache database, and the medical message is sent to the second cache database according to the first delay duration in the first cache database;If the difference between the executable time and target time is less than or equal to the preset time threshold, the medical message is stored in the second cache database, and the medical message is sent according to the second delay duration in the second cache database.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of digital medical technology, and in particular to a medical message sending method and device. BACKGROUND

[0002] With the continuous integration of medical needs and digital platforms, more and more users make appointments through online medical platforms. As application programs, medical platforms usually communicate data based on message queue methods to meet the transmission needs of different medical data. At this time, the medical platform as an application program communicates by writing and retrieving the data (messages) in and out of the queue to achieve data interaction.

[0003] Currently, the existing data communication based on the message queue method usually uses activeMq, kafka, rocketMq, etc. Open source message middleware as a message subscription system for processing coupling between various application programs. However, since the medical platform processing medical messages needs to send specific messages with a delay according to a specific time, the message queue cannot flexibly send messages based on the above message subscription system, such as not being able to send overdue messages or long-time delay messages, etc., thereby greatly affecting the processing efficiency of messages in the medical platform, thereby reducing the accuracy of sending medical messages. SUMMARY

[0004] Therefore, the present application provides a medical message sending method and device, which mainly aims to solve the problem of poor accuracy of sending existing medical messages.

[0005] According to one aspect of the present application, a medical message sending method is provided, comprising:

[0006] determining the message type of the medical message to be sent, and performing time format conversion on the sending time of the medical message based on the message type to obtain an executable time;

[0007] If the difference between the executable time and the target time is greater than the preset time threshold, the medical message is stored in a first cache database, and the medical message is sent to a second cache database according to a first delay duration in the first cache database;

[0008] If the difference between the executable time and the target time is less than or equal to the preset time threshold, the medical message is stored in the second cache database, and the medical message is sent according to a second delay duration in the second cache database.

[0009] Further, the sending of the medical message to the second cache database according to the first delay duration in the first cache database comprises:

[0010] retrieve an executable time of the medical message stored in the first cache database according to a preset first scanning duration;

[0011] if a difference between the executable time and the target time is less than the first delay duration, send the medical message to the second cache database to send the medical message according to a second delay duration in the second cache database.

[0012] Further, the method further comprises:

[0013] loading the medical message from a medical service system and determining a message consumption strategy of the medical message, the message consumption strategy being used to represent a time and a number of times of sending the medical message;

[0014] determining a message type of the medical message according to the time in the message consumption strategy, the message type comprising an extended sending type, a timing sending type, and a periodic sending type.

[0015] Further, the method further comprises:

[0016] activating a message time format conversion component and performing time format conversion on the sending time of the medical message based on the message time format conversion component to obtain the executable time, the message time format conversion component being configured with conversion logic of performing time format conversion on the sending time according to the extended sending type, the timing sending type, and the periodic sending type.

[0017] Further, before the method of determining the message type of the medical message to be sent, the method further comprises:

[0018] obtaining different medical service consumption objects from a medical service system and determining consumption attributes of the medical service consumption objects, the consumption attributes being used to represent a behavior state of receiving and viewing historical medical messages based on the medical service consumption objects;

[0019] configuring the first delay duration and the second delay duration according to the consumption attributes and determining the first cache database and the second cache database based on the first delay time and the second delay time.

[0020] Further, the method further comprises:

[0021] retrieve an executable time of the medical message stored in the second cache database according to a preset second scanning duration;

[0022] If the difference between the executable time and the target time is less than the second delay duration, the medical message is sent to a medical consumption system to enable consumption of the medical message.

[0023] Further, the method further comprises:

[0024] When the number of medical messages in the first cache database is greater than a preset number threshold, the medical messages in the first cache database are determined to be stored, and the stored medical messages are stored in a third cache database.

[0025] When it is detected that the medical messages in the first cache database are sent to a second cache database, the stored medical messages are stored in the first cache database.

[0026] According to another aspect of the present application, a medical message sending device is provided, comprising:

[0027] A determination module is configured to determine a message type of a medical message to be sent, and perform time format conversion on a sending time of the medical message based on the message type to obtain an executable time.

[0028] A storage module is configured to, if the difference between the executable time and a target time is greater than a preset time threshold, store the medical message in a first cache database, and send the medical message to a second cache database according to a first delay duration in the first cache database.

[0029] A sending module is configured to, if the difference between the executable time and the target time is less than or equal to the preset time threshold, store the medical message in the second cache database, and send the medical message according to a second delay duration in the second cache database.

[0030] Further, the storage module is specifically configured to retrieve the executable time of the stored medical message in the first cache database according to a preset first scanning duration, and if the difference between the executable time and the target time is less than the first delay duration, send the medical message to the second cache database to send the medical message according to the second delay duration in the second cache database.

[0031] Further, the determination module is specifically configured to load the medical message from a medical service system, and determine a message consumption strategy of the medical message, the message consumption strategy being used to represent a time and a number of times of sending the medical message, and determine a message type of the medical message according to the time in the message consumption strategy, the message type including an extended sending type, a timing sending type, and a periodic sending type.

[0032] Further, the determining module is specifically configured to activate the message time format conversion component, and perform time format conversion on the sending time of the medical message based on the message time format conversion component to obtain the executable time, wherein the message time format conversion component is configured with conversion logic for performing time format conversion on the sending time according to the extended sending type, the timed sending type and the periodic sending type.

[0033] Further, the apparatus further comprises:

[0034] The acquisition module is configured to acquire different medical service consumption objects from a medical service system, and determine consumption attributes of the medical service consumption objects, wherein the consumption attributes are used to represent behavior states of receiving and viewing historical medical messages based on the medical service consumption objects.

[0035] The configuration module is configured to configure the first delay duration and the second delay duration according to the consumption attributes, and determine the first cache database and the second cache database based on the first delay time and the second delay time.

[0036] Further, the sending module is specifically configured to retrieve the executable time of the medical message stored in the second cache database according to a preset second scanning duration, and send the medical message to a medical consumption system if a difference between the executable time and the target time is less than the second delay duration, so that the medical message is consumed.

[0037] Further, the determining module is specifically configured to determine the medical message stored in the first cache database when the number of medical messages in the first cache database is greater than a preset number threshold, store the stored medical message in a third cache database, and store the stored medical message in the first cache database after detecting that the medical message in the first cache database is sent to the second cache database.

[0038] According to another aspect of the present application, a storage medium is provided, wherein at least one executable instruction is stored in the storage medium, and the executable instruction causes a processor to perform operations corresponding to the medical message sending method.

[0039] According to another aspect of the present application, a computer device is provided, comprising a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete communication with each other through the communication bus.

[0040] The memory is used to store at least one executable instruction, and the executable instruction causes the processor to perform the operation corresponding to the medical message sending method.

[0041] By means of the technical scheme, the embodiment of the present application has at least the following advantages:

[0042] The present application provides a medical message sending method and device, compared with the prior art, the embodiment of the present application determines the message type of the medical message to be sent, and converts the sending time of the medical message into executable time based on the message type; if the difference between the executable time and the target time is greater than the preset time threshold, the medical message is stored in the first cache database, and the medical message is sent to the second cache database according to the first delay time length in the first cache database; if the difference between the executable time and the target time is less than or equal to the preset time threshold, the medical message is stored in the second cache database, and the medical message is sent according to the second delay time length in the second cache database, the sending of the long delay message is realized by combining two cache databases, the mode of message sending is flexible, the sending requirements of different messages are met, the processing efficiency of messages in the medical platform is improved, and the sending accuracy of medical messages is improved.

[0043] The above description is only a summary of the technical scheme of the present application, in order to more clearly understand the technical means of the present application, the content of the specification can be implemented, and in order to make the above and other purposes, characteristics and advantages of the present application more obvious and easy to understand, the following specific embodiments of the present application are described. BRIEF DESCRIPTION OF DRAWINGS

[0044] By reading the detailed description of the preferred embodiments below, various other advantages and benefits will become clear to those of ordinary skill in the art. The drawings are only for the purpose of illustrating the preferred embodiments and are not considered as limiting the present application. Moreover, the same reference symbols are used to represent the same parts throughout the drawings. In the drawings:

[0045] Figure 1 A medical message sending method flow chart provided by the embodiment of the present application is shown;

[0046] Figure 2 A medical message sending device block diagram provided by the embodiment of the present application is shown;

[0047] Figure 3 The structure of a computer device provided by the embodiment of the present application is shown. DETAILED DESCRIPTION

[0048] Exemplary embodiments of the present disclosure will be described in greater detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it is understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that the present disclosure can be more thoroughly understood, and so that the scope of the present disclosure can be completely conveyed to those skilled in the art.

[0049] The embodiments of the present application can acquire and process related data based on artificial intelligence technology. Among them, artificial intelligence (AI) is to use digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.

[0050] The basic technology of artificial intelligence generally includes technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction system, mechatronics, etc. The software technology of artificial intelligence mainly includes computer vision technology, robot technology, biometric technology, speech processing technology, natural language processing technology, and machine learning / deep learning, etc.

[0051] Based on this, in one embodiment, the embodiments of the present application provide a medical message sending method. Taking a computer device such as a server as an example, the server can be an independent server, or a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content distribution networks (CDN), and basic cloud computing services such as big data and artificial intelligence platforms, etc. Such as intelligent medical systems, digital medical platforms, etc.

[0052] The embodiments of the present application provide a medical message sending method, as shown in Figure 1 The method comprises the following steps:

[0053] 101. Determine the message type of the medical message to be sent, and perform time format conversion on the sending time of the medical message based on the message type to obtain an executable time.

[0054] In this embodiment of the invention, the current execution end is an intermediate carrier for processing medical messages. It can be configured in a digital healthcare platform or in the server of a digital healthcare system; this embodiment does not impose specific limitations. The current execution end can communicate with both the medical business system that generates the medical messages and the medical consumption system that consumes the medical messages. When a medical message is generated in the medical business system, the current execution end acquires it, along with the message type of the medical message to be sent. The medical message represents a message transmitting specific medical information, including but not limited to registration information, doctor information, disease information, and treatment information. Based on this, the message is transmitted to the medical consumption system for publishing and other operations; this embodiment does not impose specific limitations. Furthermore, the message type defines the time type for sending the medical message, including extended sending, timed sending, and periodic sending. After determining the message type, the current execution end converts the sending time of the medical message according to this message type to obtain an executable time. Since different types of sending times correspond to different time formats, the current execution end converts the sending time format to a unified or predetermined time format to obtain an executable time to be compared with a target time. The executable time is obtained by converting the sending time of the medical message. For example, if the sending time is every 5 seconds and the target time is the current time, then the executable time after format conversion is the time after a delay of 5 seconds based on the current time. This embodiment of the invention does not make specific limitations.

[0055] 102. If the difference between the executable time and the target time is greater than a preset time threshold, the medical message is stored in the first cache database, and the medical message is sent to the second cache database according to the first delay duration in the first cache database.

[0056] In this embodiment of the invention, the current execution end calculates the difference between the executable time and the target time, and compares the difference with a preset time threshold. The target time can be the current time or a specified time, and the preset time threshold can be one hour or half an hour, configurable based on latency requirements. This embodiment does not impose specific limitations. When the calculated difference is greater than the preset time threshold, it indicates that the medical message is a message requiring an extremely long delay. Therefore, the medical message is sent to a first cache database for waiting. The first cache database is a relational database, such as a MySQL database. Simultaneously, the medical information is sent to a second cache database according to a first delay duration configured in the first cache database. The second cache database can be a non-relational database, such as a Redis database, to send the medical information to the second cache database according to a second delay duration.

[0057] It should be noted that, in order to realize the flexibility of medical message sending, the specific time of delay sending can be configured based on the pre-configured first delay duration and second delay duration, such as 3 hours and 5 hours, and the embodiments of the present application do not make specific limitation, so as to meet the sending requirements of super-long delay messages and specified time.

[0058] 103、If the difference between the executable time and the target time is less than or equal to the preset time threshold, the medical message is stored in the second cache database, and the medical message is sent according to the second delay duration in the second cache database.

[0059] In the embodiments of the present application, when the difference of the current execution end calculation is less than or equal to the preset time threshold, it is indicated that the medical message does not belong to the message of super-long delay sending, at this time, the medical message is stored in the second cache database, so as to directly send the medical message according to the delay duration in the second cache database. The configuration of the second delay duration is shorter than the first delay duration, so as to realize the placement of the super-long medical message in the first cache database and the cyclic judgment, and after the matching of the first delay duration, the medical message is placed in the second cache database for waiting for sending. Therefore, the time of super-long delay sending of the medical information can be configured as the sum of the fixed multiple of the first delay duration and the second delay duration, and the embodiments of the present application do not make specific limitation.

[0060] It should be noted that when the medical message is stored in the first cache database and the second cache database, the contents that can be stored include primary key id, message type, sending time, executable time, message ID, and the embodiments of the present application do not make specific limitation.

[0061] In another embodiment of the present application, in order to further illustrate and limit, the step of sending the medical message to the second cache database according to the first delay duration in the first cache database includes:

[0062] According to the preset first scanning duration, the executable time of the medical message stored in the first cache database is called;

[0063] If the difference between the executable time and the target time is less than the first delay duration, the medical message is sent to the second cache database, and the medical message is sent according to the second delay duration in the second cache database.

[0064] In order to realize accurate consumption of the medical message with the super-long delay, the current execution end sends the medical information to the second cache database, specifically, first scans the executable time of all the medical messages stored in the first cache database according to the preset first scanning duration, which is not limited in the embodiment of the application. When the difference between the executable time and the target time (such as the current time) is less than the first delay duration configured in the first cache database, it is indicated that the medical message has completed the super-long delay waiting, and therefore the medical information can be sent to the second cache database, so that the medical message is sent out based on the matching of the second delay duration in the second cache database. For example, a timing task is started for the MySql database, which is executed once every 30 minutes (the time is ensured to be less than 1 hour), the messages with the difference between the executable time and the current time less than 1 hour are found and dropped into the redis cache.

[0065] It should be noted that in the embodiment of the application, when the preset first scanning duration is used to scan the consumption time of the stored medical message, the preset first scanning duration can be configured according to different medical services, such as 3 hours, 5 hours, etc., to adapt to the sending scenario of the super-long delay message.

[0066] In another embodiment of the application, in order to further illustrate and limit, the step of determining the message type of the medical message to be sent includes:

[0067] Loading the medical message from the medical service system and determining the message consumption strategy of the medical message;

[0068] Determining the message type of the medical message according to the time in the message consumption strategy.

[0069] In order to ensure the unification of the time format according to different consumption types, the current execution end first loads the medical message to be sent from the medical service system, which can include that the current execution end receives a medical message after each medical message is generated in the medical service system, and can also include that a plurality of medical messages are packaged and sent according to a time interval in the medical service system, which is not limited in the embodiment of the application. After the current execution end loads the medical message, the message consumption strategy of the medical message is determined, at this time, the message consumption strategy is used to represent the time and the number of times of sending the medical message, and the consumption type is determined according to the time and the number of times based on the message consumption strategy. The message type includes the extended sending type, the timing sending type and the periodic sending type. When the time length in the message consumption strategy is long and only once, it is indicated that the message type is the extended sending type. When the time is a time point every day and once a day, it is indicated that the message type is the timing sending type. If the time length is specific and the number of times is specific, it is indicated that the message type is the periodic sending type, and the specific time length is not limited.

[0070] It should be noted that different message types can be represented based on the same time format or different time formats, such as different orders of magnitude of seconds, hours, days, months, years, etc., and the embodiments of the present application do not make specific limitations.

[0071] In another embodiment of the present application, in order to further illustrate and limit, the step of converting the sending time of the medical message into a time format based on the message type includes:

[0072] The message time format conversion component is adjusted, and the sending time of the medical message is converted into a time format based on the message time format conversion component to obtain the executable time.

[0073] In order to improve the sending accuracy of the medical message, the current execution end can convert the sending time into a time format based on the pre-configured message time format conversion component, for example, the sending time is delayed for 5 seconds, the current time is 10:20:10, and after the time format conversion, the executable time is 10:20:15, and the embodiments of the present application do not make specific limitations.

[0074] It should be noted that since the message time format conversion component is configured with conversion logic for converting the sending time into a time format according to the extended sending type, the timing sending type, and the periodic sending type, the sending time can be directly converted based on the message time format conversion component to obtain the executable time, for example, for a specified sending type, the sending time is yyyy-mm-dd hh:mm:ss, and the converted executable time is also yyyy-mm-dd hh:mm:ss. The current time is 2023-1-2 12:30:3, the sending time is 60 seconds for the periodic sending type, and the executable time is converted to 2023-1-2 12:31:3, 2023-1-2 12:32:3, 2023-1-2 12:33:3, etc. The embodiments of the present application do not make specific limitations.

[0075] In another embodiment of the present application, in order to further illustrate and limit, before the step of determining the message type of the medical message to be sent, the method further includes:

[0076] Different medical business consumption objects are obtained from the medical business system, and the consumption attributes of the medical business consumption objects are determined;

[0077] The first delay duration and the second delay duration are configured according to the consumption attributes, and the first cache database and the second cache database are determined based on the first delay time and the second delay time.

[0078] To achieve flexible configuration for ultra-long delays or timed message sending, the current execution end obtains different medical service consumer objects from the medical service system to determine the consumption attributes of these objects. These medical service consumer objects are users or third parties consuming medical messages, including but not limited to doctors, patients, and hospitals. The consumption attributes of these objects characterize their behavior in receiving and viewing historical medical messages. For example, if a medical service consumer frequently receives and views historical medical information, the value of the consumption attribute is configured to be higher; if it rarely does so, the value is configured to be lower. In other words, the consumption attributes are pre-configured based on behavioral status, and this embodiment of the invention does not impose specific limitations.

[0079] It should be noted that the current execution terminal is pre-configured with configuration mapping relationships corresponding to different consumption attributes and different delay durations. Therefore, the first delay duration and the second delay duration are configured according to the corresponding consumption attributes. This allows for configuring delay durations for different cache databases based on the behavior state of receiving and viewing historical medical information, thereby determining the corresponding cache database. In this embodiment of the invention, the first delay duration is longer than the second delay duration. Correspondingly, when determining the cache database, a relational database is determined based on the first delay duration, and a non-relational database is determined based on the second delay duration. This embodiment of the invention does not impose specific limitations.

[0080] In another embodiment of the invention, for further explanation and limitation, the step of sending the medical message according to a second delay duration in the second cache database includes:

[0081] The executable time of the medical message stored in the second cache database is retrieved according to the preset second scan duration;

[0082] If the difference between the executable time and the target time is less than the second delay duration, the medical message is sent to the medical consumption system for consumption.

[0083] In order to realize accurate consumption of the medical message with the super-long delay, the current execution end stores the executable time of the medical message in the second cache database after sending the medical information to the second cache database. The current execution end scans the executable time of the medical message in the second cache database according to the preset second scanning time length. When the difference between the executable time and the target time (for example, the current time) is less than the second delay time length configured in the second cache database, it is indicated that the medical message has completed the super-long delay waiting and has reached the message sending time. Therefore, the medical information can be sent to the medical consumption system to consume the medical message in the medical consumption system. For example, a timing task is started separately for the redis cache database, which is executed once every 500 milliseconds. The executable time less than or equal to the second delay time length is found and discarded into the open source message middleware such as RocketMQ for consumption by the consumer.

[0084] In another embodiment of the application, in order to further illustrate and limit, the step further comprises:

[0085] When the number of the medical messages in the first cache database is greater than the preset number threshold, the medical messages in the first cache database are determined to be stored, and the stored medical messages are stored in the third cache database.

[0086] When it is detected that the medical messages in the first cache database are sent to the second cache database, the stored medical messages are stored in the first cache database.

[0087] In order to avoid losing the medical message, the current execution end detects whether the number of the medical messages in the first cache database is greater than the preset number threshold in real time. If yes, it is indicated that the first cache database is full and cannot store the medical message. Therefore, the medical message to be stored is determined. At this time, the preset number of medical messages can be directly screened, or the medical messages stored in the first cache database can be screened according to the time, for example, the medical messages stored in the cache within the last one hour are stored as the stored medical data. The third cache database is a same type relational database as the second cache database, which is used as a backup database to store the excessive medical messages. When the current execution end detects that the medical messages in the first cache database have been sent to the second cache database, it is indicated that the first cache database has a free storage space. Therefore, the stored medical messages can be stored in the first cache database, and the embodiment of the application is not limited.

[0088] The embodiment of the present application provides a medical message sending method, compared with the prior art, the embodiment of the present application determines the message type of a medical message to be sent, and performs time format conversion on the sending time of the medical message based on the message type, to obtain executable time; if the difference between the executable time and target time is greater than a preset time threshold, the medical message is stored into a first cache database, and the medical message is sent into a second cache database according to a first delay duration in the first cache database; if the difference between the executable time and target time is less than or equal to the preset time threshold, the medical message is stored into the second cache database, and the medical message is sent according to a second delay duration in the second cache database, the sending of the super-long delay message is realized by combining two cache databases, the mode of message sending is flexible, the sending requirements of different messages are met, the processing efficiency of messages in the medical platform is improved, and therefore the sending accuracy of medical messages is improved.

[0089] Further, as the implementation of the method shown in the above Figure 1 The embodiment of the present application provides a medical message sending device, as shown in the above Figure 2 The device comprises:

[0090] A determination module 21 is configured to determine the message type of a medical message to be sent, and perform time format conversion on the sending time of the medical message based on the message type, to obtain executable time.

[0091] A storage module 22 is configured to store the medical message into a first cache database if the difference between the executable time and target time is greater than a preset time threshold, and send the medical message into a second cache database according to a first delay duration in the first cache database.

[0092] A sending module 23 is configured to store the medical message into the second cache database if the difference between the executable time and target time is less than or equal to the preset time threshold, and send the medical message according to a second delay duration in the second cache database.

[0093] Further, the storage module is specifically configured to retrieve the executable time of the medical message stored in the first cache database according to a preset first scanning duration; if the difference between the executable time and the target time is less than the first delay duration, the medical message is sent into the second cache database, so as to send the medical message according to the second delay duration in the second cache database.

[0094] Further, the determining module is specifically configured to load the medical message from a medical service system and determine a message consumption strategy of the medical message, the message consumption strategy being used to represent a time and a number of times of sending the medical message; and determine a message type of the medical message according to the time in the message consumption strategy, the message type including an extended sending type, a timing sending type and a periodic sending type.

[0095] Further, the determining module is specifically configured to further adjust a message time format conversion component and perform time format conversion on the sending time of the medical message based on the message time format conversion component to obtain the executable time, the message time format conversion component being configured with conversion logic of performing time format conversion on the sending time according to the extended sending type, the timing sending type and the periodic sending type.

[0096] Further, the apparatus further comprises:

[0097] The obtaining module is configured to obtain different medical service consumption objects from a medical service system and determine consumption attributes of the medical service consumption objects, the consumption attributes being used to represent a behavior state of receiving and viewing historical medical messages based on the medical service consumption objects;

[0098] The configuring module is configured to configure the first delay duration and the second delay duration according to the consumption attributes and determine the first cache database and the second cache database based on the first delay time and the second delay time.

[0099] Further, the sending module is specifically configured to retrieve the executable time of the medical message stored in the second cache database according to a preset second scanning duration; if a difference between the executable time and the target time is less than the second delay duration, send the medical message to a medical consumption system to enable consumption of the medical message.

[0100] Further, the determining module is specifically configured to determine the medical message stored in the first cache database when a number of the medical messages in the first cache database is greater than a preset number threshold, store the stored medical message in a third cache database, and store the stored medical message in the first cache database after detecting that the medical message in the first cache database is sent to the second cache database.

[0101] This invention provides a medical message sending device. Compared with the prior art, this invention determines the message type of the medical message to be sent and performs time format conversion on the sending time of the medical message based on the message type to obtain an executable time. If the difference between the executable time and the target time is greater than a preset time threshold, the medical message is stored in a first cache database and sent to a second cache database according to a first delay duration in the first cache database. If the difference between the executable time and the target time is less than or equal to the preset time threshold, the medical message is stored in the second cache database and sent according to a second delay duration in the second cache database. By combining the two cache databases, ultra-long delay message sending is achieved, the message sending method is flexible, different message sending needs are met, the message processing efficiency in the medical platform is improved, and thus the accuracy of medical message sending is improved.

[0102] According to one embodiment of the present invention, a storage medium is provided, the storage medium storing at least one executable instruction, the computer-executable instruction being capable of executing the medical message sending method in any of the above method embodiments.

[0103] Figure 3 The diagram illustrates a structural schematic of a computer device according to an embodiment of the present invention. The specific embodiments of the present invention do not limit the specific implementation of the computer device.

[0104] like Figure 3 As shown, the computer device may include: a processor 302, a communications interface 304, a memory 306, and a communications bus 308.

[0105] The processor 302, communication interface 304, and memory 306 communicate with each other via communication bus 308.

[0106] Communication interface 304 is used to communicate with other network elements such as clients or other servers.

[0107] The processor 302 is used to execute program 310, specifically to execute the relevant steps in the above-described embodiment of the medical message sending method.

[0108] Specifically, program 310 may include program code that includes computer operation instructions.

[0109] The processor 302 can be a central processing unit (CPU), or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to perform the embodiments of the present application. The computer device can include one or more processors of the same type or different types, such as one or more CPUs and one or more ASICs.

[0110] The memory 306 is configured to store a program 310. The memory 306 can include a high-speed RAM memory, and can further include a non-volatile memory, such as at least one disk memory.

[0111] The program 310 can be specifically configured to enable the processor 302 to perform the following operations:

[0112] determine a message type of a medical message to be sent, and perform time format conversion on a sending time of the medical message based on the message type, to obtain an executable time;

[0113] If a difference between the executable time and a target time is greater than a preset time threshold, store the medical message into a first cache database, and send the medical message to a second cache database according to a first delay duration in the first cache database;

[0114] If the difference between the executable time and the target time is less than or equal to the preset time threshold, store the medical message into the second cache database, and send the medical message according to a second delay duration in the second cache database.

[0115] Obviously, those skilled in the art should understand that the above-mentioned modules or steps of the present application can be realized by general computing devices, which can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be realized by program codes executable by computing devices, so that they can be stored in storage devices and executed by computing devices, and in some cases, the steps shown or described can be executed in different orders, or they can be respectively manufactured into individual integrated circuit modules, or multiple modules or steps among them can be manufactured into a single integrated circuit module. Thus, the present application is not limited to any specific combination of hardware and software.

[0116] The above merely provides the preferred embodiments of the present application, and is not used to limit the present application. For those skilled in the art, the present application can have various modifications and changes. Any modifications, equivalent replacements, improvements, etc. made within the principles and technical scope of the present application shall fall into the scope of the present application.

Claims

1. A method for sending medical messages, characterized in that, include: Determine the message type of the medical message to be sent, and convert the time format of the medical message based on the message type to obtain the executable time; If the difference between the executable time and the target time is greater than a preset time threshold, the medical message is stored in the first cache database and sent to the second cache database according to the first delay duration in the first cache database. If the difference between the executable time and the target time is less than or equal to a preset time threshold, the medical message is stored in the second cache database and sent according to the second delay duration in the second cache database. The step of converting the sending time of the medical message based on the message type to obtain the executable time includes: The message time format conversion component is invoked, and the sending time of the medical message is converted into a time format based on the message time format conversion component to obtain the executable time. The message time format conversion component is configured with conversion logic to convert the sending time into a time format according to extended sending type, timed sending type, and periodic sending type.

2. The method according to claim 1, characterized in that, Sending the medical message to the second cache database according to the first delay duration in the first cache database includes: The executable time of the medical message stored in the first cache database is retrieved according to the preset first scan duration; If the difference between the executable time and the target time is less than the first delay duration, the medical message is sent to the second cache database to send the medical message according to the second delay duration in the second cache database.

3. The method according to claim 1, characterized in that, The message types for determining the medical message to be sent include: The medical message is loaded from the medical business system, and a message consumption strategy for the medical message is determined. The message consumption strategy is used to characterize the time and number of times the medical message is sent. The message type of the medical message is determined according to the time specified in the message consumption strategy. The message type includes extended sending type, timed sending type, and periodic sending type.

4. The method according to claim 1, characterized in that, Before determining the message type of the medical message to be sent, the method further includes: Different medical service consumers are obtained from the medical service system, and the consumption attributes of the medical service consumers are determined. The consumption attributes are used to characterize the behavior status of receiving and viewing historical medical messages based on the medical service consumers. Configure the first delay duration and the second delay duration according to the consumption attributes, and determine the first cache database and the second cache database based on the first delay duration and the second delay duration.

5. The method according to claim 1, characterized in that, Sending the medical message according to the second delay duration in the second cache database includes: The executable time of the medical message stored in the second cache database is retrieved according to the preset second scan duration; If the difference between the executable time and the target time is less than the second delay duration, the medical message is sent to the medical consumption system for consumption.

6. The method according to any one of claims 1-5, characterized in that, The method further includes: When the number of medical messages in the first cache database exceeds a preset threshold, it is determined that the medical messages are transferred to the first cache database and then stored in the third cache database. When the medical message in the first cache database is detected to be sent to the second cache database, the transferred medical message is stored in the first cache database.

7. A medical message sending device, characterized in that, include: The determination module is used to determine the message type of the medical message to be sent, and to convert the time format of the medical message based on the message type to obtain the executable time; The storage module is configured to store the medical message in a first cache database and send the medical message to a second cache database according to a first delay duration in the first cache database if the difference between the executable time and the target time is greater than a preset time threshold. The sending module is configured to store the medical message in the second cache database and send the medical message according to the second delay duration in the second cache database if the difference between the executable time and the target time is less than or equal to a preset time threshold. The determining module is further configured to invoke the message time format conversion component and perform time format conversion on the sending time of the medical message based on the message time format conversion component to obtain the executable time. The message time format conversion component is configured with conversion logic to convert the sending time according to extended sending type, timed sending type and periodic sending type.

8. A storage medium storing at least one executable instruction that causes a processor to perform an operation corresponding to the method for sending medical messages as described in any one of claims 1-6.

9. A computer device, comprising: The processor, memory, communication interface, and communication bus are provided, wherein the processor, memory, and communication interface communicate with each other via the communication bus. The memory is used to store at least one executable instruction that causes the processor to perform an operation corresponding to the medical message sending method as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Delay message pushing method and apparatus, computer device and storage medium

    CN108388479A

  • Message processing method and apparatus, and electronic device

    WO2022111733A1