CN109040311B - Service information push processing method and device - Google Patents

Service information push processing method and device Download PDF

Info

Publication number
CN109040311B
CN109040311B CN201811079708.5A CN201811079708A CN109040311B CN 109040311 B CN109040311 B CN 109040311B CN 201811079708 A CN201811079708 A CN 201811079708A CN 109040311 B CN109040311 B CN 109040311B
Authority
CN
China
Prior art keywords
service
database
recorded
registered service
registered
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811079708.5A
Other languages
Chinese (zh)
Other versions
CN109040311A (en
Inventor
陆文成
张洺棋
胡彦斌
魏博文
代博文
关默然
宛明宇
张立丽
王依桌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN201811079708.5A priority Critical patent/CN109040311B/en
Publication of CN109040311A publication Critical patent/CN109040311A/en
Application granted granted Critical
Publication of CN109040311B publication Critical patent/CN109040311B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/544Remote

Abstract

The invention provides a method and a device for pushing and processing service information, which are applied to a platform server, wherein the method comprises the following steps: determining at least one registered service currently recorded in a first database, wherein the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used for being called by part or all of the first system; if a new registered service is generated in the first database and first calling specification information corresponding to the new registered service is determined, sending first service information containing the first calling specification information to a preset first network address, so that a system associated with the first network address can call the new registered service according to the first calling specification information. The invention enables the first system to learn in time that a new registered service has been generated.

Description

Service information push processing method and device
Technical Field
The present invention relates to the field of internet, and in particular, to a method and an apparatus for pushing and processing service information.
Background
In a service architecture in the internet field, a first system for implementing various information processing may call, through a platform server, a service provided by a second underlying system, which may be a common, core service required by each first system.
In the prior art, in order to enable a first system to call services provided by a lower-layer second system through a platform server according to configured interface specifications, each first system needs to be configured separately, and before the first system is not configured, even if new services are generated, personnel associated with the first system cannot learn in time and call the new services.
Therefore, as the personnel associated with the first system cannot timely learn about the generation of the new service, the business system cannot timely process the newly generated service.
Disclosure of Invention
The invention provides a method and a device for pushing and processing service information, which aim to solve the problem that a system cannot process newly generated services in time.
According to a first aspect of the present invention, a method for pushing service information is provided, which is applied to a platform server, where the platform server is disposed between a first system and a second system, and includes:
determining at least one registered service currently recorded in a first database, wherein the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used for being called by part or all of the first system;
if a new registered service is generated in the first database and first calling specification information corresponding to the new registered service is determined, sending first service information containing the first calling specification information to a preset first network address.
Optionally, the method further includes:
periodically querying and determining services recorded by a first list, wherein the first list is used for recording the services which are registered in a registry server or the platform server in real time;
if the registered service recorded in the first database is different from the service recorded in the first list, the registered service recorded in the first database is updated to the service recorded in the first list.
Optionally, after the periodically querying and determining the services recorded in the first list, the method further includes:
if the first registered service is recorded in the inquired first list but the first database before updating does not record the first registered service, determining that the first registered service is the new registered service so as to determine that the new registered service is generated in the updated first database.
Optionally, the method further includes:
periodically acquiring required calling specification information from a second system and/or a platform server which can provide registered services, wherein the required calling specification information is the calling specification information corresponding to the registered services recorded by the first database;
updating and recording the required calling specification information and the first corresponding relation between the required calling specification information and the registered service in a second database;
and if the first database records the new registered service, determining first calling specification information corresponding to the new registered service according to the second database.
Optionally, the method further includes:
periodically inquiring and determining a second corresponding relation recorded in the second list; the second corresponding relation is the corresponding relation between the registered service recorded by the first database and the first system; the second list is used for updating the second corresponding relation in real time;
if the third corresponding relation recorded by a third database is different from the second corresponding relation recorded by the second list, updating the third corresponding relation according to the second corresponding relation;
the registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
Optionally, after updating the third corresponding relationship according to the second corresponding relationship, the method further includes:
and if a corresponding first system is determined to be added to a second registered service recorded in the first database according to the third corresponding relation before updating and the updated third corresponding relation, sending second service information containing second calling specification information corresponding to the second registered service to a second network address associated with the newly added first system.
According to a second aspect of the present invention, there is provided a push processing apparatus for service information, comprising:
a determining module, configured to determine at least one registered service currently recorded in a first database, where the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used to be invoked by part or all of the first system;
the first sending module is configured to send first service information including first call specification information to a preset first network address if a new registered service is generated in the first database and the first call specification information corresponding to the new registered service is determined.
Optionally, the apparatus further includes:
the first query module is used for periodically querying and determining services recorded by a first list, and the first list is used for recording the services which are registered in a registry server or the platform server in real time;
a first updating module, configured to update the registered service recorded in the first database to the service recorded in the first list if the registered service recorded in the first database is different from the service recorded in the first list.
Optionally, the apparatus further includes:
and the new registration determining module is used for determining that the first registered service is the new registered service if the first registered service is recorded in the inquired first list but the first registered service is not recorded in the first database before updating so as to determine that the new registered service is generated in the updated first database.
Optionally, the apparatus further includes:
the acquisition module is used for periodically acquiring required calling specification information from a second system and/or a platform server which can provide registered services, wherein the required calling specification information is the calling specification information corresponding to the registered services recorded by the first database;
the second updating module is used for updating and recording the required calling specification information and the first corresponding relation between the required calling specification information and the registered service in a second database;
and the new specification determining module is used for determining first calling specification information corresponding to the new registered service according to the second database if the first database records the new registered service.
Optionally, the apparatus further includes:
the second query module is used for periodically querying and determining a second corresponding relation recorded in the second list; the second corresponding relation is the corresponding relation between the registered service recorded by the first database and the first system; the second list is used for updating the second corresponding relation in real time;
a third updating module, configured to update a third corresponding relationship according to the second corresponding relationship if the third corresponding relationship recorded in a third database is different from the second corresponding relationship recorded in the second list;
the registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
Optionally, the apparatus further includes:
a second sending module, configured to send, if it is determined that a corresponding first system is added to a second registered service recorded in the first database according to a third correspondence before update and a third correspondence after update, second service information including second call specification information corresponding to the second registered service to a second network address associated with the newly added first system.
According to a third aspect of the present invention, there is provided an electronic apparatus comprising:
a processor; and the number of the first and second groups,
a memory for storing executable instructions of the processor;
wherein the processor is configured to perform a push processing method of service information related to the first aspect and its alternatives via execution of the executable instructions.
According to a fourth aspect of the present invention, there is provided a storage medium having a computer program stored thereon, characterized in that the program, when executed by a processor, implements a push processing method of service information relating to the first aspect and its alternatives.
According to the method and the device for pushing and processing the service information, the at least one registered service currently recorded by the first database is determined, and if a new registered service is generated in the first database and the first calling specification information corresponding to the new registered service is determined, the first calling specification information is sent to the preset first network address, so that the corresponding first calling specification information is actively pushed to the first network address associated with the system when the new registered service is generated, further, personnel associated with the system can timely learn that the new registered service is generated, and therefore, the method and the device can be beneficial to timely implementing calling processing when the first system has a demand.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a flowchart illustrating a push processing method for service information according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a push processing method for service information according to another embodiment of the present invention;
fig. 3 is a schematic structural diagram of a push processing apparatus for service information according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a push processing device for service information according to another embodiment of the present invention;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The technical solution of the present invention will be described in detail below with specific examples. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments.
Fig. 1 is a flowchart illustrating a push processing method for service information according to an embodiment of the present invention.
Referring to fig. 1, a method for pushing service information is applied to a platform server, where the platform server is disposed between a first system and a second system, and the method includes:
s101: at least one registered service currently recorded in the first database is determined.
The registered service may be understood as a service provided by the platform server and/or a service directly provided by the platform server by the second system, and the registered service is used for being called by part or all of the first system. The service is understood to be any of at least one of executing a specific program, outputting specific information, and performing specific processing on input information.
The information for determining the registered service can be further understood as information for determining the registered service, the information can include a service name, a service version number, and update time of the information of the registered service, any information capable of distinguishing different registered services can be used as the information of the registered service, and the determination of the information can be understood as determining the registered service.
The first system, which is understood to be a system capable of invoking the registered service, and the second system, which is understood to be a corresponding system capable of providing the registered service. Meanwhile, for the same system, it may be the first system or the second system for different registered services.
The first database may be any database capable of describing or characterizing the registered service, which may be stored in a storage device alone, and may be a storage device of the platform server, an external storage device, or a storage device of another server or system.
S102: if a new registered service is generated in the first database and first calling specification information corresponding to the new registered service is determined, sending first service information containing the first calling specification information to a preset first network address.
The new registered service may be understood as a registered service that is different from the at least one registered service recorded by the first database determined above. Each time a new registered service is added to the first database, a new registered service is generated.
Call specification information is understood to be information used to implement a registered service call. It may or may not overlap with the information of the registered service, and may specifically include a description of the service usage and logic, which can provide guidance to the associated personnel. Specifically, the call specification information may include: service name, description of service function, service input, description of output parameter, information of calling interface, etc.
The first call specification information may be understood as call specification information corresponding to the new registered service, that is, call specification information for calling the new registered service.
The first network address, which may be understood as any content characterizing the network location, may be, for example, a mailbox address, a web page address, a network address of the device, etc. Which may be associated with a particular system and specifically may be the contact address of the person associated with that particular system.
The first service information may include, in addition to the first call specification information, at least one of function description information, a service name, version information, update time information, information indicating that the registered service is a new registered service, information indicating a network address of a web page introducing the registered service, and the like of the new registered service.
According to the pushing processing method of the service information, at least one registered service currently recorded by a first database is determined, and if a new registered service is generated in the first database and first calling specification information corresponding to the new registered service is determined, the first calling specification information is sent to a preset first network address, so that when the new registered service is generated, the corresponding first calling specification information is actively pushed to a first network address associated with a system, and further, personnel associated with the system can timely learn that the new registered service is generated, and therefore, the method can be beneficial to timely implementing calling processing when the first system has a demand.
Fig. 2 is a flowchart illustrating a push processing method for service information according to another embodiment of the present invention.
Referring to fig. 2, a method for pushing service information is applied to a platform server, where the platform server is disposed between a first system and a second system, and the method includes:
s201: at least one registered service currently recorded in the first database is determined.
Step S201, the operation principle, the alternative implementation, and the technical effects that can be produced in relation to the first database, the first system, the second system, the registered service can all be understood with reference to the description related to step S101 in the embodiment shown in fig. 1.
S202: whether the first period is reached.
The first period is understood to be any length of time.
If the determination in step S202 is yes, step S203 may be implemented: the services recorded in the first list are queried and determined.
If the determination in step S202 is no, the process may return to step S202 to continuously determine whether the first period is reached.
As can be seen, through the above steps S202 and S203, it is possible to implement: the services recorded by the first list are periodically queried and determined. Which may be implemented using a service registry scanning module.
The first list can be understood as a service for recording in real time services that have been registered with the registry server. The registry server may act as a service registry.
Specifically, the method can be implemented by using a created Java program, in which a timed task component can be referenced, and the Cron expression for configuring the timed task can be "000? "which may be configured to start every morning at 00: 00.
When the timing task is started for the first time, the interface of the service registration center is called to inquire all registered services, the inquired registered services are recorded in the first database, when the timing time is up, namely the timing task is started again, the interface of the service registration center is called again to inquire all registered services, the processes are repeated, and periodic inquiry and determination can be achieved.
S204: whether the registered services recorded in the first database are the same as the services recorded in the first list.
If the determination in step S204 is yes, the process returns to step S201 to determine the registered service of the first database, or to understand that the recorded content is still the registered service recorded as it is. In other alternative embodiments, if it is determined that the determination is positive, other processing may not be performed.
If the determination in step S204 is no, step S205 may be implemented: updating the registered services recorded in the first database to the services recorded in the first list. After the implementation, the method may return to step S201, and further determine the registered service recorded after the first database is updated.
S206: and determining that the first registered service is recorded in the inquired first list, but the first database before updating does not record the first registered service.
S207: determining that the first registered service is the new registered service to determine that the new registered service is generated in the updated first database.
In a specific implementation process, the implementation of steps S206 and S207 may be implemented after the update is completed, that is, after step S205, or before the update, that is, after step S203, for example, the implementation may be implemented when services recorded in the first list are queried and determined, specifically, services in the queried first list may be checked one by one, if a certain queried service does not exist in the first database, the certain queried service may be regarded as a new registered service, and the service is added to the first database, and the insertion time is the current system time; if the service already exists in the first database, but the version number changes, the update time of the service in the first database can be changed to the current system time and the version number can be updated; if the service already exists in the first database and the version number has not changed, no processing may be performed. As long as the determination of the new registered service is achieved after querying and determining the services recorded in the first list, this does not depart from the scope of the alternative solution of the present invention.
The above embodiment realizes the determination of whether there is a new registered service, and provides a basis for the transmission of the first invocation specification information in the subsequent step S208.
To implement step S208, first call specification information corresponding to the new registered service is determined. In order to determine the first call specification information, the following steps are also implemented:
s209: whether the second period is reached.
If the determination in step S209 is yes, step S210 may be implemented: the required call specification information is obtained from a second system and/or platform server capable of providing the registered service.
If the determination in step S209 is no, the process returns to step S209 to continue determining whether the second period is reached.
As can be seen, through the above steps S209 and S210, it is possible to implement: the required call specification information is periodically retrieved from a second system and/or platform server capable of providing the registered service.
The required call specification information may be understood as call specification information corresponding to the registered service recorded in the first database.
In the specific implementation process, the specification information is called, so that the specification information can be maintained in a system or a server serving as an enterprise knowledge management platform, a Web page crawler program can be realized by using Java language, and the daily ratio of the Web page crawler program is 00: starting a main crawler thread at the time 00 to capture calling specification information, wherein the number of the main crawler threads can be 100 in one embodiment, and the main crawler threads are averagely divided into 10 groups; according to the grouping, 10 crawler threads can be started, and each crawler accesses the url address to capture the content of 10 service interface specification pages according to the grouping, so that calling specification information is obtained.
The service interface specification page can be provided for the second system and/or the platform server, the content of the service interface specification page is distributed according to a fixed format, and in one embodiment, the service interface specification page can contain 1 html h3 element, and the content of the service interface specification page is a service name; 1 html span element, the content of which is service function description; 2 html table elements, which are respectively the structure description of service request entry and return data, and the formats of the two html tables are consistent, and the html tables contain 4 columns: node name, parent node, data type, Chinese description. Crawlers extract line by line, each line containing these 4 fields.
S211: and updating and recording the required calling specification information and the first corresponding relation between the required calling specification information and the registered service in a second database.
When updating, the originally recorded data can be deleted, newly acquired data can be written, and only the changed part can be supplemented, modified or deleted.
In a specific implementation process, data in the second database may be deleted, in one implementation, the second database may be a Mysql database, and the obtained data is stored in the database, where a field in the MICRO _ SERVICE table includes a SERVICE id, a SERVICE name, a SERVICE version, and a SERVICE function description; the MICRO _ SERVICE _ REQ has 5 fields including a SERVICE id, a node name of a request for entering the SERVICE id, a father node, a data type and Chinese description; the table MICRO _ SERVICE _ RSP has 5 fields of SERVICE id, node name of requested participation, parent node, data type, and Chinese description.
It can be seen that only the corresponding record is realized, and the first corresponding relation is recorded, rather than the corresponding relation is represented by a specific language.
S212: whether the first database records the new registered service.
If not, the process may return to step S211 to continue updating or to update after the period is reached.
If so, step S213 may be performed: and determining first calling specification information corresponding to the new registered service according to the second database.
After step S213 is completed, the first call specification information may be determined, and thus, step S208 may be implemented: and sending first service information containing the first calling specification information to a preset first network address.
The principle of operation, alternative embodiments, and technical effects that can be produced by step S208 can be understood with reference to the description related to step S102 in the embodiment shown in fig. 1.
Furthermore, since the registered services that can be provided by the platform server are diverse, the registered services that different first systems are authorized to invoke may also be different, i.e., different registered services may correspond to different first system or systems.
In one embodiment, if the version number, the update time, and the like of the registered service change, a change message describing the change may be generated correspondingly, and further, a third service message including the change message may be sent to the first system corresponding to the registered service.
Referring to fig. 2, in one embodiment, the method may further include:
s214: whether the third period is reached.
If the determination in step S214 is yes, step S215 may be implemented: and querying and determining the second corresponding relation recorded in the second list.
If the determination in step S214 is no, the process may return to step S214 to continuously determine whether the third period is reached.
As can be seen, through the above steps S214 and S215, it is possible to implement: the second correspondence recorded in the second list is periodically queried and determined.
The second correspondence may be understood as a correspondence between the registered service recorded in the first database and the first system. The second list may be understood to be used for updating the second correspondence in real time. The real-time update is understood to be that each time a first system completes the authorization processing of the registered service, the corresponding update can be performed in the second list in real time, and further, before the authorization processing, authentication is performed.
The first system can access the interface service through a capability opening platform, and the platform can be a platform server or a capability opening server. The capability open platform is used for storing a list, namely a second list, of services which are obtained by the first system and authorized to access, and the capability open platform scanning module queries a third database of the open platform in a timing scanning mode and scans each first system to obtain the services authorized to access.
Specifically, a Java program may be created, a timed task component may be referenced, and a timed task Cron expression may be configured as "000? Start every morning at 00: 00; when the timing task is started for the first time, connecting the database of the capacity open platform, namely inquiring the second list, and determining the service of each first system for obtaining access authorization, namely the registered service corresponding to each first system; and correspondingly, the third database can also store the information of the first list which is inquired and comprises the updating time, the micro service name, the micro service version number and the called first system. When the timed task is started again, each first system can be queried again for services to which access is granted.
It can be seen that the first database, the second database, and the third database may be merged to use the same database, so that the first database, the second database, and the third database may be understood as different data objects in the same database.
S216: determining that the third corresponding relation recorded by the third database is different from the second corresponding relation recorded by the second list.
S217: and updating the third corresponding relation according to the second corresponding relation.
The difference between the second correspondence and the third correspondence can be understood as: the second correspondence is recorded by the second list and the third correspondence is recorded by the third database.
The registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
Specifically, if the specific first system does not exist in the first system corresponding to the second registered service in the third database, the specific system is added to the first system corresponding to the second registered service recorded in the third database, and the update time is the current system time.
In another implementation process, if another specific first system is not recorded in the third database and the first database, the specific system may be added to the first system, and the related second corresponding relationship is correspondingly recorded in the third system.
S218: and determining that a corresponding first system is added to a second registered service recorded by the first database according to the third corresponding relation before updating and the third corresponding relation after updating.
S219: and sending second service information containing second calling specification information corresponding to the second registered service to a second network address associated with the newly added first system.
Furthermore, if the first system already exists in the third database and the first database and has obtained an authorized interface set, i.e., the corresponding call specification information has not changed, no processing may be performed.
Specifically, the first service information, the second service information and the third service information can be pushed by a service pushing program module according to the requirements of the subscriber, wherein the service pushing program module is responsible for pushing the newly registered service, the newly registered interface user and the newly applied authorized interface of the registered interface user. The module will receive the notifynweserviceforregcenter interface message from the service registry scan module and the notifyccustodermapplynewserviceforaop interface message from the capability openplatform scan module.
The notifynweserviceforregcenter interface message of the service registry scan module may be understood as the query and determination in the foregoing steps S202 and S203.
The notifyccustomerappywserviceforaop interface message of the capability open platform scanning module may be understood as queried and determined in the foregoing step S214 and step S215.
The processing steps after the module receives the interface notification are as follows:
traversing all newly registered service names MicroServiceName and version number ServiceVersion of the registration center from the MicroServiceList set node of the interface access reference, and storing the service names MicroServiceName and version number ServiceVersion in an object newRegServiceList of Java ArrayList < String, String > type;
calling a query interface QueryMicroServiceDetail, accessing the interface into MicroServiceName and ServiceVersion, and returning data to be queried about service function description, service request access list and service output data list in the micro service interface specification;
inquiring a push message template, wherein the template contains a placeholder, filling the content in the step 2 into the placeholder of the template to generate final push content, the template I is 'service registry new-on-shelf service { $ name }, the service function is { $ detail }, the request parameter comprises { $ reqList }, the output data comprises { $ rspList }, and the detail-knowing request is … …', the template II is 'capability-opening platform authorization to open new service { $ name }, the service function is { $ detail }, the request parameter comprises { $ reqList }, the output data comprises { $ rspList }, and the detail-knowing request is … …'.
Inquiring the mailbox information of the micro service promotion subscriber, it can be understood that the first network address and the second network address are the requirement designer and business innovation person of each business department;
and sending the generated push content to the first network address and the second network address, and further sending the push content to the service promotion subscriber through the mail server.
In the push processing method for service information provided by this embodiment, at least one registered service currently recorded in a first database is determined, and if a new registered service is generated in the first database and first call specification information corresponding to the new registered service is determined, the first call specification information is sent to a preset first network address, so that a system associated with the first network address can call the new registered service according to the first call specification information, and when the new registered service is generated, the corresponding first call specification information is actively pushed to a first network address associated with the first system, so that the first system can timely learn that the new registered service is generated, and therefore, the call processing can be timely implemented when the first system has a need.
Fig. 3 is a schematic structural diagram of a push processing device for service information according to an embodiment of the present invention.
Referring to fig. 3, the apparatus 300 for pushing service information includes:
a determining module 301, configured to determine at least one registered service currently recorded in a first database, where the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used to be invoked by part or all of the first system;
a first sending module 302, configured to send first service information including first call specification information to a preset first network address if a new registered service is generated in the first database and the first call specification information corresponding to the new registered service is determined.
According to the pushing processing device for the service information, at least one registered service currently recorded by the first database is determined, and if a new registered service is generated in the first database and the first calling specification information corresponding to the new registered service is determined, the first calling specification information is sent to the preset first network address, so that when the new registered service is generated, the corresponding first calling specification information is actively pushed to the first network address associated with the system, and further, personnel associated with the system can timely learn that the new registered service is generated, and therefore, the pushing processing device for the service information can be beneficial to timely implementing calling processing when the first system is in need.
Fig. 4 is a schematic structural diagram of a push processing device for service information according to another embodiment of the present invention;
referring to fig. 4, the apparatus 400 for pushing service information includes:
a determining module 401, configured to determine at least one registered service currently recorded in a first database, where the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used to be invoked by part or all of the first system;
a first sending module 405, configured to send first service information including first call specification information to a preset first network address if a new registered service is generated in the first database and the first call specification information corresponding to the new registered service is determined.
Optionally, the apparatus further includes:
a first query module 402, configured to periodically query and determine services recorded in a first list, where the first list is used to record, in real time, services that have been registered in a registry server or the platform server;
a first updating module 403, configured to update the registered service recorded in the first database to the service recorded in the first list if the registered service recorded in the first database is different from the service recorded in the first list;
optionally, the apparatus further includes:
a new registration determining module 404, configured to determine that the first registered service is the new registered service if the first registered service is recorded in the queried first list but the first registered service is not recorded in the first database before updating, so as to determine that the new registered service is generated in the updated first database.
Optionally, the apparatus further includes:
an obtaining module 406, configured to periodically obtain required call specification information from a second system and/or a platform server capable of providing a registered service, where the required call specification information is call specification information corresponding to the registered service recorded in the first database;
a second updating module 407, configured to update and record the required call specification information and the first corresponding relationship between the required call specification information and the registered service in a second database;
a new specification determining module 408, configured to determine, according to the second database, first call specification information corresponding to the new registered service if the first database records the new registered service.
Optionally, the apparatus further includes:
a second query module 409, configured to query and determine a second corresponding relationship recorded in the second list periodically; the second corresponding relation is the corresponding relation between the registered service recorded by the first database and the first system; the second list is used for updating the second corresponding relation in real time;
a third updating module 410, configured to update a third corresponding relationship according to the second corresponding relationship if the third corresponding relationship recorded in a third database is different from the second corresponding relationship recorded in the second list;
the registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
Optionally, the apparatus further includes:
a second sending module 411, configured to send, if it is determined that a corresponding first system is added to a second registered service recorded in the first database according to the third corresponding relationship before the update and the updated third corresponding relationship, second service information including second call specification information corresponding to the second registered service to a second network address associated with the added first system.
According to the pushing processing device for the service information, at least one registered service currently recorded by the first database is determined, and if a new registered service is generated in the first database and the first calling specification information corresponding to the new registered service is determined, the first calling specification information is sent to the preset first network address, so that when the new registered service is generated, the corresponding first calling specification information is actively pushed to the first network address associated with the system, and further, personnel associated with the system can timely learn that the new registered service is generated, and therefore, the pushing processing device for the service information can be beneficial to timely implementing calling processing when the first system is in need.
Fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the invention.
Referring to fig. 5, the present embodiment further provides an electronic device 30 including: a processor 31 and a memory 32; wherein:
a memory 32 for storing a computer program, which may also be a flash (flash memory).
And a processor 31 for executing the execution instructions stored in the memory to implement the steps of the above method. Reference may be made in particular to the description relating to the preceding method embodiment.
Alternatively, the memory 32 may be separate or integrated with the processor 31.
When the memory 32 is a device independent of the processor 31, the electronic device 30 may further include:
a bus 33 for connecting the memory 32 and the processor 31.
The present embodiment also provides a readable storage medium, in which a computer program is stored, and when the computer program is executed by at least one processor of an electronic device, the computer program electronically executes the method provided by the above various embodiments.
The present embodiment also provides a program product comprising a computer program stored in a readable storage medium. The computer program can be read from a readable storage medium by at least one processor of the electronic device, and the execution of the computer program by the at least one processor causes the electronic device to implement the methods provided by the various embodiments described above.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A method for pushing and processing service information is applied to a platform server, wherein the platform server is arranged between a first system and a second system, and the method comprises the following steps:
determining at least one registered service currently recorded in a first database, wherein the registered service is a service provided by the second system through the platform server and/or a service directly provided by the platform server, and the registered service is used for being called by part or all of the first system;
if a new registered service is generated in the first database and first calling specification information corresponding to the new registered service is determined, sending first service information containing the first calling specification information to a preset first network address;
periodically querying and determining services recorded by a first list, wherein the first list is used for recording the services which are registered in a registry server or the platform server in real time;
if the registered service recorded in the first database is different from the service recorded in the first list, the registered service recorded in the first database is updated to the service recorded in the first list.
2. The method of claim 1, wherein after periodically querying and determining the services recorded in the first list, further comprising:
if the first registered service is recorded in the inquired first list but the first database before updating does not record the first registered service, determining that the first registered service is the new registered service so as to determine that the new registered service is generated in the updated first database.
3. The method of claim 1 or 2, further comprising:
periodically acquiring required calling specification information from a second system and/or a platform server which can provide registered services, wherein the required calling specification information is the calling specification information corresponding to the registered services recorded by the first database;
updating and recording the required calling specification information and the first corresponding relation between the required calling specification information and the registered service in a second database;
and if the first database records the new registered service, determining first calling specification information corresponding to the new registered service according to the second database.
4. The method of claim 1 or 2, further comprising:
periodically inquiring and determining a second corresponding relation recorded in the second list; the second corresponding relation is the corresponding relation between the registered service recorded by the first database and the first system; the second list is used for updating the second corresponding relation in real time;
if the third corresponding relation recorded by a third database is different from the second corresponding relation recorded by the second list, updating the third corresponding relation according to the second corresponding relation;
the registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
5. The method according to claim 4, wherein after updating the third corresponding relationship according to the second corresponding relationship, further comprising:
and if a corresponding first system is determined to be added to a second registered service recorded in the first database according to the third corresponding relation before updating and the updated third corresponding relation, sending second service information containing second calling specification information corresponding to the second registered service to a second network address associated with the newly added first system.
6. A pushing processing device of service information is characterized by comprising:
the system comprises a determining module, a judging module and a judging module, wherein the determining module is used for determining at least one registered service currently recorded in a first database, the registered service is a service provided by a second system through a platform server and/or a service directly provided by the platform server, and the registered service is used for being called by part or all of a first system;
a first sending module, configured to send first service information including first call specification information to a preset first network address if a new registered service is generated in the first database and the first call specification information corresponding to the new registered service is determined;
the first query module is used for periodically querying and determining services recorded by a first list, and the first list is used for recording the services which are registered in a registry server or the platform server in real time;
a first updating module, configured to update the registered service recorded in the first database to the service recorded in the first list if the registered service recorded in the first database is different from the service recorded in the first list.
7. The apparatus of claim 6, further comprising:
and the new registration determining module is used for determining that the first registered service is the new registered service if the first registered service is recorded in the inquired first list but the first registered service is not recorded in the first database before updating so as to determine that the new registered service is generated in the updated first database.
8. The apparatus of claim 6, further comprising:
the acquisition module is used for periodically acquiring required calling specification information from a second system and/or a platform server which can provide registered services, wherein the required calling specification information is the calling specification information corresponding to the registered services recorded by the first database;
the second updating module is used for updating and recording the required calling specification information and the first corresponding relation between the required calling specification information and the registered service in a second database;
and the new specification determining module is used for determining first calling specification information corresponding to the new registered service according to the second database if the first database records the new registered service.
9. The apparatus of claim 6, further comprising:
the second query module is used for periodically querying and determining a second corresponding relation recorded in the second list; the second corresponding relation is the corresponding relation between the registered service recorded by the first database and the first system; the second list is used for updating the second corresponding relation in real time;
a third updating module, configured to update a third corresponding relationship according to the second corresponding relationship if the third corresponding relationship recorded in a third database is different from the second corresponding relationship recorded in the second list;
the registered service is specifically used for being called by a target first system, and the target first system is determined according to the third corresponding relation.
10. The apparatus of claim 9, further comprising:
a second sending module, configured to send, if it is determined that a corresponding first system is added to a second registered service recorded in the first database according to a third correspondence before update and a third correspondence after update, second service information including second call specification information corresponding to the second registered service to a second network address associated with the newly added first system.
CN201811079708.5A 2018-09-17 2018-09-17 Service information push processing method and device Active CN109040311B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811079708.5A CN109040311B (en) 2018-09-17 2018-09-17 Service information push processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811079708.5A CN109040311B (en) 2018-09-17 2018-09-17 Service information push processing method and device

Publications (2)

Publication Number Publication Date
CN109040311A CN109040311A (en) 2018-12-18
CN109040311B true CN109040311B (en) 2021-07-20

Family

ID=64621952

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811079708.5A Active CN109040311B (en) 2018-09-17 2018-09-17 Service information push processing method and device

Country Status (1)

Country Link
CN (1) CN109040311B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109714411A (en) * 2018-12-25 2019-05-03 浪潮电子信息产业股份有限公司 The task timing of springboot micro services frame executes method, apparatus, equipment and medium
CN110602193A (en) * 2019-08-29 2019-12-20 微梦创科网络科技(中国)有限公司 Service discovery method and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102497451A (en) * 2011-12-28 2012-06-13 用友软件股份有限公司 Service processing system and service processing method
CN103051551A (en) * 2011-10-13 2013-04-17 中兴通讯股份有限公司 Distributed system and automatic maintaining method for same
CN105450757A (en) * 2015-12-02 2016-03-30 联动优势电子商务有限公司 Service management method and system
CN105515759A (en) * 2015-11-27 2016-04-20 国网信息通信产业集团有限公司 Micro service registration method and micro service registration system
CN105933444A (en) * 2016-06-27 2016-09-07 焦点科技股份有限公司 Service discovering method based on cooperation of registration center and caching mechanism

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100407154C (en) * 2004-04-29 2008-07-30 国际商业机器公司 A system and method for modeling and dynamically deploying services into a distributed networking architecture
US8868072B2 (en) * 2011-02-11 2014-10-21 Vodafone Ip Licensing Limited Method and system for facilitating communication between wireless communication devices

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103051551A (en) * 2011-10-13 2013-04-17 中兴通讯股份有限公司 Distributed system and automatic maintaining method for same
CN102497451A (en) * 2011-12-28 2012-06-13 用友软件股份有限公司 Service processing system and service processing method
CN105515759A (en) * 2015-11-27 2016-04-20 国网信息通信产业集团有限公司 Micro service registration method and micro service registration system
CN105450757A (en) * 2015-12-02 2016-03-30 联动优势电子商务有限公司 Service management method and system
CN105933444A (en) * 2016-06-27 2016-09-07 焦点科技股份有限公司 Service discovering method based on cooperation of registration center and caching mechanism

Also Published As

Publication number Publication date
CN109040311A (en) 2018-12-18

Similar Documents

Publication Publication Date Title
CN107391142B (en) Application splitting method and device
CN108932236B (en) File management method and device
CN107026882B (en) Resource acquisition method and related equipment
US20020069192A1 (en) Modular distributed mobile data applications
US20070094301A1 (en) Application programming interface for centralized storage of principal data
US11153071B2 (en) Citation and attribution management methods and systems
US20170331784A1 (en) Oid configuration, resolution method, client, node, database and storage medium
CN111046041B (en) Data processing method and device, storage medium and processor
US20130091416A1 (en) Method for establishing a relationship between semantic data and the running of a widget
CN114064690A (en) Data processing method and device
CN109040311B (en) Service information push processing method and device
CN111381820A (en) Method and device for automatically generating API based on GUI
CN112182014A (en) Database query method, device, equipment and storage medium
CN112783551A (en) Interface document generation method of micro-service framework, electronic equipment and storage medium
CN110222047B (en) Dynamic form generation method and device
CN111427613A (en) Application program interface API management method and device
US20170286523A1 (en) Apparatus and method for verifying cloud service compatibility
CN112084199A (en) Scene-based general parameter maintenance method and device
CN102456070B (en) Indexing unit and search method
US11205049B2 (en) Method for managing semantic information on M2M/IoT platform
CN112491943A (en) Data request method, device, storage medium and electronic equipment
CN115017185A (en) Data processing method, device and storage medium
CN112597105A (en) Processing method of file associated object, server side equipment and storage medium
CN108491448B (en) Data pushing method and device
CN113468258A (en) Heterogeneous data conversion method and device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant