Event response method and device, electronic equipment and readable storage medium
By updating the Issue status data in Jira application and using the webhook callback mechanism to respond to events, combined with the event compensation response mechanism, the reliability problem of the Issue status change event response in Jira is solved, and the integrity and reliability of the event response are achieved.
Patent Information
- Application Number
- CN202310974920.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-03
- Publication Date
- 2025-02-14
AI Technical Summary
The webhook callback mechanism for Issue state change events in Jira has reliability problems and cannot effectively deal with event missed responses caused by callback failure.
In Jira application, the status data of the target Issue is updated to the Jira database, and the webhook callback mechanism is used to respond to the target state change event and write to the event database. When the event compensation response condition is met, the target data is filtered through the Jira query statement, and compared with the state change events recorded in the event database to determine and compensate for the unresponsive state change events.
Enhance the reliability of event response, ensure that all state change events are responded and recorded in a timely manner, and avoid incident missed responses caused by webhook callback failure.
Smart Images

Figure CN119440908A_ABST
Abstract
Description
Technical Field
[0001] This document relates to the field of computer technology, and in particular to an event response method, device, electronic device and readable storage medium. Background Art
[0002] Jira is a popular project management and issue tracking tool used to coordinate work among team members. In Jira, tasks, work items, or problems are called issues, and the progress of tasks, work items, or problems is indicated by the flow of issue status. Different Jira projects can define the status of issues according to their needs and workflow.
[0003] Sometimes, relevant personnel want to get reliable notification when the issue status changes, that is, they need to make a reliable response to the issue status change event. One implementation method is to use the webhook mechanism provided by Jira, however, the reliability of webhook is defective. Summary of the invention
[0004] The purpose of the embodiments of this specification is to provide an event response method, device, electronic device and readable storage medium to enhance the reliability of event response.
[0005] To solve the above technical problems, the embodiments of this specification are implemented as follows:
[0006] In the first aspect, an incident response method is proposed, comprising:
[0007] When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue;
[0008] When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement;
[0009] Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0010] In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
[0011] In a second aspect, an event response device is proposed, comprising:
[0012] A storage unit, when the state of a target Issue changes in the Jira application, updates the changed state data of the target Issue to the Jira database; and responds to the target state change event through a webhook callback mechanism, executes a predetermined operation corresponding to the target state change event and writes the target state change event to an event database; the target state change event is triggered by a change in the state of the target Issue;
[0013] A screening unit, when an event compensation response condition is met, screening target data corresponding to the event compensation response condition from the Jira database through a Jira query statement;
[0014] a comparison unit, comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0015] The processing unit performs a compensation response to the unresponded state change event when there is an unresponded state change event, and adds the unresponded state change event to the event database.
[0016] In a third aspect, an electronic device is provided, comprising:
[0017] Processor; and
[0018] a memory arranged to store computer executable instructions which, when executed, cause the processor to:
[0019] When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue;
[0020] When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement;
[0021] Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0022] In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
[0023] In a fourth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores one or more programs, and when the one or more programs are executed by an electronic device including a plurality of application programs, the electronic device performs the following operations:
[0024] When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue;
[0025] When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement;
[0026] Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0027] In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
[0028] It can be seen from the technical solutions provided by the above embodiments of this specification that the embodiments of this specification have at least one of the following technical effects:
[0029] In the case that the state of the target Issue in the Jira application changes, the changed state data of the target Issue is updated to the Jira database; and the target state change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target state change event is executed and the target state change event is written into the event database; the target state change event is triggered according to the change of the state of the target Issue; when the event compensation response condition is met, the target data corresponding to the event compensation response condition is filtered out from the Jira database through the Jira query statement; the target data is compared with the state change event recorded in the event database to determine whether there is an unresponsive state change event; when there is an unresponsive state change event, a compensation response is made to the unresponsive state change event, and the unresponsive state change event is added to the event database. The target data corresponding to the event compensation response condition is filtered out from the Jira database through the query statement in the Jira application, and the target data is compared with the state change event recorded in the event database. When there is an unresponsive state change event, a compensation response is made to the unresponsive state change event, and the unresponsive state change event is added to the event database, which solves the event leakage response caused by the failure of the webhook callback and enhances the reliability of the event response. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the embodiments of this specification or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0031] Figure 1 It is a schematic diagram of an implementation flow of an event response method provided by an embodiment of this specification.
[0032] Figure 2 It is a structural diagram of an event response device provided by an embodiment of this specification.
[0033] Figure 3 It is a structural schematic diagram of an electronic device provided by an embodiment of the specification. DETAILED DESCRIPTION
[0034] In order to make the purpose, technical solutions and advantages of this document clearer, the technical solutions of this specification will be clearly and completely described below in combination with the specific embodiments of this specification and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of this specification, not all of them. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this document.
[0035] The technical solutions provided by the embodiments of this specification are described in detail below in conjunction with the accompanying drawings.
[0036] Jira is a popular project management and issue tracking tool used to coordinate work among team members.
[0037] Issue is a term in Jira application. Issue refers to a task, bug, requirement or other types of work items.
[0038] Issue status in Jira refers to the different stages or states of a task, work item, or issue, which can indicate the current status or progress of the task, work item, or issue.
[0039] Typically, the Issue status in Jira can include the following common options:
[0040] 1. Open: The task has been created but processing has not yet started.
[0041] 2.In Progress: The task is in progress and is being processed by team members.
[0042] 3.Resolved: The task has been completed and has passed review or testing.
[0043] 4. Closed: The task has been completed and no further processing is required.
[0044] 5. Reopened: The task is reopened after being resolved and needs to be processed again.
[0045] 6.On Hold: The task is paused for some reason, waiting for further operation or decision.
[0046] 7.Blocked: The task cannot proceed due to some dependencies or problems.
[0047] It’s important to note that the actual status options can vary by organization, project, or team. In Jira, administrators and project leaders can customize statuses to fit specific workflows and needs.
[0048] In short, the Issue status in Jira can be used to track the different stages of tasks or issues in the workflow, helping team members understand the progress and current status of the work.
[0049] As described in the background technology, the webhook callback mechanism can be used to trigger the webhook callback according to the status change event of the Issue to notify relevant personnel. The webhook callback is a mechanism for implementing real-time, automated event notification and data delivery, and it is a way for web applications and services to communicate and integrate.
[0050] Specifically, a webhook is an application that sends a Hypertext Transfer Protocol (HTTP) request to another application's network address (Uniform Resource Locator, URL) when a specific event occurs. This URL is the callback URL of the webhook. When an event occurs, the application that sends the request sends the relevant data to the callback URL in the form of an HTTP request. The application that receives the request can perform corresponding processing and operations based on the received data.
[0051] However, the problem with this implementation is that webhook does not support a retry mechanism if it fails. In other words, if the webhook callback fails, it means that the response to the event has failed, and there is no compensatory measure.
[0052] In order to enhance the reliability of event response, the present specification provides an event response method, in which, when the status of a target Issue in a Jira application changes, the changed status data of the target Issue is updated to a Jira database; and a target status change event is responded to through a webhook callback mechanism, a predetermined operation corresponding to the target status change event is executed, and the target status change event is written into an event database; the target status change event is triggered according to a change in the status of the target Issue; when an event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement; the target data is compared with the status change events recorded in the event database to determine whether there is an unresponded status change event; when there is an unresponded status change event, a compensation response is performed for the unresponded status change event, and the unresponded status change event is added to the event database.
[0053] In this implementation, an event database is added. In addition to executing the scheduled operation, the response made through the webhook callback mechanism also includes writing the target state change event into the event database. Preferably, the execution of the scheduled operation and the writing of the target state change event are completed in one transaction. If the execution is successful, the writing is successful; if the execution fails, the writing also fails, ensuring the consistency of the two.
[0054] Therefore, the records in the event database can be used to trace whether the event response is successful. If it is unsuccessful, a compensatory response can be made. The problem is how to determine whether there are omissions in the records in the event database. A feasible solution is to use the Issue status data recorded in the Jira database for comparison.
[0055] Specifically, the target data corresponding to the event compensation response conditions are filtered out from the Jira database through the query statement in the Jira application, and the target data is compared with the state change events recorded in the event database. In the case of unresponsive state change events, a compensation response is made to the unresponsive state change events, and the unresponsive state change events are added to the event database, thereby realizing real-time recording of Jira status changes and ensuring the integrity of data in the event database, thereby enhancing the reliability of event response.
[0056] Based on the above reasons, the event response method provided in the embodiments of this specification is executed by a computer device, for example, by at least one of a server, a laptop computer, a desktop computer, a tablet computer or an intelligent robot.
[0057] For ease of description, the following takes the execution subject of the method as an electronic device capable of executing the event response method as an example, and the electronic device can specifically be an electronic device such as a server, a laptop, a desktop computer, a tablet computer or an intelligent robot to introduce the implementation method of the method. It can be understood that the execution subject of the method as an electronic device is only an exemplary description and should not be understood as a limitation of the method.
[0058] Figure 1 This is a schematic diagram of an implementation flow of an event response method provided by an embodiment of this specification, including:
[0059] S110, when the status of the target Issue changes in the Jira application, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written into the event database.
[0060] The target status change event is triggered when the status of the target issue changes. The target issue refers to the issue whose status has changed.
[0061] An issue refers to a task, bug, requirement, or other type of work item. Issues are used to track and manage work progress in a project and are the basic unit in Jira projects. Each issue represents an independent unit of work. Team members can create, edit, and process issues in Jira to collaborate, track, and record work progress.
[0062] As mentioned above, the Issue status in Jira includes but is not limited to Open, In Progress, Resolved, Closed, Reopened, On Hold, Blocked, etc., which will not be repeated here.
[0063] An issue status change refers to a transition from one state to another, for example, from the Open state to the In Progress state, or from the In Progress state to the Resolved state; an issue status change indicates that the current state or progress of a task, work item, or problem has changed.
[0064] The database of the Jira application is referred to as the Jira database. Users can query data from the Jira database through custom query statements in Jira. The event database is a database outside the Jira database. For example, the event database can be a database specifically used to record Jira status change events.
[0065] When the status of an Issue in the Jira application changes, the Issue with the changed status is used as the target Issue, and the relevant data of the target Issue status change is updated to the Jira database. The target status change event is responded to through the webhook callback mechanism, and the predetermined operation corresponding to the target status change event is executed and the target status change event is written into the event database.
[0066] Responding to a target state change event includes: determining a corresponding scheduled operation according to the content of the target state change event; the scheduled operation includes but is not limited to issuing a reminder notification, triggering code building, and triggering automatic approval.
[0067] For example, if the target Issue status changes to "To be done", a reminder is sent to the relevant responsible persons to remind them to start processing the task; if the target Issue status changes to "Resolved", the code building process is triggered to compile and deploy the relevant code; if the target Issue status changes to "Pending approval", the automatic approval process is triggered to notify the relevant personnel for approval.
[0068] Exemplarily, first, a listener is set in the Jira application to monitor changes in the target Issue status. When the target Issue status changes, the listener will trigger an event. After receiving the event, the listener extracts and updates the relevant data to the Jira database. These data may include the target Issue's identifier, the time of the status change, the status before the change, the status after the change, etc. At the same time, the listener sends the target Issue status change event response to the event database through the configured webhook callback mechanism. The webhook callback mechanism can be an HTTP request that sends the event data in JSON format to the API (Application Programming Interface) endpoint of the event database. After receiving the webhook callback request, the API endpoint of the event database parses and extracts the event data, including the Issue ID corresponding to the target Issue, the time when the target Issue was updated, the state before the target Issue was updated, and the state after the target Issue was updated. Then, according to the Issue ID corresponding to the target Issue, the time when the target Issue was updated, the state before the target Issue was updated, and the state after the target Issue was updated, a target state change event is generated and stored in the event database. The event database can be a database dedicated to recording Jira state change events to ensure the integrity and traceability of event responses.
[0069] It is possible to capture the target Issue status change event in the Jira application, update the relevant data to the Jira database, and pass the event response to the event database through the webhook callback mechanism. This can record the change of the target Issue status in real time and ensure the accuracy and consistency of the event data, providing a basis for subsequent analysis and tracking.
[0070] S120, when the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement.
[0071] The event compensation response condition includes a predetermined time interval; the target data includes the status data updated within the predetermined time interval and the corresponding Issue ID. The predetermined time interval may be, but is not limited to, 30 minutes. The Jira query statement may be JQL in Jira.
[0072] JQL (Jira Query Language) is a query language used for advanced search and filtering in Jira, allowing users to define query statements with flexible search conditions to filter out target issues that meet specific requirements. JQL queries can be used in Jira's search bar, as well as in filters, dashboards, and reports.
[0073] The query statements in Jira include, but are not limited to: query statements for searching by time range, query statements for searching by field, query statements for searching by project name, query statements for searching by user name, query statements for searching by time status, and combined query statements.
[0074] Through the query statement in Jira, the target data corresponding to the event compensation response condition within the predetermined time interval is filtered out from the Jira database. Exemplarily, a scheduled task is configured to be triggered every 30 minutes, which can be implemented using the scheduled task function in the task scheduling tool or programming language. After the scheduled task is triggered, a query statement in Jira is used to construct a query to filter out the data within the predetermined time interval. The query statement can be defined according to specific needs, such as filtering data by time range, project name, field query, user name and other conditions. Using the interface or query language in the Jira database, the constructed query is executed to obtain the target data corresponding to the event compensation response condition from the Jira database. The obtained target data can be further processed, analyzed or stored, depending on the specific needs. For example, the target data can be compared with the data in the event database for statistical analysis. Repeat the above steps to obtain the target data corresponding to the event compensation response condition every 30 minutes. The predetermined time interval can be the past 60 minutes of the current time to ensure that the latest status data is obtained.
[0075] It is possible to filter out target data corresponding to the event compensation response conditions from the Jira database through JQL query statements at predetermined time intervals. In this way, Jira status change data can be obtained regularly and processed later to meet the needs of data in a specific time period, such as real-time monitoring, report generation, data analysis, etc.
[0076] S130, comparing the target data with the state change events recorded in the event database to determine whether there is an unresponsive state change event.
[0077] As described in S120, target data corresponding to the event compensation response conditions can be obtained from the Jira database according to conditions such as time range, project name, field query, user name, etc., and collected to form a target data set. For the obtained target data set, the target data set is compared and analyzed with the state change events recorded in the event database to determine whether there are unresponded state change events in the event database.
[0078] In one implementation, when there is no Issue identifier corresponding to the target data in the event database, it is determined that there is an unresponded state change event.
[0079] In one implementation, if there is an Issue identifier corresponding to the target data in the event database, but the status data corresponding to the Issue identifier in the event database is inconsistent with the status data corresponding to the Issue identifier in the target data, it is determined that there is an unresponded status change event.
[0080] The Issue ID is a unique identifier of the Issue. The target data includes the status data updated within a predetermined time interval and the corresponding Issue ID.
[0081] Exemplarily, a comparative analysis can be performed based on the Issue identifier of the target data, the status data corresponding to the Issue identifier, or other key attributes. If the acquired target data set is consistent with the status change events recorded in the event database, that is, there are no unresponded status change events, it can be confirmed that the status change events recorded in the event database are not lost; if the acquired target data set is inconsistent with the status change events recorded in the event database, that is, there are differences, it may be that the target data includes an Issue identifier, which does not exist in the event database, or it may be that the Issue identifier exists in the event database, but the status data corresponding to the Issue identifier in the event database is inconsistent with the status data corresponding to the Issue identifier in the target data. Both possible situations can determine that there are unresponded status change events in the event database.
[0082] S140: When there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to an event database.
[0083] According to the comparison result of the example in S130, the acquired target data set is compared with the state change events recorded in the event database. If there are unresponded state change events, a compensatory response is made to the unresponded state change events, and the unresponded state change events are added to the event database.
[0084] Exemplarily, the compensation response includes executing a predetermined operation corresponding to the target state change event for each unresponded target state change event, such as issuing a reminder notification, triggering code building, or triggering automatic approval.
[0085] Add the state change events of the compensation response to the event database to ensure that all events are recorded. When performing compensation responses and updating the event database, logs can also be recorded for subsequent review and tracking.
[0086] It is possible to obtain the target data corresponding to the event compensation response conditions from the Jira database and compare and analyze them with the state change events recorded in the event database to determine whether any events are lost. This can help ensure the integrity and accuracy of the event data recorded in the event database and promptly detect possible data loss.
[0087] In summary, when the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written into the event database; the target status change event is triggered according to the change in the status of the target Issue; when the event compensation response condition is met, the target data corresponding to the event compensation response condition is filtered out from the Jira database through the Jira query statement; the target data is compared with the status change events recorded in the event database to determine whether there is an unresponded status change event; when there is an unresponded status change event, a compensation response is made to the unresponded status change event, and the unresponded status change event is added to the event database. Through the query statement in the Jira application, the target data corresponding to the event compensation response conditions are filtered out from the Jira database, and the target data is compared with the state change events recorded in the event database. In the case of unresponsive state change events, a compensation response is made to the unresponsive state change events, and the unresponsive state change events are added to the event database, which solves the event missed response caused by the failure of the webhook callback and enhances the reliability of the event response.
[0088] Figure 2 4 is a schematic diagram of a structure of an event response device 400 provided by an embodiment of the present specification, including:
[0089] The storage unit 410 updates the changed state data of the target Issue to the Jira database when the state of the target Issue changes in the Jira application; and responds to the target state change event through the webhook callback mechanism, executes a predetermined operation corresponding to the target state change event and writes the target state change event to the event database; the target state change event is triggered by the change in the state of the target Issue;
[0090] A screening unit 420, when an event compensation response condition is met, screens target data corresponding to the event compensation response condition from the Jira database through a Jira query statement;
[0091] A comparison unit 430 compares the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0092] The processing unit 440 performs a compensation response to the unresponded state change event when there is an unresponded state change event, and adds the unresponded state change event to the event database.
[0093] Optionally, in one implementation, the storage unit 410 is used to:
[0094] The state change events of each Issue are monitored by a listener configured with the webhook callback mechanism, the monitored state change events of the target type are used as the target state change events, and the target state change events are responded to.
[0095] Optionally, in one embodiment, the event compensation response condition includes the passage of a predetermined time interval;
[0096] The target data includes status data updated within a predetermined time interval and a corresponding Issue identifier.
[0097] Optionally, in one implementation, the comparison unit 430 is used to:
[0098] When there is no Issue identifier corresponding to the target data in the event database, it is determined that there is an unresponded state change event; and / or when there is an Issue identifier corresponding to the target data in the event database, and the state data corresponding to the Issue identifier in the event database is inconsistent with the state data corresponding to the Issue identifier in the target data, it is determined that there is an unresponded state change event.
[0099] Optionally, in one implementation, the storage unit 410 is used to:
[0100] Extracting the Issue ID corresponding to the target data, the time when the target data is updated, the state of the target data before being updated, and the state of the target data after being updated;
[0101] The target state change event is generated according to the Issue identifier corresponding to the target data, the time when the target data is updated, the state of the target data before being updated, and the state of the target data after being updated.
[0102] Optionally, in one embodiment, the Jira query statement includes: a query statement for searching by time range, a query statement for searching by field, a query statement for searching by project name, a query statement for searching by user name, a query statement for searching by time status, and at least one of a combination of query statements.
[0103] Optionally, in one implementation, the predetermined operation includes at least one of the following:
[0104] Send out reminder notifications, trigger code builds, and trigger automatic approvals.
[0105] The event response device 400 can achieve Figure 1 For details, please refer to Figure 1 The event response method of the illustrated embodiment will not be described in detail.
[0106] Figure 3 This is a schematic diagram of the structure of an electronic device according to an embodiment of this specification. Figure 3 At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and a memory. The memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage. Of course, the electronic device may also include hardware required for other services.
[0107] The processor, network interface and memory can be interconnected through an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 3 Only one bidirectional arrow is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0108] The memory is used to store the program. Specifically, the program may include a program code, and the program code includes a computer operation instruction. The memory may include a memory and a non-volatile memory, and provides instructions and data to the processor.
[0109] The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming an event response device at the logical level. The processor executes the program stored in the memory and is specifically used to perform the following operations:
[0110] When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue;
[0111] When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement;
[0112] Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0113] In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
[0114] The above is as in this manual Figure 1The method performed by the event response device disclosed in the illustrated embodiment can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in the processor or an instruction in the form of software. The above processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of this specification can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiments of this specification can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution. The software module can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
[0115] The electronic device may also perform Figure 1 The method and the event response device are implemented in Figure 1 The functions of the illustrated embodiments will not be described in detail in the embodiments of this specification.
[0116] Of course, in addition to software implementation, the electronic device of this specification does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
[0117] The embodiment of the present specification also provides a computer-readable storage medium, which stores one or more programs, wherein the one or more programs include instructions, which, when executed by a portable electronic device including a plurality of application programs, enable the portable electronic device to execute Figure 3 The method of the embodiment shown is specifically used to perform the following operations:
[0118] When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue;
[0119] When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement;
[0120] Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event;
[0121] In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
[0122] Of course, in addition to software implementation, the electronic device of this specification does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
[0123] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0124] In short, the above description is only a preferred embodiment of this specification and is not intended to limit the protection scope of this specification. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of this specification shall be included in the protection scope of this specification.
[0125] The systems, devices, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
[0126] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0127] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0128] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
Claims
1. An event response method, characterized in that: The method comprises: When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated to the Jira database; and the target status change event is responded to through the webhook callback mechanism, the predetermined operation corresponding to the target status change event is executed and the target status change event is written to the event database; the target status change event is triggered according to the change of the status of the target Issue; When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement; Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event; In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
2. The method according to claim 1, characterized in that The responding to the target state change event through the webhook callback mechanism includes: The state change events of each Issue are monitored by a listener configured with the webhook callback mechanism, the monitored state change events of the target type are used as the target state change events, and the target state change events are responded to.
3. The method according to claim 1, characterized in that The event compensation response condition includes the passage of a predetermined time interval; The target data includes status data updated within a predetermined time interval and a corresponding Issue identifier.
4. The method according to claim 3, characterized in that The comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event includes: If the Issue identifier corresponding to the target data does not exist in the event database, determining that there is an unresponded state change event; and / or, When there is an Issue identifier corresponding to the target data in the event database and the status data corresponding to the Issue identifier in the event database is inconsistent with the status data corresponding to the Issue identifier in the target data, it is determined that there is an unresponded status change event.
5. The method according to claim 3, characterized in that The method for generating the target state change event in the event database includes: Extracting the Issue ID corresponding to the target data, the time when the target data is updated, the state of the target data before being updated, and the state of the target data after being updated; The target state change event is generated according to the Issue identifier corresponding to the target data, the time when the target data is updated, the state of the target data before being updated, and the state of the target data after being updated.
6. The method according to claim 3, characterized in that The Jira query statement includes: a query statement for searching by time range, a query statement for searching by field, a query statement for searching by project name, a query statement for searching by user name, a query statement for searching by time status, and at least one of a combination of query statements.
7. The method according to any one of claims 1 to 6, characterized in that: The predetermined operation includes at least one of the following: Send out reminder notifications, trigger code builds, and trigger automatic approvals.
8. An event response device, characterized in that: include: A storage unit, when the state of a target Issue in the Jira application changes, updates the changed state data of the target Issue to the Jira database; And responding to the target state change event through the webhook callback mechanism, executing a predetermined operation corresponding to the target state change event and writing the target state change event into an event database; The target state change event is triggered according to the change of the state of the target Issue; A screening unit, when an event compensation response condition is met, screening target data corresponding to the event compensation response condition from the Jira database through a Jira query statement; a comparison unit, comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event; The processing unit performs a compensation response to the unresponded state change event when there is an unresponded state change event, and adds the unresponded state change event to the event database.
9. An electronic device, characterized in that: include: processor; as well as a memory arranged to store computer executable instructions which, when executed, cause the processor to: When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated in the Jira database; And responding to the target state change event through the webhook callback mechanism, executing a predetermined operation corresponding to the target state change event and writing the target state change event into an event database; The target state change event is triggered according to the change of the state of the target Issue; When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement; Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event; In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores one or more programs that, when executed by an electronic device including a plurality of application programs, cause the electronic device to perform the following operations: When the status of the target Issue in the Jira application changes, the changed status data of the target Issue is updated in the Jira database; And responding to the target state change event through the webhook callback mechanism, executing a predetermined operation corresponding to the target state change event and writing the target state change event into an event database; The target state change event is triggered according to the change of the state of the target Issue; When the event compensation response condition is met, target data corresponding to the event compensation response condition is filtered out from the Jira database through a Jira query statement; Comparing the target data with the state change events recorded in the event database to determine whether there is an unresponded state change event; In the case that there is an unresponded state change event, a compensation response is performed on the unresponded state change event, and the unresponded state change event is added to the event database.