CN111224814A - Message processing method and device - Google Patents
Message processing method and device Download PDFInfo
- Publication number
- CN111224814A CN111224814A CN201911135974.XA CN201911135974A CN111224814A CN 111224814 A CN111224814 A CN 111224814A CN 201911135974 A CN201911135974 A CN 201911135974A CN 111224814 A CN111224814 A CN 111224814A
- Authority
- CN
- China
- Prior art keywords
- message
- capability
- messages
- keywords
- message queue
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/02—Standardisation; Integration
- H04L41/0246—Exchanging or transporting network management information using the Internet; Embedding network management web servers in network elements; Web-services-based protocols
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/903—Querying
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/906—Clustering; Classification
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L47/00—Traffic control in data switching networks
- H04L47/10—Flow control; Congestion control
- H04L47/24—Traffic characterised by specific attributes, e.g. priority or QoS
- H04L47/2441—Traffic characterised by specific attributes, e.g. priority or QoS relying on flow classification, e.g. using integrated services [IntServ]
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computational Linguistics (AREA)
- Telephonic Communication Services (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The embodiment of the application provides a message processing method and device, wherein the method comprises the following steps: acquiring a message to be processed from a message queue; the message to be processed is sent to the message queue by the capability provider through a Spring AOP (automatic optic protocol) section, wherein the message to be processed is a message called by different capabilities of HSF (high speed signaling) interfaces and is sent to the message queue through a message queue theme corresponding to the capabilities, and the capabilities are service capabilities and are used for meeting business requirements; classifying the messages to be processed according to the message queue theme; extracting keywords from the classified messages according to preset keywords; and sending the classified messages and the extracted corresponding keywords to a message library for storage. The standardization of the message processing protocol and the strong expansibility of the interface service are realized, the message processing cost is reduced, and the user experience is improved. The searching personnel can search all messages in the newspaper library through a searching entry according to the keywords, and can quickly and accurately search the required messages.
Description
Technical Field
The embodiment of the application relates to the technical field of communication, in particular to a message processing method and device.
Background
With the continuous development of science and technology, communication technology has been developed rapidly, and the concept of micro service in communication service of operators has been deeply inserted into the design core of each architecture design. For hundreds of millions of calls of the HSF interface every day, the request and response messages of each time need to be accurately recorded under the condition that the corresponding service speed is not influenced, so that the tracing restoration and positioning are provided for service handling.
Currently, a method for storing messages by a capability caller and a capability provider is generally adopted to record HSF interface messages.
However, each capability caller and each capability provider in the above method record in different ways, wherein the recording ways are different, which results in that the operation and maintenance personnel cannot quickly and accurately retrieve the required message; and the recording is repeated, wasting resources.
Disclosure of Invention
The embodiment of the application provides a message processing method and device, which aim to solve the problem that operation and maintenance personnel cannot quickly and accurately retrieve required messages because each capability calling party and each capability providing party adopt different modes for recording in the message processing process; and the recording is repeated, wasting resources.
In a first aspect, an embodiment of the present application provides a message processing method, including:
acquiring a message to be processed from a message queue; the message to be processed is sent to the message queue by the capability provider through a SpringAOP (automatic optic-object-oriented protocol) section, wherein the message to be processed is a message called by different capabilities of HSF (high speed signaling) interfaces and is sent to the message queue through a message queue theme corresponding to the capabilities, and the capabilities are service capabilities and are used for meeting business requirements;
classifying the messages to be processed according to the message queue theme;
extracting keywords from the classified messages according to preset keywords;
and sending the classified messages and the extracted corresponding keywords to a message library for storage.
In one possible design, the packet to be processed also carries a call time;
the classifying the to-be-processed packet according to the message queue theme includes:
and classifying the messages to be processed according to the message queue theme and the calling time.
In one possible design, the preset key includes at least one of a capability, a capability provider, a capability caller, a capability call result, a call flow number, and a service flow number.
In a second aspect, an embodiment of the present application provides another packet processing method, including:
receiving the classified messages and the extracted corresponding keywords sent by the message receiving device; the classified messages are obtained by classifying the messages to be processed by the message receiving device according to message queue themes, the corresponding keywords are obtained by extracting the keywords of the classified messages by the message receiving device according to preset keywords, the messages to be processed are obtained from message queues by the message receiving device, the messages to be processed are transmitted to the message queues through the message queue themes corresponding to the capabilities by the capability provider through Spring AOP (automatic optic resource planning) planes, and the capabilities are service capabilities and are used for meeting business requirements;
and storing the classified messages and the corresponding keywords.
In one possible design, the preset key includes at least one of a capability, a capability provider, a capability caller, a capability call result, a call flow number, and a service flow number.
In one possible design, after the storing the classified packet and the corresponding keyword, the method further includes:
receiving a message retrieval request sent by a message retrieval device, wherein the message retrieval request carries retrieval keywords;
and searching the stored classified messages according to the search keywords and the stored keywords.
In a third aspect, an embodiment of the present application provides another packet processing method, including:
the capability provider sends different capability calling messages of the HSF interface to the message queue through the Spring AOP section, and the message queue theme corresponding to the capability is sent to the message queue, wherein the capability is service capability and is used for meeting business requirements;
the message receiving device obtains a message to be processed from the message queue; classifying the messages to be processed according to the message queue theme; extracting keywords from the classified messages according to preset keywords; sending the classified messages and the extracted corresponding keywords to a message library;
and the newspaper library stores the classified messages and the corresponding keywords.
In a possible design, the capability provider sends the capability call messages with different HSF interfaces to the message queue through the message queue theme corresponding to the capability through the Spring AOP plane, including:
the capability provider configures the Spring AOP section according to the HSF interface, configures the implementation class of the HSF interface into the section class, acquires a request and a response message each time the HSF interface implementation class is called, acquires the capability, the capability provider, the capability caller, a capability calling result, a calling serial number and a service serial number in the response message, packages the acquired information into serialized objects, configures a message queue theme for each serialized object, and sends each serialized object configured with the message queue theme to the message queue.
In one possible design, the packet to be processed also carries a call time;
the classifying the to-be-processed packet according to the message queue theme includes:
and classifying the messages to be processed according to the message queue theme and the calling time.
In one possible design, the preset keywords include at least one of capabilities, capability providers, capability callers, and capability invocation results.
In one possible design, further comprising: receiving a message retrieval request sent by a message retrieval device by a message library, wherein the message retrieval request carries retrieval keywords;
and the newspaper library searches the stored classified messages according to the search keywords and the stored keywords.
In a fourth aspect, an embodiment of the present application provides a message processing apparatus, including: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executes computer-executable instructions stored by the memory to cause the at least one processor to perform the message processing method as set forth in the first aspect above and in various possible designs of the first aspect.
In a fifth aspect, an embodiment of the present application provides another packet processing device, including: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executes the computer-executable instructions stored by the memory to cause the at least one processor to perform the message processing method as set forth in the second aspect above and in various possible designs of the second aspect.
In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, where computer-executable instructions are stored in the computer-readable storage medium, and when a processor executes the computer-executable instructions, the message processing method according to the first aspect and various possible designs of the first aspect is implemented.
In a seventh aspect, an embodiment of the present application provides another computer-readable storage medium, where a computer-executable instruction is stored in the computer-readable storage medium, and when the processor executes the computer-executable instruction, the message processing method according to the second aspect and various possible designs of the second aspect is implemented.
In the message processing method and device provided by the embodiment, the message to be processed is obtained from the message queue, and the message to be processed is classified according to the message queue theme; extracting keywords from the classified messages according to preset keywords so that subsequent searching personnel can search the required messages according to the keywords; the classified messages and the extracted corresponding keywords are sent to a newspaper library for storage, and unified storage is carried out in the same recording mode, namely all the messages are collected into one newspaper library in the same format, so that repeated recording of the messages is avoided, resources are wasted, a searching person can search all the messages in the newspaper library through one searching entry according to the keywords, and the required messages can be quickly and accurately searched.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to these drawings without inventive exercise.
Fig. 1 is a schematic diagram of an architecture of a message processing system according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a message processing method according to an embodiment of the present application;
fig. 3 is a schematic flowchart of another message processing method according to an embodiment of the present application;
fig. 4 is a schematic flowchart of another message processing method according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a message processing apparatus according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of another message processing apparatus according to an embodiment of the present application;
fig. 7 is a schematic diagram of a hardware structure of a message processing device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the micro-service architecture, the HSF interface is called hundreds of millions of times every day, and the request and response messages of each time need to be accurately recorded under the condition of not influencing the corresponding service speed, so that the tracing restoration and positioning are provided for service handling.
Currently, a method for storing messages by a capability caller and a capability provider is generally adopted to record HSF interface messages.
However, each capability caller and each capability provider in the above method record in different ways, wherein the recording ways are different, which results in that the operation and maintenance personnel cannot quickly and accurately retrieve the required message; the recording is repeated, wasting resources.
Therefore, in view of the above problems, the present embodiment provides an interface interaction method, which obtains a to-be-processed packet from a message queue, and classifies the to-be-processed packet according to the message queue topic; extracting keywords from the classified messages according to preset keywords so that subsequent searching personnel can search the required messages according to the keywords; the classified messages and the extracted corresponding keywords are sent to a newspaper library for storage, and unified storage is carried out in the same recording mode, namely all the messages are collected into one newspaper library in the same format, so that repeated recording of the messages is avoided, resources are wasted, a searching person can search all the messages in the newspaper library through one searching entry according to the keywords, and the required messages can be quickly and accurately searched.
As shown in fig. 1, the system provided in this embodiment includes a message receiving device 101, a report library 102, a message queue, and a capability provider. The resource allocation center 101 may obtain a message to be processed from the message queue; the message to be processed is sent to the message queue by the capability provider through the SpringAOP section, the message is called by different capabilities of the HSF interface, and the message queue theme corresponding to the capabilities is sent to the message queue; the messages to be processed can be classified according to the message queue theme; keyword extraction can also be carried out on the classified messages according to preset keywords; or sending the classified messages and the extracted corresponding keywords to a message library for storage. The message receiving apparatus 101 can interact with the report library 102 and the message queue, and the implementation manner of the message receiving apparatus is not particularly limited in this embodiment. The newspaper library 102 may store the classified messages and the extracted corresponding keywords, so that a searcher may search all the messages in the newspaper library through a uniform search entry according to the keywords, and the implementation manner of the newspaper library 102 is not particularly limited in this embodiment, for example: relational Database Service (RDS), and the like.
The following describes the technical solutions of the present application and how to solve the above technical problems with specific embodiments. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
Fig. 2 is a flowchart illustrating a message processing method according to an embodiment of the present application, where an execution main body of the embodiment may be the message receiving apparatus 101 in the embodiment shown in fig. 1. As shown in fig. 2, the method may include:
s201: acquiring a message to be processed from a message queue; the message to be processed is sent to the message queue by the capability provider through the Spring AOP section, the message is called by different capabilities of the HSF interface, and the message queue theme corresponding to the capabilities is sent to the message queue, wherein the capabilities are service capabilities and are used for meeting business requirements.
The AOP is a section-oriented programming paradigm, is a programming idea, aims to improve modularization by separating cross-cutting attention points, and can span the attention points of an object. Aop, a typical application is spring's transaction mechanism, logging. By utilizing the AOP, all parts of the business logic can be isolated, so that the coupling degree between all parts of the business logic is reduced, the reusability of a program is improved, and the development efficiency is improved. The main functions are: log recording, performance statistics, security control, transaction processing, exception handling, and the like; the main intentions are: codes such as log records, performance statistics, safety control, transaction processing, exception handling and the like are divided from business logic codes, and the behaviors can be independently arranged in a method of non-guidance business logic by separating the behaviors, so that the codes of the business logic are not influenced when the behaviors are changed.
The HSF aims to provide a distributed service framework for the captive application, and the HSF provides support for users from a distributed application level and a uniform publish/invoke mode level, so that the distributed application can be easily developed and a common function module can be provided or used without considering various detailed technologies in the distributed field, such as remote communication, performance loss, call transparency, implementation of a synchronous/asynchronous invoke mode and the like.
The capability provider is a party providing the call service, and it is understood that the capability provider may call other services in other scenarios, and in this case, the capability provider is a capability caller. For example: b calls the capability of A, wherein A is used as a capability provider and B is used as a capability caller; a calls the capabilities of C and D, when A is the capability caller.
The message queue theme is a channel provided for messages with different capabilities, and the message queue theme is sent to the message queue through the channel corresponding to the capabilities.
Illustratively, the capability provider configures the Spring AOP plane according to an HSF interface, configures an implementation class of the HSF interface into a plane class, acquires a request and a response message each time the HSF interface implementation class is called, acquires information such as a capability, a capability provider, a capability caller, a capability calling result, a calling serial number, a service serial number, and the like in the response message, encapsulates the acquired information into serialized objects, configures a message queue topic for each serialized object, and sends each serialized object configured with the message queue topic onto the message queue.
S202: and classifying the messages to be processed according to the message queue theme.
Optionally, the to-be-processed packet further carries a call time. The classifying the to-be-processed packet according to the message queue theme includes:
and classifying the messages to be processed according to the message queue theme and the calling time.
Illustratively, different message queue topics are classified first, and then messages of the same message queue topic are classified according to dates. For example: the classification can be done according to the day dimension, i.e. the same message queue topic on the same day is classified into the same class.
S203: and extracting keywords from the classified messages according to preset keywords.
Optionally, the preset keyword includes at least one of a capability, a capability provider, a capability caller, a capability call result, a call flow number, and a service flow number.
The capability calling result comprises capability calling success and capability calling failure; the calling serial number is the serial number of the capability calling party; the service flow number is the flow number of the capability provider.
In addition, the preset keywords may include other keywords besides at least one of the capability, the capability provider, the capability caller, the capability call result, the call flow number, and the service flow number, and the preset keywords may be set according to actual needs, so as to meet various application needs.
For example, one or more keywords may be preset, such as: at least one of a preset capability, a capability provider, a capability caller, a capability call result, a call flow number, and a service flow number. And the message receiving device extracts the preset keywords of the classified messages according to the preset keywords. For example: the message 1 is a call message for calling the order creating capability of the capability provider A by the capability caller B, the call serial number is X, the call result is successful, the preset keywords are the capability caller, the capability and the call result, and the keywords are extracted as successful keywords from the capability caller B, the order creating capability and the call result in the message 1.
S204: and sending the classified messages and the extracted corresponding keywords to a message library for storage.
Illustratively, the message receiving device stores the classified messages and the extracted keywords in the messages into the message table of the corresponding message subject and date. Therefore, the user can search all messages stored in the message library through keywords with different dimensions, the user experience is improved, and different search requirements of the user are met.
In the message processing method provided in this embodiment, a message to be processed is acquired from a message queue through a message receiving device, and the message to be processed is classified through the message receiving device according to the message queue theme; extracting keywords from the classified messages according to preset keywords so that subsequent searching personnel can search the required messages according to the keywords; the classified messages and the extracted corresponding keywords are sent to a newspaper library for storage, the newspaper library is uniformly stored by the message receiving device in the same recording mode, namely all the messages are gathered in the newspaper library, so that the repeated recording of the messages and the resource waste are avoided, a retrieval worker can retrieve all the messages in the newspaper library according to the keywords through a retrieval inlet, and the required messages can be quickly and accurately retrieved.
Fig. 3 is a schematic flow chart of another message processing method according to an embodiment of the present disclosure, and an execution subject of the embodiment may be the report library 102 in the embodiment shown in fig. 1. As shown in fig. 3, the method may include:
s301: and receiving the classified messages and the extracted corresponding keywords sent by the message receiving device. The classified messages are obtained by classifying the messages to be processed by the message receiving device according to message queue themes, the corresponding keywords are obtained by extracting the keywords of the classified messages by the message receiving device according to preset keywords, the messages to be processed are obtained from the message queues by the message receiving device, the messages to be processed are transmitted to the message queues through the message queue themes corresponding to the capabilities by the capability provider through the SpringAOP section, and the capabilities are service capabilities and are used for meeting business requirements.
Optionally, the preset keyword includes at least one of a capability, a capability provider, a capability caller, and a capability call result.
S302: and storing the classified messages and the corresponding keywords.
Optionally, after storing the classified packet and the corresponding keyword, the method further includes:
s303: receiving a message retrieval request sent by a message retrieval device, wherein the message retrieval request carries retrieval keywords.
Illustratively, a search person sends a search request to the newspaper library through a message search device, where the search request carries keywords, such as: the search keywords in the retrieval request are capability invoker B and capability provider A.
S304: and searching the stored classified messages according to the search keywords and the stored keywords.
Illustratively, the newspaper library retrieves the stored classified messages according to the retrieval key and the stored key. For example: the retrieval keywords are the capability caller B and the capability provider A, the newspaper library retrieves that 1-20 messages meet the requirements for all stored keywords which are the messages of the capability caller B and the capability provider A, and the 20 messages can be sent to a message retrieval device for the retrieval personnel to review, download and the like.
The message retrieval request carrying the retrieval key word sent by the message retrieval device is received through the message library, and the stored classified messages are retrieved according to the retrieval key word and the stored key word, so that all the retrieval personnel can retrieve all the messages in the message library through the unified message retrieval device according to the key word, and can quickly and accurately retrieve the required messages, look up and download the messages and the like.
In the message processing method provided by this embodiment, a message to be processed is acquired from a message queue through a message receiving device, the message to be processed is classified through the message receiving device according to the message queue theme, and keyword extraction is performed on the classified message according to preset keywords, so that a subsequent searcher can search a required message according to the keywords; the newspaper library receives the classified messages sent by the message receiving device and the extracted corresponding keywords, and the newspaper library is stored in a unified mode, namely all the messages are collected into the newspaper library in the same format, so that repeated recording of the messages is avoided, resources are wasted, a message retrieval request which is sent by the message retrieval device and carries retrieval keywords is received through the newspaper library, the stored classified messages are retrieved according to the retrieval keywords and the stored keywords, all retrieval personnel can retrieve all the messages in the newspaper library through the unified message retrieval device according to the keywords, and required messages can be retrieved quickly and accurately, and the messages can be looked up and downloaded.
Fig. 4 is a schematic flow chart of another message processing method according to an embodiment of the present application, which is a flowchart of a scenario description performed from multiple terminals, such as a capability provider, a message receiving device, and a report library. As shown in fig. 4, the method may include:
s401: and the capability provider sends different capability calling messages of the HSF interface to the message queue through the Spring AOP section, and the message queue theme corresponding to the capability is sent to the message queue, wherein the capability is the service capability and is used for meeting the service requirement.
Optionally, the capability provider sends the capability call messages with different HSF interfaces to the message queue through the Spring AOP plane, and sends the message queue topics corresponding to the capabilities to the message queue, where the method includes:
the capability provider configures the Spring AOP section according to the HSF interface, configures the implementation class of the HSF interface into the section class, acquires a request and a response message each time the implementation class of the HSF interface is called, acquires capability, the capability provider, the capability caller and a capability calling result in the response message, encapsulates the acquired information into serialized objects, configures a message queue theme for each serialized object, and sends each serialized object configured with the message queue theme to the message queue.
S402: and the message receiving device acquires the message to be processed from the message queue.
S403: and the message receiving device classifies the messages to be processed according to the message queue theme.
Optionally, the to-be-processed packet further carries a call time;
the classifying the to-be-processed packet according to the message queue theme includes:
and classifying the messages to be processed according to the message queue theme and the calling time.
S404: and the message receiving device extracts the keywords of the classified messages according to the preset keywords.
Optionally, the preset keyword includes at least one of a capability, a capability provider, a capability caller, and a capability call result.
S405: and the message receiving device sends the classified messages and the extracted corresponding keywords to a message library.
S406: and the newspaper library stores the classified messages and the corresponding keywords.
Optionally, the method further comprises:
s407: the message library receives a message retrieval request sent by a message retrieval device, wherein the message retrieval request carries retrieval keywords.
S408: and the newspaper library searches the stored classified messages according to the search keywords and the stored keywords.
In the message processing method provided by this embodiment, a message to be processed is acquired from a message queue through a message receiving device, the message to be processed is classified through the message receiving device according to the message queue theme, and keyword extraction is performed on the classified message according to preset keywords, so that a subsequent searcher can search a required message according to the keywords; the newspaper library receives the classified messages sent by the message receiving device and the extracted corresponding keywords, and the newspaper library is stored in a unified mode, namely all the messages are collected into the newspaper library in the same format, so that repeated recording of the messages is avoided, resources are wasted, a message retrieval request which is sent by the message retrieval device and carries retrieval keywords is received through the newspaper library, the stored classified messages are retrieved according to the retrieval keywords and the stored keywords, all retrieval personnel can retrieve all the messages in the newspaper library through the unified message retrieval device according to the keywords, and required messages can be retrieved quickly and accurately, and the messages can be looked up and downloaded.
Fig. 5 is a schematic structural diagram of a message processing apparatus according to an embodiment of the present application, which corresponds to the message processing method according to the foregoing embodiment. For convenience of explanation, only portions related to the embodiments of the present application are shown. As shown in fig. 5, the message processing apparatus 50 includes: an acquisition module 501, a classification module 502, an extraction module 503, and a sending module 504.
An obtaining module 501, configured to obtain a message to be processed from a message queue; the message to be processed is sent to the message queue by the capability provider through a Spring AOP (automatic optic protocol) section, wherein the message to be processed is a message called by different capabilities of HSF (high speed signaling) interfaces and is sent to the message queue through a message queue theme corresponding to the capabilities, and the capabilities are service capabilities and are used for meeting business requirements;
a classification module 502, configured to classify the to-be-processed packet according to the message queue topic;
an extracting module 503, configured to perform keyword extraction on the classified messages according to preset keywords;
a sending module 504, configured to send the classified packet and the extracted corresponding keyword to a packet library for storage.
Optionally, the to-be-processed packet further carries a call time;
the classification module 502 classifies the to-be-processed packet according to the message queue topic, including:
and classifying the messages to be processed according to the message queue theme and the calling time.
Optionally, the preset keyword includes at least one of a capability, a capability provider, a capability caller, and a capability call result.
The apparatus provided in the embodiment of the present application may be configured to implement the technical solution of the method embodiment, and the implementation principle and the technical effect are similar, which are not described herein again in the embodiment of the present application.
Fig. 6 is a schematic structural diagram of another message processing apparatus according to the embodiment of the present application, which corresponds to the message processing method according to the embodiment. For convenience of explanation, only portions related to the embodiments of the present application are shown. As shown in fig. 6, the message processing apparatus 60 includes: a receiving module 601 and a storing module 602, and optionally, a receiving module 603 and a retrieving module 604.
A receiving module 601, configured to receive the classified message and the extracted corresponding keyword sent by the message receiving apparatus; the classified messages are obtained by classifying the messages to be processed by the message receiving device according to message queue themes, the corresponding keywords are obtained by extracting the keywords of the classified messages by the message receiving device according to preset keywords, the messages to be processed are obtained from message queues by the message receiving device, the messages to be processed are transmitted to the message queues through the message queue themes corresponding to the capabilities by the capability provider through Spring AOP (automatic optic resource planning) planes, and the capabilities are service capabilities and are used for meeting business requirements;
a storage module 602, configured to store the classified packet and the corresponding keyword.
Optionally, the preset keyword includes at least one of a capability, a capability provider, a capability caller, and a capability call result.
Optionally, the receiving module 603 is configured to, after storing the classified packet and the corresponding keyword,
receiving a message retrieval request sent by a message retrieval device, wherein the message retrieval request carries retrieval keywords.
Optionally, the retrieving module 604 is configured to retrieve the stored classified packet according to the retrieval keyword and the stored keyword.
The apparatus provided in the embodiment of the present application may be configured to implement the technical solution of the method embodiment, and the implementation principle and the technical effect are similar, which are not described herein again in the embodiment of the present application.
Fig. 7 is a schematic diagram of a hardware structure of a message processing device according to an embodiment of the present application. As shown in fig. 7, the message processing apparatus 7 of the present embodiment includes: a processor 701 and a memory 702; wherein
A memory 702 for storing computer-executable instructions;
the processor 701 is configured to execute computer-executable instructions stored in the memory to implement the steps of the message processing method in the embodiment of fig. 2. Reference may be made in particular to the description relating to the method embodiments described above.
Alternatively, the memory 702 may be separate or integrated with the processor 701.
When the memory 702 is separately provided, the message processing apparatus further includes a bus 703 for connecting the memory 702 and the processor 701.
An embodiment of the present application further provides a packet processing device, including: a processor and a memory; wherein
A memory for storing computer execution instructions;
and a processor for executing computer executable instructions stored in the memory to implement the steps of the message processing method in the embodiment of fig. 3. Reference may be made in particular to the description relating to the method embodiments described above.
Alternatively, the memory may be separate or integrated with the processor.
When the memory is independently arranged, the message processing device also comprises a bus which is used for connecting the memory and the processor.
An embodiment of the present application further provides a computer-readable storage medium, where a computer execution instruction is stored in the computer-readable storage medium, and when a processor executes the computer execution instruction, the message processing method in the embodiment of fig. 2 is implemented.
An embodiment of the present application further provides a computer-readable storage medium, where a computer execution instruction is stored in the computer-readable storage medium, and when a processor executes the computer execution instruction, the message processing method in the embodiment of fig. 3 is implemented.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described message processing apparatus embodiments are merely illustrative, and for example, the division of the modules is only one logical function division, and there may be another division manner in actual implementation, for example, a plurality of modules may be combined or may be integrated into another system, or some features may be omitted, or may not be executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to implement the solution of the present embodiment.
In addition, functional modules in the embodiments of the present application may be integrated into one processing unit, or each module may exist alone physically, or two or more modules are integrated into one unit. The unit formed by the modules can be realized in a hardware form, and can also be realized in a form of hardware and a software functional unit.
The integrated module implemented in the form of a software functional module may be stored in a computer-readable storage medium. The software functional module is stored in a storage medium and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device) or a processor to execute some steps of the message processing method according to the embodiments of the present application.
It should be understood that the Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the message processing method disclosed in this application may be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules in the processor.
The memory may comprise a high-speed RAM memory, and may further comprise a non-volatile storage NVM, such as at least one disk memory, and may also be a usb disk, a removable hard disk, a read-only memory, a magnetic or optical disk, etc.
The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended ISA (Extended Industry Standard Architecture) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, the buses in the figures of the present application are not limited to only one bus or one type of bus.
The storage medium may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be integral to the processor. The processor and the storage medium may reside in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the storage medium may reside as discrete components in an electronic device or host device.
Those of ordinary skill in the art will understand that: all or part of the steps of implementing the message processing method embodiments can be completed by hardware related to program instructions. The program may be stored in a computer-readable storage medium. When the program is executed, the steps of the message processing method embodiments are executed; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present application.
Claims (12)
1. A message processing method is characterized by comprising the following steps:
acquiring a message to be processed from a message queue; the message to be processed is sent to the message queue by the capability provider through a Spring AOP (automatic optic protocol) section, wherein the message to be processed is a message called by different capabilities of HSF (high speed signaling) interfaces and is sent to the message queue through a message queue theme corresponding to the capabilities, and the capabilities are service capabilities and are used for meeting business requirements;
classifying the messages to be processed according to the message queue theme;
extracting keywords from the classified messages according to preset keywords;
and sending the classified messages and the extracted corresponding keywords to a message library for storage.
2. The method according to claim 1, wherein the message to be processed further carries a call time;
the classifying the to-be-processed packet according to the message queue theme includes:
and classifying the messages to be processed according to the message queue theme and the calling time.
3. The method according to claim 1 or 2, wherein the preset keyword comprises at least one of a capability, a capability provider, a capability invoker, a capability invocation result, a call flow number, and a service flow number.
4. A message processing method is characterized by comprising the following steps:
receiving the classified messages and the extracted corresponding keywords sent by the message receiving device; the classified messages are obtained by classifying the messages to be processed by the message receiving device according to message queue themes, the corresponding keywords are obtained by extracting the keywords of the classified messages by the message receiving device according to preset keywords, the messages to be processed are obtained from message queues by the message receiving device, the messages to be processed are transmitted to the message queues through the message queue themes corresponding to the capabilities by the capability provider through Spring AOP (automatic optic resource planning) planes, and the capabilities are service capabilities and are used for meeting business requirements;
and storing the classified messages and the corresponding keywords.
5. The method of claim 4, wherein the preset keyword comprises at least one of a capability, a capability provider, a capability caller, a capability call result, a call flow number, and a service flow number.
6. The method according to claim 4 or 5, further comprising, after said storing said classified packets and said corresponding keywords:
receiving a message retrieval request sent by a message retrieval device, wherein the message retrieval request carries retrieval keywords;
and searching the stored classified messages according to the search keywords and the stored keywords.
7. A message processing method is characterized by comprising the following steps:
the capability provider sends different capability calling messages of the HSF interface to the message queue through the Spring AOP section, and the message queue theme corresponding to the capability is sent to the message queue, wherein the capability is service capability and is used for meeting business requirements;
the message receiving device obtains a message to be processed from the message queue; classifying the messages to be processed according to the message queue theme; extracting keywords from the classified messages according to preset keywords; sending the classified messages and the extracted corresponding keywords to a message library;
and the newspaper library stores the classified messages and the corresponding keywords.
8. The method according to claim 7, wherein the capability provider sends the capability call messages with different HSF interfaces to the message queue through a message queue topic corresponding to the capability through a Spring AOP plane, and the method comprises:
the capability provider configures the Spring AOP section according to the HSF interface, configures the implementation class of the HSF interface into the section class, acquires a request and a response message each time the HSF interface implementation class is called, acquires the capability, the capability provider, the capability caller, a capability calling result, a calling serial number and a service serial number in the response message, packages the acquired information into serialized objects, configures a message queue theme for each serialized object, and sends each serialized object configured with the message queue theme to the message queue.
9. A message processing apparatus, comprising: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the message processing method of any of claims 1-3.
10. A message processing apparatus, comprising: at least one processor and memory;
the memory stores computer-executable instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the message processing method of any of claims 4-6.
11. A computer-readable storage medium having computer-executable instructions stored thereon which, when executed by a processor, implement the message processing method of any of claims 1-3.
12. A computer-readable storage medium having computer-executable instructions stored thereon which, when executed by a processor, implement the message processing method of any of claims 4-6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911135974.XA CN111224814B (en) | 2019-11-19 | 2019-11-19 | Message processing method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201911135974.XA CN111224814B (en) | 2019-11-19 | 2019-11-19 | Message processing method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111224814A true CN111224814A (en) | 2020-06-02 |
CN111224814B CN111224814B (en) | 2023-03-24 |
Family
ID=70829421
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201911135974.XA Active CN111224814B (en) | 2019-11-19 | 2019-11-19 | Message processing method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111224814B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111767296A (en) * | 2020-06-30 | 2020-10-13 | 北京百度网讯科技有限公司 | Method, device, electronic equipment and readable storage medium for synchronizing data |
CN112437126A (en) * | 2020-11-10 | 2021-03-02 | 中国联合网络通信集团有限公司 | Task flow processing method and device based on atomic interface |
CN112882846A (en) * | 2021-02-19 | 2021-06-01 | 深圳市云网万店科技有限公司 | Data processing method and device of message queue, computer equipment and storage medium |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106992940A (en) * | 2016-09-23 | 2017-07-28 | 阿里巴巴集团控股有限公司 | Message processing method, device, system and terminal |
CN107465549A (en) * | 2017-08-18 | 2017-12-12 | 北京奇艺世纪科技有限公司 | A kind of distributed message processing method and system |
US20190095510A1 (en) * | 2017-09-25 | 2019-03-28 | Splunk Inc. | Low-latency streaming analytics |
US20190236194A1 (en) * | 2018-01-31 | 2019-08-01 | Splunk Inc. | Dynamic query processor for streaming and batch queries |
CN110134523A (en) * | 2018-12-24 | 2019-08-16 | 安徽省鼎众金融信息咨询服务有限公司 | It is a kind of using message system as the system architecture of core |
CN110196868A (en) * | 2019-06-06 | 2019-09-03 | 四川新网银行股份有限公司 | Based on distributed work order flow monitoring method |
-
2019
- 2019-11-19 CN CN201911135974.XA patent/CN111224814B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106992940A (en) * | 2016-09-23 | 2017-07-28 | 阿里巴巴集团控股有限公司 | Message processing method, device, system and terminal |
CN107465549A (en) * | 2017-08-18 | 2017-12-12 | 北京奇艺世纪科技有限公司 | A kind of distributed message processing method and system |
US20190095510A1 (en) * | 2017-09-25 | 2019-03-28 | Splunk Inc. | Low-latency streaming analytics |
US20190236194A1 (en) * | 2018-01-31 | 2019-08-01 | Splunk Inc. | Dynamic query processor for streaming and batch queries |
CN110134523A (en) * | 2018-12-24 | 2019-08-16 | 安徽省鼎众金融信息咨询服务有限公司 | It is a kind of using message system as the system architecture of core |
CN110196868A (en) * | 2019-06-06 | 2019-09-03 | 四川新网银行股份有限公司 | Based on distributed work order flow monitoring method |
Non-Patent Citations (3)
Title |
---|
JACKTANGER: "RocketMQ中Topic、Tag、GroupName的设计初衷", 《中文开源技术交流社区》 * |
TOOLTIME: "消息队列MQ入门理解", 《博客园》 * |
七牛云: "Topic与Tag最佳实践", 《七牛开发者中心》 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111767296A (en) * | 2020-06-30 | 2020-10-13 | 北京百度网讯科技有限公司 | Method, device, electronic equipment and readable storage medium for synchronizing data |
CN112437126A (en) * | 2020-11-10 | 2021-03-02 | 中国联合网络通信集团有限公司 | Task flow processing method and device based on atomic interface |
CN112437126B (en) * | 2020-11-10 | 2022-06-03 | 中国联合网络通信集团有限公司 | Task flow processing method and device based on atomic interface |
CN112882846A (en) * | 2021-02-19 | 2021-06-01 | 深圳市云网万店科技有限公司 | Data processing method and device of message queue, computer equipment and storage medium |
CN112882846B (en) * | 2021-02-19 | 2024-02-09 | 深圳市云网万店科技有限公司 | Data processing method and device for message queue, computer equipment and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN111224814B (en) | 2023-03-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111224814B (en) | Message processing method and device | |
WO2019134226A1 (en) | Log collection method, device, terminal apparatus, and storage medium | |
WO2019227689A1 (en) | Data monitoring method and apparatus, and computer device and storage medium | |
CN113595788B (en) | API gateway management method and device based on plug-in | |
CN111131368A (en) | Message pushing method and device | |
CN113938522B (en) | Event message transmission method, system, device and computer storage medium | |
CN113010378B (en) | Log processing method and device of microservice module, storage medium and electronic device | |
CN104077420A (en) | Method and device for importing data into HBase database | |
CN111367873A (en) | Log data storage method and device, terminal and computer storage medium | |
CN111651595A (en) | Abnormal log processing method and device | |
CN112217684A (en) | API gateway monitoring method, device and system | |
CN113704790A (en) | Abnormal log information summarizing method and computer equipment | |
CN111881094A (en) | Method, device, terminal and storage medium for extracting key information in log | |
CN114168297A (en) | Method, device, equipment and medium for scheduling collection tasks | |
CN111399999B (en) | Computer resource processing method, device, readable storage medium and computer equipment | |
CN118093219A (en) | Message processing method, device, equipment and storage medium | |
CN113342806A (en) | Big data processing method and device, storage medium and processor | |
CN112286930A (en) | Method, device, storage medium and electronic equipment for resource sharing of redis business side | |
CN115496470A (en) | Full-link configuration data processing method and device and electronic equipment | |
CN115438020A (en) | Database resource scheduling method, device, equipment and medium | |
CN115328734A (en) | Cross-service log processing method and device and server | |
CN112287643B (en) | Message monitoring method, device, equipment and computer readable storage medium | |
CN114157662A (en) | Cloud platform parameter adaptation method and device, terminal equipment and storage medium | |
US9240968B1 (en) | Autogenerated email summarization process | |
CN112269941A (en) | Business real-time pushing method and system, electronic equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |