Data routing method, device, equipment and computer readable storage medium

文档序号:7645 发布日期:2021-09-17 浏览:26次 中文

1. A data routing method, comprising:

receiving structured data sent by a forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data comprises a device identification of a network camera sending the structured data;

acquiring registration information of at least one target service corresponding to the structured data according to the equipment identification;

and pushing the structured data to each target service respectively according to the registration information of each target service.

2. The method of claim 1, wherein the obtaining registration information of at least one target service corresponding to the structured data according to the device identifier comprises:

determining at least one task type in a task database according to the equipment identifier;

determining the at least one target service corresponding to the at least one task type according to a preset mapping relation between the task type and the service type; each task type corresponds to a target service of at least one service type;

and inquiring the registration information of each target service in the task database.

3. The method according to claim 2, wherein the pushing the structured data to each of the target services according to the registration information of each of the target services comprises:

under the condition that the service type of the target service is an event push type, acquiring a subscription theme corresponding to the target service based on the registration information of the target service;

generating a push event according to the subscription theme and the structured data;

and persisting the push event to a message queue, and pushing the push event to a subscription service corresponding to the subscription theme through the message queue.

4. The method according to claim 2, wherein the pushing the structured data to each of the target services according to the registration information of each of the target services comprises:

under the condition that the service type of the target service is a task pushing type, acquiring address information of the target service based on registration information of the target service; the address information comprises a network address and port information of the target service;

and pushing the structured data to the target service based on the network address and the port information of the target service.

5. The method of claim 4, further comprising:

acquiring parameter information of the target service based on the registration information of the target service; the parameter information comprises service parameters and a data format;

the pushing the structured data to the target service based on the network address and the port information of the target service comprises:

extracting the service parameters from the structured data;

packaging the service parameters according to the data format to obtain packaged data;

and pushing the encapsulated data to the target service based on the network address and the port information of the target service.

6. The method of claim 1, further comprising:

receiving a registration request corresponding to a service to be registered;

and storing the task type and the registration information of the service to be registered carried in the registration request so as to determine the service to be registered as the registered service.

7. The method according to claim 6, wherein the storing the task type and the registration information of the service to be registered carried in the registration request to determine the service to be registered as the registered service comprises:

under the condition that the service type of the service to be registered is a task pushing type, acquiring the task type and the registration information of the service to be registered, which are carried in the registration request; the registration information comprises address information and parameter information;

and storing the task type, the address information and the parameter information of the service to be registered to the task database so as to determine the service to be registered as the registered service.

8. A data routing device, comprising:

the service routing module is used for receiving the structured data sent by the forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data comprises a device identification of a network camera sending the structured data;

the task management module is used for acquiring the registration information of at least one target service corresponding to the structured data according to the equipment identifier;

and the service routing module is further used for pushing the structured data to each target service in a service layer according to the registration information of each target service.

9. A data routing device, comprising:

a memory for storing executable instructions;

a processor for implementing the method of any one of claims 1 to 7 when executing executable instructions stored in the memory.

10. A computer-readable storage medium having stored thereon executable instructions for, when executed by a processor, implementing the method of any one of claims 1 to 7.

Background

With the rapid development of AI (Artificial Intelligence), the integration of Artificial Intelligence and security monitoring industry is also realized after the development and transformation from analog to digital and from digital to high definition in the security monitoring industry. Artificial intelligence is dependent on the development of intelligent IPC (Internet Protocol Camera) on the ground of intelligent business and intelligent security, and the core of the intelligent IPC is an image recognition technology. Through various video intelligent analysis technologies, the problem that the traditional video analysis must depend on manual video viewing is solved. The structured data extraction of effective information is realized, and users of video analysis really leave artificial security and retail and enter a new era of intelligent security and retail.

In the related technology, aiming at application scenes of intelligent IPC such as intelligent retail and intelligent security, a set of data transmission system is realized aiming at each single scene. The data transmission system has more links in the upstream and downstream, for example, the data uploading of the intelligent IPC, and the forwarding of the transit service to each intelligent service in the downstream is customized based on each scene. It can be seen that the data transmission system in the related art cannot realize data transmission in different scenes, and the data transmission system in each scene needs to be developed in a customized manner, so that the development cost and the maintenance cost are high.

Disclosure of Invention

Embodiments of the present application provide a data routing method, apparatus, device, and computer-readable storage medium, which can reduce development cost and maintenance cost of a data transmission system.

The technical scheme of the embodiment of the application is realized as follows:

an embodiment of the present application provides a data routing method, including: receiving structured data sent by a forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data comprises the equipment identification of the network camera sending the structured data; acquiring registration information of at least one target service corresponding to the structured data according to the equipment identifier; and pushing the structured data to each target service respectively according to the registration information of each target service.

In some embodiments of the present application, the obtaining, according to the device identifier, registration information of at least one target service corresponding to the structured data includes: determining at least one task type in a task database according to the equipment identifier; determining at least one target service corresponding to at least one task type according to a preset mapping relation between the task type and the service type; each task type corresponds to a target service of at least one service type; the registration information for each target service is queried in a task database.

In some embodiments of the present application, the pushing the structured data to each target service according to the registration information of each target service respectively includes: under the condition that the service type of the target service is an event push type, acquiring a subscription theme corresponding to the target service based on the registration information of the target service; generating a push event according to the subscription theme and the structured data; and persisting the push event into a message queue, and pushing the push event to the subscription service corresponding to the subscription theme through the message queue.

In some embodiments of the present application, the pushing the structured data to each target service according to the registration information of each target service respectively includes: under the condition that the service type of the target service is a task pushing type, acquiring address information of the target service based on registration information of the target service; the address information comprises a network address and port information of the target service; and pushing the structured data to the target service based on the network address and the port information of the target service.

In some embodiments of the present application, the method further comprises: acquiring parameter information of the target service based on the registration information of the target service; the parameter information comprises service parameters and a data format; the pushing of the structured data to the target service based on the network address and the port information of the target service comprises: extracting service parameters from the structured data; encapsulating the service parameters according to the data format to obtain encapsulated data; and pushing the encapsulated data to the target service based on the network address and the port information of the target service.

In some embodiments of the present application, the method further comprises: receiving a registration request corresponding to a service to be registered; and storing the task type and the registration information of the service to be registered carried in the registration request so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the storing the task type and the registration information of the service to be registered carried in the registration request to determine the service to be registered as the registered service includes: under the condition that the service type of the service to be registered is a task pushing type, acquiring the task type and the registration information of the service to be registered, which are carried in the registration request; the registration information comprises address information and parameter information; and storing the task type, the address information and the parameter information of the service to be registered to a task database so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the storing the task type and the registration information of the service to be registered carried in the registration request to determine the service to be registered as the registered service includes: under the condition that the service type of the service to be registered is an event pushing type, acquiring a task type and an event theme of the service to be registered carried in the registration request; judging whether the registration request is valid according to a mapping relation between a preset task type and a service type; and under the condition that the registration request is valid, storing the task type and the event subject of the service to be registered so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the method further comprises: monitoring a registration information change event of a registered service; in response to the registration information change event, extracting new registration information of the registered service in the registration information change event; the new registration information is stored to complete the update of the registered service.

An embodiment of the present application provides a data routing apparatus, where the apparatus includes:

the service routing module is used for receiving the structured data sent by the forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data comprises a device identification of a network camera sending the structured data;

the task management module is used for acquiring the registration information of at least one target service corresponding to the structured data according to the equipment identifier;

and the service routing module is further used for pushing the structured data to each target service in a service layer according to the registration information of each target service.

An embodiment of the present application provides a data routing device, including:

a memory for storing executable instructions;

and the processor is used for realizing the data routing method provided by the embodiment of the application when the processor executes the executable instructions stored in the memory.

The embodiment of the present application provides a computer-readable storage medium, which stores executable instructions for causing a processor to implement the data routing method provided by the embodiment of the present application when the processor executes the executable instructions.

The embodiment of the application has the following beneficial effects:

according to the embodiment of the application, the forwarding layer receives the structured data sent by all the network cameras, so that the target services corresponding to different scenes can share the forwarding layer to realize the acquisition of the structured data, and the development cost and the maintenance cost of the system are reduced; meanwhile, due to the fact that the device identification corresponding to each structured data is obtained, the registration information of at least one target service corresponding to each structured data can be determined according to the device identification, so that correct routing of each structured data is completed, correct transmission of the structured data when all the network cameras share the same forwarding layer and service routing module is achieved, development cost and maintenance cost can be reduced, different service scenes can be supported, and the application range of the data routing method is expanded.

Drawings

FIG. 1 is a schematic diagram of an alternative architecture of a data routing system according to an embodiment of the present application;

fig. 2 is a schematic structural diagram of a data routing device according to an embodiment of the present application;

fig. 3 is an alternative flow chart of a data routing method provided in the embodiment of the present application;

fig. 4 is an alternative flow chart of a data routing method provided in the embodiment of the present application;

fig. 5 is an alternative flow chart of a data routing method provided in the embodiment of the present application;

fig. 6 is an alternative flow chart of a data routing method according to an embodiment of the present application;

fig. 7 is an alternative flow chart of a data routing method according to an embodiment of the present application;

fig. 8 is an alternative flow chart of a data routing method according to an embodiment of the present application;

fig. 9 is an alternative flow chart of a data routing method according to an embodiment of the present application;

FIG. 10 is a block diagram illustrating an alternative data routing system according to an embodiment of the present application;

fig. 11 is a schematic diagram of an intelligent service registry provided in an embodiment of the present application.

Detailed Description

In order to make the objectives, technical solutions and advantages of the present application clearer, the present application will be described in further detail with reference to the attached drawings, the described embodiments should not be considered as limiting the present application, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.

In the following description, reference is made to "some embodiments" which describe a subset of all possible embodiments, but it is understood that "some embodiments" may be the same subset or different subsets of all possible embodiments, and may be combined with each other without conflict.

In the following description, the terms "first \ second \ third" are used merely for distinguishing similar objects and do not represent specific ordering for the objects, and it is understood that "first \ second \ third" may be interchanged with specific order or sequence where permitted so that the embodiments of the present application described in the present embodiment can be implemented in an order other than that shown or described in the present embodiment.

Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of the present application only and is not intended to be limiting of the application.

Referring to fig. 1, fig. 1 is an alternative architecture diagram of a data routing system 100 provided in this embodiment of the present application, in order to support a data routing application, data receiving terminals (illustratively, a receiving terminal 400-1 and a receiving terminal 400-2) are connected to a server 200 through a network 300, where the network 300 may be a wide area network or a local area network, or a combination of both. Fig. 1 further shows that the server 200 may be a server cluster, where the server cluster includes servers 200-1 to 200-3, and similarly, the servers 200-1 to 200-3 may be physical machines, or virtual machines constructed by using virtualization technologies (such as container technology and virtual machine technology), which is not limited in this embodiment, and of course, a single server may also be used to provide services in this embodiment. The server 200 may receive the structured data sent by the data sender 600 and route the structured data to the corresponding data receiver.

The embodiments of the present application may be implemented by means of Cloud Technology (Cloud Technology), which refers to a hosting Technology for unifying series resources such as hardware, software, and network in a wide area network or a local area network to implement data calculation, storage, processing, and sharing.

The cloud technology is based on the general names of network technology, information technology, integration technology, management platform technology, application technology and the like applied in the cloud computing business model, can form a resource pool, is used as required, and is flexible and convenient. Cloud computing technology will become an important support. Background services of technical network systems require a large amount of computing, storage resources, such as web portals of educational systems.

As an example, the server 200 may be an independent physical server, may be a server cluster or a distributed system formed by a plurality of physical servers, and may also be a cloud server providing basic cloud computing services such as a cloud service, a cloud database, cloud computing, a cloud function, cloud storage, a web service, cloud communication, a middleware service, a domain name service, a security service, a CDN, and a big data and artificial intelligence platform. The terminal may be, but is not limited to, a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, and the like. The terminal and the server 200 may be directly or indirectly connected through wired or wireless communication, and the embodiment of the present application is not limited thereto.

Referring to fig. 2, fig. 2 is a schematic structural diagram of a data routing device 500 according to an embodiment of the present application, where the data routing device 500 shown in fig. 2 includes: at least one processor 510, memory 550, at least one network interface 520, and a user interface 530. The various components in the data routing device 500 are coupled together by a bus system 540. It is understood that the bus system 540 is used to enable communications among the components. The bus system 540 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, however, the various buses are labeled as bus system 540 in fig. 2.

The Processor 510 may be an integrated circuit chip having Signal processing capabilities, such as a general purpose Processor, a Digital Signal Processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like, wherein the general purpose Processor may be a microprocessor or any conventional Processor, or the like.

The user interface 530 includes one or more output devices 531 enabling presentation of media content, including one or more speakers and/or one or more visual display screens. The user interface 530 also includes one or more input devices 532, including user interface components to facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.

The memory 550 may comprise volatile memory or nonvolatile memory, and may also comprise both volatile and nonvolatile memory. The non-volatile Memory may be a Read Only Memory (ROM), and the volatile Memory may be a Random Access Memory (RAM). The memory 550 described in embodiments herein is intended to comprise any suitable type of memory. Memory 550 optionally includes one or more storage devices physically located remote from processor 510.

In some embodiments of the present application, memory 550 can store data to support various operations, examples of which include programs, modules, and data structures, or subsets or supersets thereof, as exemplified below.

An operating system 551 including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;

a network communication module 552 for communicating to other computing devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 including: bluetooth, wireless compatibility authentication (WiFi), and Universal Serial Bus (USB), etc.;

a display module 553 for enabling presentation of information (e.g., a user interface for operating peripherals and displaying content and information) via one or more output devices 531 (e.g., a display screen, speakers, etc.) associated with the user interface 530;

an input processing module 554 to detect one or more user inputs or interactions from one of the one or more input devices 532 and to translate the detected inputs or interactions.

In some embodiments of the present application, the data routing apparatus provided in the embodiments of the present application may be implemented by a combination of hardware and software, and for example, the data routing apparatus provided in the embodiments of the present application may be a processor in the form of a hardware decoding processor, which is programmed to execute the data routing method provided in the embodiments of the present application.

In some embodiments of the present application, the data routing apparatus provided in the embodiments of the present application may be implemented in software, and fig. 2 shows a data routing apparatus 555 stored in a memory 550, which may be software in the form of programs and plug-ins, and includes the following software modules: a service routing module 5551, a task management module 5552 and a registration module 5553, which are logical and thus can be arbitrarily combined or further split depending on the implemented functionality.

The functions of the respective modules will be explained below.

In other embodiments, the apparatus provided in the embodiments of the present Application may be implemented in hardware, and for example, the apparatus provided in the embodiments of the present Application may be a processor in the form of a hardware decoding processor, which is programmed to execute the data routing method provided in the embodiments of the present Application, for example, the processor in the form of the hardware decoding processor may be one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable Logic Devices (PLDs), Complex Programmable Logic Devices (CPLDs), Field Programmable Gate Arrays (FPGAs), or other electronic components.

In this embodiment of the present application, a data routing method provided in this embodiment of the present application will be described with a server as an execution subject.

Referring to fig. 3, fig. 3 is an alternative flowchart of a data routing method provided in the embodiment of the present application, and will be described with reference to the steps shown in fig. 3.

In step 301, receiving structured data sent by a forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data includes the device identification of the network camera that sent the structured data.

In some embodiments of the present application, the forwarding layer is connected to at least one webcam. After each network camera collects real-time data, the structured data corresponding to the network camera is generated according to the own equipment identification and the real-time data, and the generated structured data is sent to the forwarding layer. After receiving the structured data sent by at least one network camera, the forwarding layer extracts the device identifier carried in each structured data to determine the device identifier corresponding to each structured data.

It should be noted that, since the corresponding network camera can be determined by the device identifier, the camera information of each network camera is also determined, and the camera information may include a camera type, a camera location, a camera function, and the like. Therefore, after the device identification is obtained, the specific use of the corresponding structured data can be known.

In some embodiments of the present application, the network camera is a smart camera, and the smart camera can perform preliminary smart recognition on the original video on the basis of acquiring the original video. The original video is unstructured data, and a target object in the original video can be identified only by manual watching and cannot be directly read and identified by electronic equipment. Thus, the smart camera accomplishes the extraction of this structured data by analyzing the original video. The structured data of the original video can be extracted by adopting analysis means such as target detection, feature extraction, object recognition, deep learning and the like, and the structured data can comprise mark information of a target object, track information of the target object and the like.

In step 302, registration information of at least one target service corresponding to the structured data is obtained according to the device identifier.

In some implementations of the present application, the server can determine, from the device identification, at least one target service that requires use of the structured data. The acquisition step of the registration information of at least one target service can be realized by the following method, that is, an inquiry request is sent to a storage layer, so that the storage layer determines a service identifier of at least one target service corresponding to an equipment identifier according to a matching relationship between the equipment identifier carried in the inquiry request and storage, and acquires the registration information of the corresponding at least one target service according to the at least one service identifier. The storage layer may be disposed in the server, may be disposed in other services for storing data, and may implement storage of the matching relationship through a Redis database, where the matching relationship includes a matching relationship between each device identifier in the plurality of device identifiers and at least one target service.

In some embodiments of the present application, the registration information is used to determine an interface address at which the target service receives structured data. The structured data may be received by the target services via the interface address, the interface address of each target service being unique.

In some embodiments of the present application, the target service may be an event push type service or a task push type service.

And when the target service is a task push type service, the task push type service generates an analysis task according to the received structured data, and the analysis task is used for further analyzing the structured data to generate an analysis result under a scene corresponding to the target service. The analysis task often needs to be completed by the analysis server in the scenario corresponding to the target service, and therefore, the registration information may include the network address and the port information corresponding to the target service, that is, the network address and the port information corresponding to the analysis server. The task push type services include, but are not limited to, at least one of: security deployment and control, security construction, security passerby bank protection, commercial passenger flow analysis, security snapshot pushing, commercial preview pushing and commercial self-registration.

And under the condition that the target service is an event push type service, the event push type service directly generates an event task according to the received structured data, stores the event task into a message queue, and pushes the event task to at least one subscriber subscribed to the event task through the message queue. Therefore, the registration information may be a subscription topic corresponding to the target service. The event push type service includes, but is not limited to, at least one of: and pushing a security snapshot picture and a business preview picture.

In some embodiments of the present application, a correspondence between a device identifier and a target service may be that one device identifier corresponds to at least one target service, or that multiple device identifiers correspond to one target service.

In step 303, the structured data is pushed to each target service according to the registration information of each target service.

In some embodiments of the present application, according to the registration information of each target service corresponding to the device identifier, since the registration information is used to determine an interface address of the target service for receiving the structured data, the structured data can be pushed to each target service through each registration information.

As can be seen from the foregoing exemplary implementation of fig. 3 in the embodiment of the present application, the forwarding layer receives structured data sent by all the network cameras, so that target services corresponding to different scenes can share the forwarding layer to achieve acquisition of the structured data, and development cost and maintenance cost of the system are reduced; meanwhile, due to the fact that the device identification corresponding to each structured data is obtained, the registration information of at least one target service corresponding to each structured data can be determined according to the device identification, so that correct routing of each structured data is completed, correct transmission of the structured data when all the network cameras share the same forwarding layer and service routing module is achieved, development cost and maintenance cost can be reduced, different service scenes can be supported, and the application range of the data routing method is expanded.

In some embodiments of the present application, referring to fig. 4, fig. 4 is an optional flowchart of the data routing method provided in this embodiment of the present application, and based on fig. 3, step 302 shown in fig. 3 may be updated to step 401 to step 403, which will be described in conjunction with the steps shown in fig. 4.

In step 401, at least one task type is determined in a task database based on the device identification.

In some embodiments of the present application, the task database may be provided in the server; the task database can also be provided only in a storage layer for storing data, which storage layer can be implemented by at least one storage database.

In some embodiments of the present application, for all the network cameras connected to the forwarding layer, a task type corresponding to the device identifier of each network camera is set in the task database. The device identifier of one network camera may correspond to at least one task type.

For example, the task types may include 7 task types including security deployment and control, security filing, a security passerby library, business passenger flow analysis, security snapshot pushing, business preview pushing, and business self-registration, and for the device identifier X1 of one network camera, the device identifier X1 may correspond to only one task type, or may correspond to two or more task types. For example, the device identification X1 may correspond to a security administration; the device identification X1 may also correspond to a commercial preview push and a commercial self-registration at the same time.

In step 402, determining at least one target service corresponding to at least one task type according to a preset mapping relationship between the task type and the service type; each task type corresponds to a target service of at least one service type.

In some embodiments of the present application, for each task type in the task database, each task type may correspond to at least one service type. That is, in the case that the service type includes two service types, namely an event push type and a task push type, one task type may correspond to only the event push type, only the task push type, and both the event push type and the task push type. Accordingly, the at least one target service may include a target service corresponding to each task type.

For example, based on the above example, in the case that the task types may include security deployment, security filing, security passerby library, business passenger flow analysis, security snapshot pushing, business preview pushing, and business self-registration, where the security deployment, the security filing, the security passerby library, the business passenger flow analysis, and the business self-registration may correspond to only one service type (task pushing type), and the security snapshot pushing and the business preview pushing may correspond to two service types at the same time. In a case that the device identifier X1 may also correspond to both the business preview push and the business self-registration, the target service corresponding to the device identifier X1 may include a target service whose task type is the business preview push and whose service type is the event push type, a target service whose task type is the business preview push and whose service type is the task push type, and a target service whose task type is the business self-registration push and whose service type is the task push type.

In step 403, the registration information for each target service is queried in the task database.

In some embodiments of the present application, after determining at least one target service corresponding to the device identifier, registration information corresponding to the service identifier may be obtained in the task database according to the service identifier corresponding to each target service, so as to determine the registration information of each target service.

As can be seen from the foregoing exemplary implementation of fig. 4 in the embodiment of the present application, by setting a mapping relationship between a task type and a service type in a task database, after at least one task type corresponding to the device identifier is obtained, at least one target service corresponding to the device identifier may be further determined, so that different service types are implemented. The target services of different task types share the structured data sent by one network camera, so that the adaptability to complex application scenes is improved; and, according to the registration information of each target service stored by the task database, a data base can be provided for the correct routing of the subsequent structured data.

In some embodiments of the present application, referring to fig. 5, fig. 5 is an optional flowchart of a data routing method provided in this embodiment of the present application, and based on fig. 4, step 303 shown in fig. 4 may be updated to be step 501 to step 503, which will be described in conjunction with the steps shown in fig. 5.

In step 501, when the service type of the target service is an event push type, a subscription theme corresponding to the target service is acquired based on the registration information of the target service.

In some embodiments of the present application, in a case that the service type of the target service is an event push type, the registration information corresponding to the target service is a subscription topic (topic) corresponding to the target service. The subscription theme corresponding to each target service is preset by the administrator.

In step 502, a push event is generated from the subscription topic and the structured data.

In some embodiments of the present application, for the target service of the event push type, the target service only pushes the original structured data as an event message to a subscriber subscribing to the target service, and therefore, the server does not need to further process the structured data, and only needs to generate a push event by using the subscription theme corresponding to the target service and the structured data.

In step 503, the push event is persisted in a message queue, and the push event is pushed to the subscription service corresponding to the subscription topic through the message queue.

In some embodiments of the present application, the message queue is configured to push an event in the queue to a subscription service corresponding to the event carrying subscription topic. The subscription service corresponding to the subscription theme is used for pushing an event to at least one subscriber subscribing to the subscription theme. The message queue may be implemented by a kafka cluster.

For example, if the subscription topic corresponding to the target service is topicA, the server generates a corresponding push event according to topicA and the structured data, and stores the push event into a message queue in the kafka cluster, where the message queue may determine at least one subscriber who subscribes to topicA according to a preset push rule during the process of pushing the push event, and push the push event to the at least one subscriber.

As can be seen from the above exemplary implementation of fig. 5 in the embodiment of the present application, by obtaining a subscription theme of a target service of an event push type, generating a push event based on the subscription theme and structured data, and pushing the push event to at least one subscriber subscribing to the subscription theme through a preset message queue, a data push form of the data routing method of the present application is increased, and due to the adoption of the event push method, the push efficiency of the structured data can be improved.

In some embodiments of the present application, referring to fig. 6, fig. 6 is an optional flowchart of a data routing method provided in this embodiment of the present application, and based on fig. 4, step 303 shown in fig. 4 may be updated to be step 601 to step 603, which will be described in conjunction with the steps shown in fig. 6.

In step 601, when the service type of the target service is a task push type, acquiring address information of the target service based on registration information of the target service; the address information includes a network address and port information of the target service.

In some embodiments of the present application, in a case that a service type of a target service is a task push type, the registration information includes a network address and port information corresponding to the target service. The registration information may be obtained by the server through a service registration request sent by the target service in the process of registering the target service with the server.

In step 602, structured data is pushed to the target service based on the network address and port information of the target service.

In some embodiments of the present application, each target service corresponds to a network address and port information, and the target service may receive structured data corresponding to the target service through the network address and the port information, and further analyze and process the structured data to obtain an analysis result.

As can be seen from the foregoing exemplary implementation of fig. 6 in the embodiment of the present application, by acquiring the network address and the port information of the target service in the task push type and pushing the structured data to the target service based on the network address and the port information of the target service, a data push form of the data routing method in the present application is increased.

In some embodiments of the present application, referring to fig. 7, fig. 7 is an optional flowchart of a data routing method provided in this embodiment of the present application, and based on fig. 4, step 303 shown in fig. 4 may be updated to be step 701 to step 703, which will be described in conjunction with the steps shown in fig. 7.

In step 701, when the service type of the target service is a task push type, address information and parameter information of the target service are acquired based on registration information of the target service; the parameter information comprises service parameters and a data format; the address information includes a network address and port information of the target service.

In some embodiments of the present application, the registration information may be obtained by the server through a service registration request sent by the target service during the registration process of the target service with the server. The registration information is used for determining a transmission path of the structured data, and the parameter information is used for determining a processing method of the structured data.

It should be noted that, for the original structured data, all the analysis data corresponding to the original camera data may be included, but for the target service in a specific scene, all the analysis data is not needed, and the original structured data is not needed, so that the original structured data may be subjected to processing such as screening, reorganization, and encapsulation according to the parameter information before being transmitted to the target service.

In step 702, extracting service parameters from the structured data; encapsulating the service parameters according to the data format to obtain encapsulated data; and pushing the encapsulated data to the target service based on the network address and the port information of the target service.

In some embodiments of the present application, parameters required by the target service are determined based on the service parameters, parameters other than the service parameters are removed from the structured data, and only the service parameters are reserved to complete the extraction of the service parameters.

In some embodiments of the present application, the extracted service parameters are encapsulated according to the data format to obtain corresponding encapsulated data. And pushing the encapsulated data to the target service through the network address and the port information of the target service. The data format may be a data packaging method, an encryption method, and the like. The service parameters can be further encapsulated through the data format, and encapsulated data which can be identified only by the target service is generated, so that the transmission safety of the service parameters is improved.

For example, if the original structured data includes pedestrian analysis data, road analysis data and vehicle analysis data, if the target service is a security road-pedestrian base type, the service parameter corresponding to the target service is the pedestrian analysis data, and therefore, based on the service parameter, the original structured data may be processed to obtain the road analysis data and the vehicle analysis data which are not needed, and the pedestrian analysis data may be encapsulated according to the data format corresponding to the target service to obtain the encapsulated data only including the pedestrian analysis data.

As can be seen from the foregoing exemplary implementation of fig. 7, in the embodiment of the present application, by obtaining the service parameter of the target service of each task push type, the original structured data may be processed, invalid data that is not needed by the target service is removed, and only the service parameter that is needed by the target service is transmitted, so that the data amount of network transmission may be saved, and the routing efficiency may be improved while the bandwidth is saved; meanwhile, the data format of the target service of each task push type is obtained, and the service parameters of each target service are further encapsulated according to the data format, so that the data format requirements of the target service can be met, and the data transmission safety can be improved.

In some embodiments of the present application, referring to fig. 8, fig. 8 is an optional flowchart of a data routing method provided in the embodiments of the present application, based on fig. 3 and the above embodiments, step 801 and step 802 may be further included between any steps, which will be described with reference to the steps shown in fig. 8 by taking the step 303 in fig. 3 as an example.

In step 801, a registration request corresponding to a service to be registered is received.

In some embodiments of the present application, the server may further include a service registry, which is an extensible registry plug-in the server, and in the case that the registry plug-in is installed in the server, the registration function of the service to be registered may be supported.

In step 802, the task type and the registration information of the service to be registered carried in the registration request are stored, so that the service to be registered is determined to be the registered service.

In some embodiments of the present application, the above step 802 may be implemented by: in step 8021, when the service type of the service to be registered is the task push type, the task type and the registration information of the service to be registered, which are carried in the registration request, are acquired; the registration information comprises address information and parameter information; and storing the task type, the address information and the parameter information of the service to be registered to a task database so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the above step 802 may be implemented by: in step 8022, when the service type of the service to be registered is the event push type, the task type and the event topic of the service to be registered carried in the registration request are obtained; judging whether the registration request is valid according to a mapping relation between a preset task type and a service type; and under the condition that the registration request is valid, storing the task type and the event subject of the service to be registered so as to determine the service to be registered as the registered service.

As can be seen from the foregoing exemplary implementation of fig. 8 in the embodiment of the present application, by receiving a registration request of a service to be registered, and implementing a registration process of the service to be registered according to a task type and registration information in the registration request, scalability of the data routing method in the present application is implemented, and in a case where a new service is required, it is only necessary to store the task type and the registration information of the service to be registered carried in the registration request, and the registration process of the new service can be completed without performing customized development on the new service.

In some embodiments of the present application, referring to fig. 9, fig. 9 is an optional flowchart of a data routing method provided in the embodiments of the present application, based on fig. 3 and the above embodiments, step 901 and step 902 may be further included between any steps, which will be described with reference to the steps shown in fig. 9 by taking the step 303 in fig. 3 as an example.

In step 901, a registration request corresponding to a service to be registered is received.

In step 902, the task type and the registration information of the service to be registered carried in the registration request are stored, so as to determine the service to be registered as the registered service.

In some embodiments of the application, under the condition that the service type of the service to be registered is a task push type, the task type and the registration information of the service to be registered, which are carried in the registration request, are acquired; the registration information comprises address information and parameter information; and storing the task type, the address information and the parameter information of the service to be registered to a task database so as to determine the service to be registered as the registered service.

In some embodiments of the application, under the condition that the service type of the service to be registered is an event push type, the task type and the event theme of the service to be registered carried in the registration request are acquired; judging whether the registration request is valid according to a mapping relation between a preset task type and a service type; and under the condition that the registration request is valid, storing the task type and the event subject of the service to be registered so as to determine the service to be registered as the registered service.

In step 903, registration information change events of registered services are monitored.

In some embodiments of the present application, the registration information change event may be monitored through a service discovery mechanism. After the registered service is registered, a heartbeat message needs to be reported to the server periodically, and the server can determine whether the registered service is alive according to the heartbeat message. Wherein the service discovery mechanism may be implemented by a zookeeper component.

In step 904, new registration information for the registered service in the registration information change event is extracted in response to the registration information change event.

In some embodiments of the present application, the server may implement monitoring of the registered service by subscribing to registration information change events of the registered service. After the registration information of the registered service changes, a registration information change event carrying new registration information is reported through a service discovery mechanism. The server, as a service consumer subscribing to the event, may obtain the new registration information through the registration information change event. Accordingly, the registered service is a service provider.

In step 905, the new registration information is stored to complete the update of the registered service.

In some embodiments of the present application, while storing the new registration information, the historical registration information stored before the registered service is deleted, and in the subsequent route forwarding process, the routing of the structured data is completed according to the new registration information.

As can be known from the above exemplary implementation of fig. 9 in the embodiment of the present application, by monitoring the registration information change event of each registered service, the embodiment of the present application can update the registered service in the server in real time when the registered service has data change, network address change, or disconnection change, so as to facilitate correct routing of subsequent structured data.

Next, an exemplary application of the embodiment of the present application in a practical application scenario will be described.

In recent years, big data, cloud computing, new generation information technology has become the "standard allocation" for advanced business enterprise operations. The intelligent business becomes a new development trend, and a plurality of business enterprises can arrange the intelligent business territory in a dispute. Among them, artificial intelligence is widely used in more and more commercial fields. The business enterprises use the powerful data collection and analysis capability of artificial intelligence, for example, member automatic identification, passenger flow attribute statistics including age, gender and the like, passenger flow thermodynamic diagram analysis to check the position where the user stays for the longest time and the like can be performed, so that personalized recommendation is further performed for the user, better profit is achieved, and the user experience is optimized.

In the high-speed development of the last 20 years, the security industry has undergone the development change from simulation to digital and from digital to high definition, and the 'security AI original year' is introduced in 2017. Although the overall level of artificial intelligence is still in its infancy, it does not prevent artificial intelligence from gaining widespread use in certain fields (such as security) and with great success. The artificial intelligence depends on the development of intelligent IPC on the intelligent business and intelligent security, the intelligent IPC is a new generation of network cameras, and the core of the intelligent IPC is an image recognition technology. Through various video intelligent analysis technologies, the problem that the traditional video analysis needs to depend on manual video viewing is solved, the structured data extraction of effective information is realized, and users of the video analysis really stand for manual security and retail and enter a new era of intelligent security and smart retail.

At present, aiming at application scenes of intelligent IPC, such as intelligent retail and intelligent security, a set of system is realized aiming at each single scene. The system has more links in upstream and downstream, for example, data uploading of intelligent IPC, and forwarding of the transit service to each intelligent service in the downstream is customized based on each scene. However, in fact, two different scenarios of intelligent retail and intelligent security are only different application scenarios, specifically, only the most downstream intelligent services (including security deployment and control, face profiling, business self-registration, business passenger flow statistics, etc.) are different, and the forwarding of the intelligent IPC data uploading and the forwarding of the transit service are the same in different scenarios. The inability to multiplex upstream and downstream services under different scenarios can bring about a lot of additional overhead.

Existing solutions are generally based on a specific application scenario such as intelligent business, customized development from intelligent IPC data upload to relay service forwarding. The scheme can lead to the customized development of how many application scenes exist, so that the maintenance cost and the development cost are greatly increased, and meanwhile, the landing cost of intelligent business and intelligent security scenes is also increased.

In view of the above problems and the drawbacks of the existing solutions, the applicant has developed a data routing method and a data routing system after research.

Please refer to fig. 10, which shows an architecture diagram of a data routing system, wherein the data routing system a10 includes an access forwarding layer a11, a service routing module a12, a task management module a13, and a service layer a 14.

The service routing module A12 is a bus-type intelligent data routing module facing to IPC video stream, and as the bus-type intelligent data routing module, it can provide IPC video stream routing for all intelligent services in two large scenes including business and security. The bus type intelligent routing module comprises pushing of business/security events (events) and bus type data routing of intelligent services of different scenes (business and security). In this embodiment of the present application, the service routing module may support data routing for multiple types of tasks, where the supported task types may include: security deployment and control, security construction, security passerby bank protection, commercial passenger flow analysis, security snapshot image pushing, commercial preview image pushing and commercial self-registration.

Upstream of the service routing module a12 is an access forwarding layer a11, where the access forwarding layer is configured to receive smart camera data sent by at least one network camera, where the smart camera data may be video stream data, image data, text data, and the like.

Downstream of the service routing module a12 is a service layer a14, wherein the service layer a14 may include task push type services and event push type services. The task push type service is an intelligent service with AI algorithm capability, such as face recognition, automatic filing and the like.

The service routing module a12 may also be connected to a task management module a13, where the task management module a13 is configured to write task data into the storage tier a15 to facilitate the service routing module a12 querying the storage tier a15 for real-time tasks. The task management module a13 is further configured to issue the real-time task to the access forwarding layer a11, so that the access forwarding layer a11 obtains the smart camera data corresponding to the real-time task.

Among these, the automatic service discovery in fig. 10 is applied to two places in the present embodiment: 1) the access forwarding layer can find the intelligent service scheduling module and obtain the ip address of the intelligent service scheduling module; 2) the intelligent service scheduling module interacts with downstream intelligent services. A zookeeper component implementation may be relied upon.

The distributed service framework performs registration and dynamic discovery of services based on service names by means of zookeeper, which exists as a service registry. The idea is that a service provider registers service to zookeeper, and periodically reports heartbeat information to a service registration center to prove that the service provider lives. The service consumer, namely the client, acquires the registration information of the service when starting, and subscribes to data and node change under a certain path, so that once the service provider changes, the zookeeper informs the service consumer, and the service consumer updates the locally cached downstream service address information.

The access forwarding layer sends data to the intelligent service scheduling module, which can also be understood as that the intelligent service scheduling module is a service provider, and the upstream access forwarding layer is a service consumer. The intelligent service scheduling module sends data to the downstream intelligent service module, and it can also be understood that the downstream intelligent service is a service provider, and the upstream intelligent service scheduling module is a service consumer.

In some embodiments of the present application, the data of the smart camera, which is received by the access forwarding layer a11 and sent by the network camera, is JSON data, and the JSON data of the access forwarding layer a11 is original data of the IPC video stream. The smart camera data may include device identification data ("did" field) and structured data ("payload" field). Wherein, the 'did' field represents the unique equipment identification (IPC device id) of the intelligent camera, namely the equipment information; the "payload" field is then all the smart data carried by the smart camera data.

Here, the JSON data is only formatted by the access forwarding layer a11, and includes device identification data and structured data. Each JSON data corresponds to device identification data and structured data. The structured data is attribute data corresponding to the identified object in the data of the smart camera. For example, if the object is a pedestrian, the corresponding attribute data may be age, gender, height, clothing, and the like.

In some embodiments of the present application, the service routing module a12 receives JSON data of the upstream access forwarding layer a11, obtains "did" information in the JSON data, and performs a query of a real-time task according to interaction between the "did" information and the task management module a13 through the storage layer a 15. The storage layer a15 may be implemented by a Redis database, and in the process of querying the database, the "did" information may be used as a matching condition (key) to query specific "action" information. Each "action" represents a different intelligent service, such as A141, which illustratively shows intelligent services such as "profiling", "self-registration", and "business analysis". When a specific intelligent service task to be executed is inquired, the service routing module a12 processes the "payload" information in the JSON data, wherein the obtained "payload" information can be screened, recombined and encapsulated according to the registration information of each intelligent service to the intelligent service routing module, so as to route the intelligent service a141 in the service layer a14 according to an agreed data format.

At least one task exists in the database in the storage layer a15, and each task includes a correspondence between a service and a plurality of devices, that is, each task includes a correspondence between one service and a plurality of device identifiers. The service routing module a12 may forward the received JSON data to the target service corresponding to the device identifier according to the correspondence in the database.

In some embodiments of the present application, in addition to the smart service a141, the data of the smart camera received from the access forwarding layer a11 may not be processed by the service routing module a12, for example, a business screenshot and a security snapshot are not processed by the service routing module a12, and the service routing module a12 directly pushes an event. Wherein the event may be persisted to the message queue of kafka cluster a 142.

As can be seen from the above embodiments, the service routing module a12 functions similarly to a "data bus" to provide routing services for the upstream smart camera data and the downstream message queues in each type of smart service a141 or kafka cluster a 142.

In some embodiments of the present application, the data routing system a10 may also include an intelligent service registry that supports other custom routing task registrations for extensible registry plug-ins in the service routing module a12 to enable extensible capabilities of the service routing module. The intelligent service registry acts as a plug-in that supports registration by modifying configuration files. When a new intelligent service a141 registers with the service routing module a12, path information of the intelligent service needs to be provided, so that the service routing module a12 can obtain address information of the intelligent service, wherein the address information includes a port and an IP address.

Please refer to fig. 11, which shows a schematic diagram of the intelligent service registry, wherein the intelligent service registry B11 can receive a registration request from the service provider B12, and during the process of registering with the intelligent service registry B11, the intelligent service provider B12 needs to send a registration request carrying registration information to the intelligent service registry B11. Wherein, the registration information includes the service parameters and data format of the intelligent service corresponding to the service provider B12. In the actual routing process, the service consumer B13 may be the service routing module in the foregoing embodiment, and the service consumer B13 may process the obtained smart camera data according to the registration information, specifically, may filter and reassemble the smart camera data according to the service parameter, encapsulate the filtered and reassembled smart camera data according to the data format, and finally send the encapsulated data to the service provider B12.

In some embodiments of the present application, the service routing module a12 acts as a hub and hub for data transmission, supporting data relay throughout the system. Because the requirements on the performance can be high, after the research, the applicant also makes many performance optimization and high-availability designs. The data routing system provided by the application adopts an asynchronous communication mode design, an LRU cache mechanism which introduces a thread pool and increases thread safety and the like, and can support the processing of a forwarding request of 4000+ intelligent camera data per second, namely, the routing of the 4000+ intelligent camera data is completed. Meanwhile, the high-availability optimization of the kafka cluster mode, the redis sentry mode, the zkclient c + + sdk automatic disconnection reconnection, the probe mode service state monitoring and the like is added, the stability of the data routing system can be improved, and automatic disaster recovery can be realized.

By the data routing method and the data routing system provided by the embodiment, various typical intelligent service data routes and event push routes in two scenes of business and security can be covered; meanwhile, the intelligent service register is provided, and is an extensible register plug-in, so that other self-defined service registration can be supported, and the extensibility of the service routing module is realized; due to the adoption of the universal module design, different service scenes can be supported, customized development is not needed, and the development cost and the maintenance cost are saved.

Continuing with the exemplary structure of the data routing device 555 implemented as a software module provided by embodiments of the present application, in some embodiments of the present application, as shown in fig. 2, the software module stored in the data routing device 555 in the memory 550 may include:

the service routing module 5551 is configured to receive the structured data sent by the forwarding layer; the forwarding layer is used for receiving the structured data sent by at least one network camera; the structured data comprises a device identification of a network camera sending the structured data;

the task management module 5552 is configured to obtain registration information of at least one target service corresponding to the structured data according to the device identifier;

the service routing module 5551 is further configured to push the structured data to each of the target services in a service layer according to the registration information of each of the target services.

In some embodiments of the present application, the task management module 5552 is further configured to determine at least one task type in a task database according to the device identifier; determining at least one target service corresponding to at least one task type according to a preset mapping relation between the task type and the service type; each task type corresponds to a target service of at least one service type; the registration information for each target service is queried in a task database.

In some embodiments of the present application, the service routing module 5551 is further configured to, when the service type of the target service is an event push type, obtain a subscription theme corresponding to the target service based on the registration information of the target service; generating a push event according to the subscription theme and the structured data; and persisting the push event into a message queue, and pushing the push event to the subscription service corresponding to the subscription theme through the message queue.

In some embodiments of the present application, the service routing module 5551 is further configured to, when the service type of the target service is a task push type, obtain address information of the target service based on registration information of the target service; the address information comprises a network address and port information of the target service; and pushing the structured data to the target service based on the network address and the port information of the target service.

In some embodiments of the present application, the service routing module 5551 is further configured to obtain parameter information of the target service based on registration information of the target service; the parameter information comprises service parameters and a data format; extracting service parameters from the structured data; encapsulating the service parameters according to the data format to obtain encapsulated data; and pushing the encapsulated data to the target service based on the network address and the port information of the target service.

In some embodiments of the present application, the data routing device 555 also includes a registration module 5553.

The registration module 5553 is configured to receive a registration request corresponding to a service to be registered; and storing the task type and the registration information of the service to be registered carried in the registration request so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the registration module 5553 is further configured to, when the service type of the service to be registered is a task push type, obtain a task type and registration information of the service to be registered, where the task type and the registration information are carried in the registration request; the registration information comprises address information and parameter information; and storing the task type, the address information and the parameter information of the service to be registered to a task database so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the registration module 5553 is further configured to, when the service type of the service to be registered is an event push type, obtain a task type and an event topic of the service to be registered, where the task type and the event topic are carried in the registration request; judging whether the registration request is valid according to a mapping relation between a preset task type and a service type; and under the condition that the registration request is valid, storing the task type and the event subject of the service to be registered so as to determine the service to be registered as the registered service.

In some embodiments of the present application, the registration module 5553 is further configured to monitor a registration information change event of a registered service; in response to the registration information change event, extracting new registration information of the registered service in the registration information change event; the new registration information is stored to complete the update of the registered service.

Embodiments of the present disclosure provide a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the data routing method described in the embodiment of the present application.

Embodiments of the present disclosure provide a computer-readable storage medium having stored therein executable instructions that, when executed by a processor, will cause the processor to perform a data routing method provided by embodiments of the present disclosure, for example, the method as illustrated in fig. 3 to 9.

In some embodiments of the present application, the computer readable storage medium may be memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.

In some embodiments of the application, the executable instructions may be in the form of a program, software module, script, or code, written in any form of programming language, including compiled or interpreted languages, or declarative or procedural languages, and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

By way of example, executable instructions may correspond, but do not necessarily have to correspond, to files in a file system, and may be stored in a portion of a file that holds other programs or data, such as in one or more scripts in a hypertext Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files that store one or more modules, sub-programs, or portions of code).

By way of example, executable instructions may be deployed to be executed on one computing device or on multiple computing devices at one site or distributed across multiple sites and interconnected by a communication network.

In summary, the following technical effects can be achieved through the embodiments of the present application:

(1) according to the embodiment of the application, the forwarding layer receives the structured data sent by all the network cameras, so that the target services corresponding to different scenes can share the forwarding layer to realize the acquisition of the structured data, and the development cost and the maintenance cost of the system are reduced; meanwhile, due to the fact that the device identification corresponding to each structured data is obtained, the registration information of at least one target service corresponding to each structured data can be determined according to the device identification, so that correct routing of each structured data is completed, correct transmission of the structured data when all the network cameras share the same forwarding layer and service routing module is achieved, development cost and maintenance cost can be reduced, different service scenes can be supported, and the application range of the data routing method is expanded.

(2) According to the method and the device for determining the task type, the mapping relation between the task type and the service type is set in the task database, and after at least one task type corresponding to the equipment identification is obtained, at least one target service corresponding to the equipment identification can be further determined, so that different service types are achieved. The target services of different task types share the structured data sent by one network camera, so that the adaptability to complex application scenes is improved; and, according to the registration information of each target service stored by the task database, a data base can be provided for the correct routing of the subsequent structured data.

(3) According to the data pushing method and the data routing device, the subscription theme of the target service of the event pushing type is obtained, the pushing event is generated based on the subscription theme and the structured data, the pushing event is pushed to at least one subscriber subscribing the subscription theme through the preset message queue, the data pushing mode of the data routing method is increased, and due to the fact that the event pushing method is adopted, the pushing efficiency of the structured data can be improved.

(4) According to the data pushing method, the network address and the port information of the task pushing type target service are obtained, the structured data are pushed to the target service based on the network address and the port information of the target service, the data pushing mode of the data routing method is increased, due to the fact that the task pushing method is adopted, the task pushing type target service can conveniently obtain accurate structured data, a corresponding intelligent analysis result is generated, and the pushing efficiency of the structured data is improved.

(5) According to the method and the device, the original structured data can be processed by acquiring the service parameters of the target service of each task push type, invalid data which are not needed by the target service are removed, only the service parameters needed by the target service are transmitted, the data volume of network transmission can be saved, the bandwidth is saved, and meanwhile, the routing efficiency can be improved; meanwhile, the data format of the target service of each task push type is obtained, and the service parameters of each target service are further encapsulated according to the data format, so that the data format requirements of the target service can be met, and the data transmission safety can be improved.

(6) According to the embodiment of the application, the registration request of the service to be registered is received, the registration process of the service to be registered is realized according to the task type and the registration information in the registration request, the expandability of the data routing method is realized, the newly added service does not need to be customized and developed under the condition that the newly added service is needed, the registration process of the newly added service can be completed only by storing the task type and the registration information of the service to be registered carried in the registration request, the registration cost is reduced, and the service registration efficiency is improved.

(7) By monitoring the registration information change event of each registered service, the embodiment of the application can update the registered service in the server in real time under the condition that the registered service has data change, network address change or disconnection change, so that the correct routing of the subsequent structured data is facilitated.

The above description is only an example of the present application, and is not intended to limit the scope of the present application. Any modification, equivalent replacement, and improvement made within the spirit and scope of the present application are included in the protection scope of the present application.

完整详细技术资料下载
上一篇:石墨接头机器人自动装卡簧、装栓机
下一篇:一种基于深度学习算法的企业行业二级行业多标签分类器

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!