CN105893150A - Interface calling frequency control and interface calling request processing method and device - Google Patents

Interface calling frequency control and interface calling request processing method and device Download PDF

Info

Publication number
CN105893150A
CN105893150A CN201610197050.2A CN201610197050A CN105893150A CN 105893150 A CN105893150 A CN 105893150A CN 201610197050 A CN201610197050 A CN 201610197050A CN 105893150 A CN105893150 A CN 105893150A
Authority
CN
China
Prior art keywords
frequency
interface
request
interchange
interface identifier
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201610197050.2A
Other languages
Chinese (zh)
Other versions
CN105893150B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201610197050.2A priority Critical patent/CN105893150B/en
Publication of CN105893150A publication Critical patent/CN105893150A/en
Application granted granted Critical
Publication of CN105893150B publication Critical patent/CN105893150B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals

Abstract

The invention relates to an interface calling frequency control and interface calling request processing method and device. The interface calling frequency control method includes the steps that calling frequencies reported by all interface servers and corresponding to interface identification are collected; the collected calling frequencies are summarized according to a frequency control cycle to obtain the frequencies called already and corresponding to the interface identification; an applying calling frequency corresponding to the interface identification is obtained; if the frequencies called already reach the applying calling frequency, interface calling limiting notifications for limiting the interface calling request corresponding to the interface identification within limiting time are sent to all the interface servers in batches. By means of the interface calling frequency control and interface calling request processing method and device, the interface calling frequencies are controlled accurately.

Description

The control of interface interchange frequency, interface interchange request processing method and device
Technical field
The present invention relates to field of computer technology, particularly relate to a kind of interface interchange frequency control, interface tune With request processing method and device.
Background technology
Request end docking port server initiates interface interchange request, by interface server response interface call request Respond.But the resource of interface server is limited, it is therefore necessary to docking port call request is adjusted With the restriction of frequency.
Current interface interchange FREQUENCY CONTROL scheme, mainly receives what request end was initiated at interface server After interface interchange request, cached by the set time window with current time as time upper limit and call frequency, If in set time window, the frequency of calling of statistics reaches certain threshold value, just please to subsequently received interface interchange Ask and limit, until the frequency of calling of statistics is less than threshold value in set time window.
But, current interface interchange FREQUENCY CONTROL scheme when there is multiple interface server, each interface Server all can have identical frequency limit condition, is only assuming that interface interchange request falls equably each Interface interchange frequency can be accurately controlled time on interface server, but this hypothesis is very difficult in practice Ensure.
Such as with reference to Fig. 1, there is M interface server, it is equal that what each interface server limited calls frequency Be 10,000/minute, then be actually needed restriction call frequency be M ten thousand/minute, if but interface interchange please Ask and fail to fall equably on each interface server, then interface interchange request be also not up to M ten thousand/minute Just limited when calling frequency, and cannot accurately determine and specifically be limited under which kind of calls frequency.
Summary of the invention
Based on this, it is necessary to for current interface interchange FREQUENCY CONTROL scheme in the field of multiple interface servers The problem that cannot accurately control interface interchange frequency under scape, it is provided that a kind of interface interchange frequency controls, interface is adjusted With request processing method and device.
A kind of interface interchange frequency control method, described method includes:
That collects that each interface server reports corresponding with interface identifier calls frequency;
According to the frequency control cycle, the frequency that calls collected is collected, it is thus achieved that corresponding with described interface identifier Modulated frequency;
Obtain the application corresponding with described interface identifier and call frequency;
If described modulated frequency reaches described application calls frequency, then send out to described each interface server batch Send the interface interchange limit within the restriction time, the interface interchange request corresponding with described interface identifier limited System notice.
A kind of interface interchange frequency controls device, and described device includes:
Call frequency collection module, for collecting call corresponding with interface identifier that each interface server reports Frequency;
Call frequency summarizing module, for the frequency that calls collected being collected according to the frequency control cycle, Obtain the modulated frequency corresponding with described interface identifier;
Interface interchange control module, calls frequency for obtaining the application corresponding with described interface identifier;If institute State modulated frequency to reach described application and call frequency, then limiting to described each interface server Batch sending In time, the interface interchange corresponding with described interface identifier is asked the interface interchange limitation notification limited.
A kind of interface interchange request processing method, described method includes:
Control server to frequency to report and corresponding with interface identifier call frequency so that described frequency controls clothes The frequency that calls that business device reports according to each interface server carries out collecting and obtains modulated frequency;
Receive described frequency to control server and reach the Shen corresponding with described interface identifier at described modulated frequency The interface interchange limitation notification sent when please call frequency;
Described interface identifier and the time of restriction is obtained according to described interface interchange limitation notification;
Receive the interface interchange request carrying described interface identifier;
If receiving the time of described interface interchange request in the described restriction time corresponding with described interface identifier In, then the request of described interface interchange is limited.
A kind of interface interchange request processing means, described device includes:
Call frequency reporting module, report call frequently corresponding with interface identifier for controlling server to frequency Degree so that described frequency controls the frequency that calls that server reports according to each interface server and collects and obtain Obtain modulated frequency;
Interface interchange limitation notification processing module, is used for receiving described frequency and controls server in described modulated use Frequency reaches the interface interchange limitation notification sent when frequency is called in the application corresponding with described interface identifier;Root Described interface identifier and the time of restriction is obtained according to described interface interchange limitation notification;
Interface interchange request processing module, for receiving the interface interchange request carrying described interface identifier; If receive described interface interchange request time within the described restriction time corresponding with described interface identifier, Then the request of described interface interchange is limited.
The control of above-mentioned interface interchange frequency, interface interchange request processing method and device, in multiple interface service Under the scene of device, the frequency that calls reported by each interface server carries out collecting and obtains modulated frequency, should Modulated frequency can accurately reflect out multiple interface server the most total call frequency.Again by by modulated Call frequency with the application of frequency and pre-first to file to compare, if modulated frequency reaches application calls frequency, to Each interface server batch is given notice so that each interface server is docking port call request within the restriction time Limit.So without ensureing that interface interchange request uniformly falls on each interface server, if modulated use Frequency is called in frequency not up to application, and each interface server receives the request of corresponding interface interchange can be just Often process;If modulated frequency reaches application calls frequency, then whichever interface server receives accordingly Interface interchange request all can limit, it is achieved that the accurate control of interface interchange frequency.
Accompanying drawing explanation
Fig. 1 is the system architecture diagram of current interface interchange FREQUENCY CONTROL scheme;
Fig. 2 is the applied environment figure of interface interchange frequency control system in an embodiment;
Fig. 3 is the applied environment figure of interface interchange frequency control system in another embodiment;
Fig. 4 is the applied environment figure of interface interchange frequency control system in further embodiment;
Fig. 5 is the internal structure schematic diagram of server in an embodiment;
Fig. 6 is the schematic flow sheet of interface interchange frequency control method in an embodiment;
Fig. 7 is the schematic flow sheet of interface interchange frequency control method in another embodiment;
Fig. 8 is the schematic flow sheet of interface interchange frequency control method in further embodiment;
Fig. 9 is the schematic flow sheet of interface interchange frequency control method in another embodiment;
Figure 10 is the schematic flow sheet of interface interchange request processing method in an embodiment;
Figure 11 is the schematic flow sheet of interface interchange request processing method in another embodiment;
Figure 12 is the schematic flow sheet of interface interchange request processing method in further embodiment;
If Figure 13 is that the time receiving interface interchange request in an embodiment is in the limit corresponding with interface identifier In time processed, then docking port call request carries out the sequential chart of the step limited;
If Figure 14 is that the time receiving interface interchange request in another embodiment is corresponding with interface identifier In the restriction time, then docking port call request carries out the sequential chart of the step limited;
Figure 15 is the structured flowchart that in an embodiment, interface interchange frequency controls device;
Figure 16 is the structured flowchart that in another embodiment, interface interchange frequency controls device;
Figure 17 is the structured flowchart of interface interchange request processing means in an embodiment.
Detailed description of the invention
In order to make the purpose of the present invention, technical scheme and advantage clearer, below in conjunction with accompanying drawing and reality Execute example, the present invention is further elaborated.Only should be appreciated that specific embodiment described herein Only in order to explain the present invention, it is not intended to limit the present invention.
As in figure 2 it is shown, in one embodiment, it is provided that a kind of interface interchange frequency control system, including Request end 210, multiple interface server 220 and frequency control server 230.Wherein request end 210 is to send out Play the equipment of interface interchange request, can be user terminal or service server.Interface server 220 is Thering is provided the equipment of interface service, the interface interchange request initiating request end 210 responds, plurality of Interface server 220 refers to two or more multiple interface server 220.Frequency controls server 230 for carrying out centralized Control to multiple interface servers 220.
As it is shown on figure 3, in one embodiment, interface interchange frequency control system also includes database service Device 240 and frequency call application platform 250.Frequency calls application platform 250 for receiving 210, request end That rises calls application, authorizes call authority if this is called application, then will call the content write data of application In storehouse server 240.Database server 240 is for controlling clothes to each interface server 220 and frequency Business device 230 provides the content calling application.The content calling application can include that interface identifier and application are called The corresponding relation of frequency, or can include that the correspondence of frequency is called in request end mark, interface identifier and application Relation, or can include that the corresponding relation of frequency is called in request end cluster identity, interface identifier and application.
As shown in Figure 4, in one embodiment, interface interchange frequency control system also includes request end cluster Management platform 260, for determining each request end cluster belonging to request end 210, and records request end mark With the subordinate relation of affiliated request end cluster identity, specifically can be by subordinate relation record at database server In 240, read by each interface server 210 and be cached in shared drive.
As it is shown in figure 5, in one embodiment, it is provided that a kind of server, this server can be used as interface Server 220, frequency control server 230, database server 240, frequency call application platform 250 Or request end cluster management platform 260.Processor that this server includes being connected by system bus, non-easily The property lost storage medium, built-in storage and network interface.Wherein processor has computing function and controls server The function of work, this processor can be configured to perform a kind of interface interchange frequency control method or interface is adjusted Use request processing method.Non-volatile memory medium includes that magnetic storage medium, optical storage media and flash memory type are deposited At least one in storage media.Non-volatile memory medium storage has operating system, and also storage has interface interchange Frequency controls device or interface interchange request processing means.Interface interchange frequency controls device and is used for realizing one Planting interface interchange frequency control method, interface interchange request processing means is used for realizing a kind of interface interchange request Processing method.
In one embodiment, multiple interface servers 220 are respectively used to control on server 230 to frequency Report and corresponding with interface identifier call frequency.
Frequency controls server 230 for collecting call corresponding with interface identifier that each interface server reports Frequency;According to the frequency control cycle, the frequency that calls collected is collected, it is thus achieved that corresponding with interface identifier Modulated frequency;Obtain the application corresponding with interface identifier and call frequency;Adjust if modulated frequency reaches application With frequency, then the interface corresponding with interface identifier is adjusted within the restriction time to each interface server Batch sending The interface interchange limitation notification limited is carried out with request.
Multiple interface servers 220 are respectively used to receive frequency and control the interface interchange limit that server 230 sends System notice;Interface identifier and the time of restriction is obtained according to interface interchange limitation notification;Reception carries interface mark The interface interchange request known;If receiving the time of interface interchange request when the restriction corresponding with interface identifier In, then docking port call request limits.
In one embodiment, frequency controls server 230 for the tune will collected according to the frequency control cycle Collect with frequency, it is thus achieved that the modulated frequency corresponding with request end mark and interface identifier;It is additionally operable to obtain Take the request end cluster identity corresponding to the mark of request end, and obtain and request end cluster identity and interface identifier Frequency is called in corresponding application;If modulated frequency reaches application calls frequency, then criticize to each interface server The interface interchange request corresponding with request end mark and interface identifier is limited in being sent in the restriction time by amount Interface interchange limitation notification.
In one embodiment, frequency controls server 230 specifically for controlling the cycle according at current frequency The frequency that calls of interior collection updates the modulated frequency corresponding with interface identifier of caching in shared drive;Working as Front frequency controls to be reset by modulated frequency corresponding with interface identifier for shared drive during end cycle.
In one embodiment, frequency control server 230 is additionally operable to read and interface identifier pair from database Frequency is called in the application answered, and application is called frequency and called application platform by frequency and call application according to receive In write into Databasce;Application is called that frequency is corresponding with interface identifier to be cached in shared drive.Be additionally operable to from Shared drive reads the application corresponding with interface identifier and calls frequency.
In one embodiment, frequency control server 230 be additionally operable to collect each interface server reports with Request end cluster identity and interface identifier corresponding call frequency;Obtain and request end cluster identity and interface mark Know corresponding application and call frequency;To each interface server Batch sending within the restriction time to request end collection Group identification and interface interchange request corresponding to interface identifier carry out the interface interchange limitation notification that limits.
In one embodiment, if multiple interface server 220 is respectively used to receive interface interchange request Time exceedes the restriction time, then carry out interface interchange according to interface interchange request, and update and interface identifier pair That answers calls frequency;The frequency that calls of interface identifier and renewal is reported to frequency control server.
In one embodiment, multiple interface servers 220 are respectively used to according to report cycle statistics and interface What mark was corresponding calls frequency and reports to frequency control server, and report cycle controls the cycle less than frequency.
In one embodiment, multiple interface servers 220 be respectively used to frequency control server report with Request end mark and interface identifier corresponding call frequency;Request end mark is obtained according to interface interchange limitation notification Knowledge, interface identifier and the time of restriction;Receive the interface interchange request carrying request end mark and interface identifier; If receive time of interface interchange request with request end mark and in restriction time corresponding to interface identifier, Then docking port call request limits.
In one embodiment, multiple interface servers 220 are respectively used to obtain entrained by interface interchange request Request end cluster identity;Judge whether the request end cluster identity obtained exists corresponding application and call frequency; If there is corresponding application to call frequency, and receive time of interface interchange request with request end cluster mark Know and in restriction time corresponding to interface identifier, then docking port call request limits.
In one embodiment, multiple interface servers 220 are respectively used to obtain entrained by interface interchange request Request end mark;Request end cluster identity belonging to inquiry request end mark;Judge the request end inquired Whether cluster identity exists the application of correspondence is called frequency;If there is corresponding application to call frequency, and receive To the time that interface interchange is asked within the restriction time corresponding with request end cluster identity and interface identifier, then Docking port call request limits.
Above-mentioned interface interchange frequency control system, under the scene of multiple interface servers, by each interface service What device reported call frequency carries out collecting and obtaining modulated frequency, and this modulated frequency can accurately reflect out many What individual interface server was the most total calls frequency.Again by the application of modulated frequency and pre-first to file is adjusted Compare with frequency, if modulated frequency reaches application calls frequency, give notice to each interface server batch, Each interface server docking port call request within the restriction time is limited.So without ensureing interface Call request uniformly falls on each interface server, if the not up to application of modulated frequency calls frequency, often Individual interface server receives the request of corresponding interface interchange all can normal process;If modulated frequency reaches Shen Please call frequency, then whichever interface server receives the request of corresponding interface interchange and all can limit, Achieve the accurate control of interface interchange frequency.
As shown in Figure 6, in one embodiment, it is provided that a kind of interface interchange frequency control method, this reality Execute the frequency that example is applied in above-mentioned Fig. 2 to Fig. 4 in this way to control server 230 and illustrate.Should Method specifically includes following steps:
Step 602, that collects that each interface server reports corresponding with interface identifier calls frequency.
Specifically, each interface server in real time or can report the tune corresponding with interface identifier according to report cycle With frequency, frequency control that server collects that each interface server in real time or reports according to report cycle with please Ask end mark and interface identifier corresponding call frequency.Report cycle controls the cycle less than frequency, such as reports Cycle can be 5 seconds, and frequency controls the cycle can be such as 1 minute.Report cycle adjustable, adjusts report cycle The little accuracy that can further improve frequency control, tunes up report cycle and can reduce frequency control server Resource consumption.
Call frequency to refer to reflect the tolerance calling frequency, can be by call number or in the unit interval Frequency of calling represent.Interface identifier, can be according to this interface identifier for uniquely identifying corresponding interface Call corresponding interface.Corresponding with interface identifier calls frequency, refers to call corresponding the connecing of this interface identifier The frequency of mouth.The frequency that calls collected can be that corresponding interface server is newly-increased in a report cycle Call frequency, it is also possible to be accumulative within a frequency control cycle to call frequency.
Step 604, collects the frequency that calls collected according to the frequency control cycle, it is thus achieved that with interface identifier Corresponding modulated frequency.
Specifically, frequency control server can by within a frequency control cycle collect with interface identifier pair The frequency that calls answered adds up, it is thus achieved that the modulated frequency corresponding with interface identifier.
In one embodiment, step 604 includes: according to calling of collecting within the current frequency control cycle Frequency updates the modulated frequency corresponding with interface identifier of caching in shared drive;Week is controlled at current frequency At the end of phase, modulated frequency corresponding with interface identifier for shared drive is reset.
Specifically, frequency control server specifically can read the Shen corresponding with interface identifier from database server Please call frequency, and application be called in frequency, modulated frequency and interface identifier be buffered in accordingly and share In depositing.
The frequency control cycle is the cycle that docking port server calls that frequency controls, such as 30 seconds or 1 Minute etc..Frequency controls server and often receives call frequently corresponding with interface identifier that interface server reports Degree, then read the modulated frequency corresponding with this interface identifier from shared drive and frequency called in application.If The current frequency control cycle does not terminates, then be added in the modulated frequency read by the frequency that calls received, And the modulated frequency updated and interface identifier are write in shared drive accordingly.If current frequency controls week Phase terminates, then, after being reset by modulated frequency, call, by receive, the modulated frequency that frequency is added to read In degree, and the modulated frequency updated and interface identifier are write in shared drive accordingly.
Step 606, obtains the application corresponding with interface identifier and calls frequency.
In one embodiment, this interface interchange frequency control method also includes: read and interface from database Frequency is called in the application of mark correspondence, and application is called frequency and called application platform according to the tune received by frequency With in application write into Databasce;Application is called that frequency is corresponding with interface identifier to be cached in shared drive.Frequently Degree control server specifically can read the application corresponding with interface identifier from shared drive and call frequency.
Specifically, request end can be called application platform to frequency in advance and be initiated to call application, and frequency calls application This is called application and verifies by platform, if being verified, in database server, application is called in write Content.The content calling application includes that the corresponding relation of frequency is called in interface identifier and application.Frequency controls clothes Business device then reads interface identifier from database server and application is called the corresponding relation of frequency and is cached to share In internal memory.
Step 608, if modulated frequency reaches application calls frequency, then exists to each interface server Batch sending In the restriction time, the interface interchange corresponding with interface identifier is asked the interface interchange limitation notification limited.
Specifically, modulated frequency and application are called frequency and compare by frequency control server, if modulated Calling frequency with frequency more than or equal to application, the most modulated frequency reaches application and calls frequency, then to institute Some interface server transmission interfaces call limitation notification.Interface interchange limitation notification includes interface identifier and limit Time processed, for notifying that corresponding with this interface identifier was connect within this restriction time by corresponding interface server Mouth call request limits.If the request of certain interface interchange is limited by interface server, then it is rejected by this Interface interchange is asked, and returns, to the request end initiating the request of this interface interchange, the feedback information that request is limited. The time that wherein limits can be specifically to limit the time point terminated, and the time that such as limits can be current frequency control The time point of end cycle processed;The restriction time can also be to limit the duration maintained.
Above-mentioned interface interchange frequency control method, under the scene of multiple interface servers, by each interface service What device reported call frequency carries out collecting and obtaining modulated frequency, and this modulated frequency can accurately reflect out many What individual interface server was the most total calls frequency.Again by the application of modulated frequency and pre-first to file is adjusted Compare with frequency, if modulated frequency reaches application calls frequency, give notice to each interface server batch, Each interface server docking port call request within the restriction time is limited.So without ensureing interface Call request uniformly falls on each interface server, if the not up to application of modulated frequency calls frequency, often Individual interface server receives the request of corresponding interface interchange all can normal process;If modulated frequency reaches Shen Please call frequency, then whichever interface server receives the request of corresponding interface interchange and all can limit, Achieve the accurate control of interface interchange frequency.
As it is shown in fig. 7, in one embodiment, it is provided that a kind of interface interchange frequency control method, including:
Step 702, collects call frequently corresponding with request end mark and interface identifier that each interface server reports Degree.
Step 704, collects the frequency that calls collected according to the frequency control cycle, it is thus achieved that mark with request end Know and modulated frequency corresponding to interface identifier.
Step 706, obtains the application corresponding with request end mark and interface identifier and calls frequency.
Step 708, if modulated frequency reaches application calls frequency, then exists to each interface server Batch sending The interface in the restriction time limited the interface interchange request corresponding with request end mark and interface identifier is adjusted Use limitation notification.
In the present embodiment, it is possible not only to distinguishing interface mark and concrete interface interchange is called the control of frequency System, it is also possible to distinguish request end, the interface interchange of different request ends is controlled so that docking port is adjusted Control more accurate.
As shown in Figure 8, in one embodiment, a kind of interface interchange frequency control method, specifically include:
Step 802, receiving interface server report 802 report with request end mark and interface identifier corresponding Call frequency.Wherein request end mark can be request end IP (Internet Protocol, procotol) Location or MAC (Media Access Control, medium access control) address.
Step 804, read from shared drive identify with request end and modulated frequency corresponding to interface identifier and Frequency is called in application.
Step 806, controls the cycle, then to be reset by the modulated frequency read if having arrived next frequency.
Step 808, reported by modulated frequency calls frequency, and updates in shared drive.
Step 810, if modulated frequency reaches application calls frequency, then connects to each interface server Batch sending Mouth calls limitation notification, and interface interchange limitation notification includes request end mark, interface identifier and restriction time.
In the present embodiment, controlled the shared drive of server by frequency, different request ends, difference can be connect The frequency that calls of mouth carries out centerized fusion efficiently and accurately.
As it is shown in figure 9, in one embodiment, a kind of interface interchange frequency control method, specifically include:
Step 902, collects call frequently corresponding with request end mark and interface identifier that each interface server reports Degree.
Specifically, request end is divided into different request end clusters, and different request end clusters is by request End cluster identity is uniquely distinguished.What frequency controlled that server can collect that each interface server reports marks with request end Know and interface identifier be corresponding calls frequency, or collect that each interface server reports with request end cluster mark Know and interface identifier corresponding call frequency.
Step 904, collects the frequency that calls collected according to the frequency control cycle, it is thus achieved that mark with request end Know and modulated frequency corresponding to interface identifier.
Specifically, frequency controls server and can determine that the request end cluster identity corresponding to the mark of request end, from And according to the frequency control cycle, the call frequency corresponding with request end cluster identity and interface identifier collected is entered Row collects, it is thus achieved that the modulated frequency corresponding with request end cluster identity and interface identifier.
Step 906, obtains the request end cluster identity corresponding to the mark of request end, and obtains and request end cluster Frequency is called in mark and application corresponding to interface identifier.
Specifically, shared drive is cached with request end mark and the subordinate relation of request end cluster identity, mark Know the attaching relation of corresponding request end and corresponding request end cluster.Frequency controls server can be in sharing Deposit the request end cluster identity corresponding to read requests end mark, thus obtain and this request end cluster identity And application corresponding to interface identifier call frequency.
Step 908, if modulated frequency reaches application calls frequency, then exists to each interface server Batch sending The interface in the restriction time limited the interface interchange request corresponding with request end mark and interface identifier is adjusted Use limitation notification.
In the present embodiment, request end is divided into different request end clusters, asking in the cluster of same request end Ask end to share identical application and call frequency, the frequency of the interface interchange to request end can be carried out according to request end cluster Degree is controlled.In actual applications, new request end can be added existing request end cluster to come directly Frequency is called in the application using existing request end cluster identity corresponding, by the request at replacement request end place End cluster just can change corresponding frequency control strategy.
In one embodiment, it can be multiple that frequency controls server, and interface server is upper in this case When frequency calls in class, the frequency that calls that need to be identified by same-interface is routed on identical frequency control server.
As shown in Figure 10, in one embodiment, it is provided that a kind of interface interchange request processing method, this reality Execute the interface server 220 that example is applied in above-mentioned Fig. 2 to 4 in this way to illustrate.The method has Body comprises the steps:
Step 1002, controls server to frequency and reports and corresponding with interface identifier call frequency so that frequency Control the frequency that calls that server reports according to each interface server to carry out collecting and obtain modulated frequency.
In one embodiment, step 1002 includes: according to the tune that report cycle statistics is corresponding with interface identifier With frequency and report to frequency control server, and report cycle less than frequency control the cycle.Report cycle is little Can be 5 seconds in the frequency control cycle, such as report cycle, frequency controls the cycle can be such as 1 minute.Report Cycle adjustable, turns down report cycle and can further improve the accuracy that frequency controls, and is adjusted by report cycle Frequency can be reduced greatly and control the resource consumption of server.
Step 1004, receives frequency and controls server and reach the application corresponding with interface identifier at modulated frequency The interface interchange limitation notification sent when calling frequency.
Specifically, interface server will call frequency and be reported to frequency to control after server, frequency control clothes Business device is implemented the interface interchange frequency control method of each embodiment above-mentioned and is called at frequency report Reason, and receive the interface interchange limitation notification that frequency invoking server sends after treatment.
Step 1006, obtains interface identifier and the time of restriction according to interface interchange limitation notification.
Specifically, interface server is after receiving interface interchange limitation notification, from interface interchange limitation notification In extract interface identifier and restriction time, and the interface identifier extracted and restriction time are cached accordingly In shared drive.
Step 1008, receives the interface interchange request carrying interface identifier.
Step 1010, if receive interface interchange request time within the restriction time corresponding with interface identifier, Then docking port call request limits.
Specifically, interface server receives the interface interchange request carrying interface identifier that request end sends, And from interface interchange is asked, extract interface identifier, thus read and this interface identifier pair from shared drive The restriction time answered.If receive interface interchange request time within the restriction time read, such as when The request of this interface interchange less than the time point represented by the restriction time, is then limited by front time point, and to Request end returns the feedback information that request is limited.
Above-mentioned interface interchange request processing method, under the scene of multiple interface servers, by each interface service What device reported call frequency carries out collecting and obtaining modulated frequency, and this modulated frequency can accurately reflect out many What individual interface server was the most total calls frequency.Again by the application of modulated frequency and pre-first to file is adjusted Compare with frequency, if modulated frequency reaches application calls frequency, give notice to each interface server batch, Each interface server docking port call request within the restriction time is limited.So without ensureing interface Call request uniformly falls on each interface server, if the not up to application of modulated frequency calls frequency, often Individual interface server receives the request of corresponding interface interchange all can normal process;If modulated frequency reaches Shen Please call frequency, then whichever interface server receives the request of corresponding interface interchange and all can limit, Achieve the accurate control of interface interchange frequency.
In one embodiment, this interface interchange request processing method also includes: please if receiving interface interchange The time asked exceedes the restriction time, then carry out interface interchange according to interface interchange request, and update and interface mark That knows correspondence calls frequency;The frequency that calls of interface identifier and renewal is reported to frequency control server.
Specifically, interface server is not if it is determined that inquire and the interface identifier pair entrained by interface interchange request The restriction time answered, or receive interface interchange request time exceed with interface interchange request entrained by The restriction time that interface identifier is corresponding, then the request of this interface interchange of normal response, asks according to this interface interchange Carry out the operation of interface interchange, and carry out data produced by interface interchange to request end feedback.
Interface server is asked, to corresponding the calling of corresponding interface identifier for the interface interchange of normal response Frequency is updated, and is cached to accordingly in shared drive with interface identifier by the frequency that calls updated.Connect It is all that oral business implement body can produce in periodically reading this report cycle from shared drive according to report cycle Call the identification information such as frequency and corresponding interface identifier, be combined as a packet and be sent to frequency control clothes Business device, so can save interface server and the resource consumption of frequency control server.
In the present embodiment, just can continue when the restriction time lost efficacy normally to respond the interface that request end is initiated Call request, without frequency control server control under cancel limit, can reduce interface server with Frequency controls the resource consumption brought alternately between server.
As shown in figure 11, in one embodiment, a kind of interface interchange request processing method, including:
Step 1102, controls server to frequency and reports call frequently corresponding with request end mark and interface identifier Degree so that frequency controls the frequency that calls that server reports according to each interface server and carries out collecting and obtain Call frequency.
Step 1104, receive frequency control server modulated frequency reach and request end mark and interface mark Know the interface interchange limitation notification sent when frequency is called in corresponding application.
Step 1106, obtains request end mark, interface identifier and the time of restriction according to interface interchange limitation notification.
Step 1108, receives the interface interchange request carrying request end mark and interface identifier.
Step 1110, if receiving the time of interface interchange request corresponding with request end mark and interface identifier The restriction time in, then docking port call request limits.
In the present embodiment, it is possible not only to distinguishing interface mark and concrete interface interchange is called the control of frequency System, it is also possible to distinguish request end, the interface interchange of different request ends is controlled so that docking port is adjusted Control more accurate.
As shown in figure 12, in one embodiment, a kind of interface interchange request processing method, including:
Step 1202, receives the interface interchange request carrying request end mark and interface identifier.
Step 1204, from shared drive read with request end identify and interface identifier corresponding call frequency and The restriction time.
Step 1206, if receiving the time of interface interchange request corresponding with request end mark and interface identifier The restriction time in, then docking port call request limits.
Step 1208, if receive interface interchange request time exceed the restriction time, then according to interface interchange Request carries out interface interchange, and updates and identify with request end and interface identifier is corresponding calls frequency.
Step 1210, produce in periodically reading this report cycle from shared drive according to report cycle is all Call frequency and corresponding interface identifier and request end mark.
Step 1211, all calls frequency and corresponding interface identifier and request end mark is combined as one by read Individual packet is sent to frequency and controls server.Frequency controls server after receiving packet from packet In parse and call frequency and corresponding interface identifier and request end identify and be cached to frequency control server In shared drive.
Step 1212, receive frequency control server modulated frequency reach and request end mark and interface mark Knowing the interface interchange limitation notification sent when frequency is called in corresponding application, interface interchange limitation notification includes please Ask end mark, interface identifier and restriction time.
Step 1214, updates the limit corresponding with request end mark and interface identifier according to interface interchange limitation notification Time processed.
In the present embodiment, by the shared drive of interface server, can be to different request ends, distinct interface Call frequency to carry out unifying to report, improve the efficiency that interface interchange frequency controls.
As shown in figure 13, in one embodiment, step 1010 specifically includes following steps:
Step 1302, obtains the request end cluster identity entrained by interface interchange request.
Specifically, the interface interchange request received in the present embodiment carries interface identifier and request end cluster Mark, the request end cluster identity that this carries is for specifying belonging to the request end initiating the request of this interface interchange Request end cluster.
In one embodiment, step 1302 includes: extract the request end mark entrained by interface interchange request With request end cluster identity, it is judged that whether the request end mark of extraction and request end cluster identity exist subordinate closes System;If existing, then continue executing with step 1304;If not existing, the most directly limit the request of this interface interchange.
Step 1304, it is judged that whether the request end cluster identity of acquisition exists the application of correspondence is called frequency.
Specifically, interface server can according to request end cluster identity in database server or shared drive, The corresponding relation of frequency is called in interface identifier and application, it is judged that whether the request end cluster identity of acquisition exists Frequency is called in corresponding application.If existing, then continue executing with step 1306;If not existing, then normal response This interface interchange is asked.
Step 1306, if there is corresponding application to call frequency, and the time receiving interface interchange request exists In the restriction time corresponding with request end cluster identity and interface identifier, then docking port call request limits.
Specifically, if there is corresponding application to call frequency, then can use corresponding to this request end cluster identity Application call frequency to this interface interchange request carry out frequency control process.Specifically can be in shared drive In the request end mark corresponding with restriction time and the interface identifier that carries, search and belong to this request end cluster mark The request end mark known.If can find, and receive interface interchange request time with find please Asking in holding the restriction time that the interface identifier identifying and carrying is corresponding, this restriction time is considered to be and this request End cluster identity is corresponding, then docking port call request limits.
In one embodiment, step 1006 includes: according to interface interchange limitation notification obtain interface identifier, Request end cluster identity and the time of restriction.Then step 1306 includes: if there is corresponding application to call frequency, And receive time of interface interchange request read from shared drive with request end cluster identity and connecing In the restriction time that mouth mark is corresponding, then docking port call request limits.
In the present embodiment, request end is divided into different request end clusters, asking in the cluster of same request end Ask end to share identical application and call frequency, the frequency of the interface interchange to request end can be carried out according to request end cluster Degree is controlled.In actual applications, new request end can be added existing request end cluster to come directly Frequency is called in the application using existing request end cluster identity corresponding, by the request at replacement request end place End cluster just can change corresponding frequency control strategy.
As shown in figure 14, in one embodiment, step 1010 specifically includes following steps:
Step 1402, obtains the request end mark entrained by interface interchange request.
Specifically, the interface interchange request received in the present embodiment carries interface identifier, and not specified Play the request end cluster belonging to request end of this interface interchange request.
Step 1404, the request end cluster identity belonging to inquiry request end mark.
Specifically, interface server can identify according to request end in shared drive or database server and please Seek the subordinate relation between end cluster identity, belonging to the request end mark entrained by query interface call request Request end cluster identity.
Step 1406, it is judged that whether the request end cluster identity inquired exists the application of correspondence is called frequency.
Specifically, interface server can according to request end cluster identity in database server or shared drive, The corresponding relation of frequency is called in interface identifier and application, it is judged that whether the request end cluster identity of acquisition exists Frequency is called in corresponding application.If existing, then continue executing with step 1306;If not existing, then normal response This interface interchange is asked.
Step 1408, if there is corresponding application to call frequency, and the time receiving interface interchange request exists In the restriction time corresponding with request end cluster identity and interface identifier, then docking port call request limits.
Specifically, if there is corresponding application to call frequency, then can use corresponding to this request end cluster identity Application call frequency to this interface interchange request carry out frequency control process.Specifically can be in shared drive In the request end mark corresponding with restriction time and the interface identifier that carries, search and belong to this request end cluster mark The request end mark known.If can find, and receive interface interchange request time with find please Asking in holding the restriction time that the interface identifier identifying and carrying is corresponding, this restriction time is considered to be and this request End cluster identity is corresponding, then docking port call request limits.
In one embodiment, step 1006 includes: according to interface interchange limitation notification obtain interface identifier, Request end cluster identity and the time of restriction.Then step 1408 includes: if there is corresponding application to call frequency, And receive time of interface interchange request read from shared drive with request end cluster identity and connecing In the restriction time that mouth mark is corresponding, then docking port call request limits.
In the present embodiment, request end is divided into different request end clusters, asking in the cluster of same request end Ask end to share identical application and call frequency, the frequency of the interface interchange to request end can be carried out according to request end cluster Degree is controlled.In actual applications, new request end can be added existing request end cluster to come directly Frequency is called in the application using existing request end cluster identity corresponding, by the request at replacement request end place End cluster just can change corresponding frequency control strategy.
As shown in figure 15, in one embodiment, it is provided that a kind of interface interchange frequency controls device 1500, Including: call frequency collection module 1501, call frequency summarizing module 1502 and interface interchange control module 1503。
Call frequency collection module 1501, corresponding with interface identifier for collect that each interface server reports Call frequency.
Call frequency summarizing module 1502, for being converged by the frequency that calls collected according to the frequency control cycle Always, it is thus achieved that the modulated frequency corresponding with interface identifier.
Interface interchange control module 1503, calls frequency for obtaining the application corresponding with interface identifier.If Call frequency to reach application and call frequency, then to each interface server Batch sending within the restriction time to connect The interface interchange request of mouth mark correspondence carries out the interface interchange limitation notification limited.
Above-mentioned interface interchange frequency controls device 1500, under the scene of multiple interface servers, by each interface What server reported call frequency carries out collecting and obtaining modulated frequency, and this modulated frequency can accurately reflect Go out multiple interface server the most total call frequency.Again by by modulated frequency and the Shen of pre-first to file Please call frequency to compare, if modulated frequency reaches application calls frequency, send to each interface server batch Notice so that each interface server docking port call request within the restriction time limits.So without protecting Card interface interchange request uniformly falls on each interface server, if frequency is called in the not up to application of modulated frequency Degree, each interface server receives the request of corresponding interface interchange can normal process;If modulated frequency Reach application and call frequency, then whichever interface server receive corresponding interface interchange request all can enter Row limits, it is achieved that the accurate control of interface interchange frequency.
In one embodiment, call frequency collection module 1501 specifically for collect each interface server according to What report cycle reported corresponding with request end mark and interface identifier calls frequency, and report cycle is less than frequency The degree control cycle.
Interface interchange control module 1503 is specifically for obtaining the application corresponding with request end mark and interface identifier Call frequency;If modulated frequency reaches application calls frequency, then to each interface server Batch sending in limit In time processed, the interface interchange corresponding with request end mark and interface identifier is asked the interface interchange limited Limitation notification.
In the present embodiment, it is possible not only to distinguishing interface mark and concrete interface interchange is called the control of frequency System, it is also possible to distinguish request end, the interface interchange of different request ends is controlled so that docking port is adjusted Control more accurate.
In one embodiment, frequency summarizing module 1502 is called specifically for controlling week according at current frequency The frequency that calls collected in phase updates the modulated frequency corresponding with interface identifier of caching in shared drive;? Current frequency controls to be reset by modulated frequency corresponding with interface identifier for shared drive during end cycle.
In one embodiment, calling frequency summarizing module 1502 will receipts specifically for controlling the cycle according to frequency The frequency that calls of collection collects, it is thus achieved that the modulated frequency corresponding with request end mark and interface identifier.
Interface interchange control module 1503 is specifically for obtaining the request end cluster mark corresponding to the mark of request end Know, and frequency is called in the acquisition application corresponding with request end cluster identity and interface identifier;If modulated frequency Reach application and call frequency, then identify with request end within the restriction time to each interface server Batch sending And interface interchange request corresponding to interface identifier carries out the interface interchange limitation notification that limits.
In the present embodiment, request end is divided into different request end clusters, asking in the cluster of same request end Ask end to share identical application and call frequency, the frequency of the interface interchange to request end can be carried out according to request end cluster Degree is controlled.In actual applications, new request end can be added existing request end cluster to come directly Frequency is called in the application using existing request end cluster identity corresponding, by the request at replacement request end place End cluster just can change corresponding frequency control strategy.
As shown in figure 16, in one embodiment, interface interchange frequency control device 1500 also includes: number According to management module 1504, calling frequency for reading the application corresponding with interface identifier from database, application is adjusted Called application platform with frequency by frequency to call in application write into Databasce according to receive;Application is called Frequency is corresponding with interface identifier to be cached in shared drive.
Interface interchange control module 1503 is specifically for reading the application corresponding with interface identifier from shared drive Call frequency.
In the present embodiment, called by frequency and apply for that each request end is called application and accepted by platform unification And authorize and call authority, and authorize call authority after by the content write into Databasce calling application, logical Cross inquiry database and just can quickly determine which interface needs to carry out frequency control.And application is called frequency Spend be cached in shared drive corresponding with interface identifier, so use when frequency is called in application the most permissible at needs Obtain application efficiently and call frequency.
As shown in figure 17, in one embodiment, it is provided that a kind of interface interchange request processing means 1700, Including: calling frequency reporting module 1701, interface interchange limitation notification processing module 1702 and interface interchange please Seek processing module 1703.
Call frequency reporting module 1701, report the tune corresponding with interface identifier for controlling server to frequency With frequency so that frequency controls the frequency that calls that server reports according to each interface server and collects and obtain Obtain modulated frequency.
Interface interchange limitation notification processing module 1702, is used for receiving frequency and controls server at modulated frequency The interface interchange limitation notification that the application reaching corresponding with interface identifier sends when calling frequency.Adjust according to interface Interface identifier and the time of restriction is obtained by limitation notification.
Interface interchange request processing module 1703, for receiving the interface interchange request carrying interface identifier. If receive interface interchange request time within the restriction time corresponding with interface identifier, then docking port calls Request limits.
Above-mentioned interface interchange request processing means 1700, under the scene of multiple interface servers, by each interface What server reported call frequency carries out collecting and obtaining modulated frequency, and this modulated frequency can accurately reflect Go out multiple interface server the most total call frequency.Again by by modulated frequency and the Shen of pre-first to file Please call frequency to compare, if modulated frequency reaches application calls frequency, send to each interface server batch Notice so that each interface server docking port call request within the restriction time limits.So without protecting Card interface interchange request uniformly falls on each interface server, if frequency is called in the not up to application of modulated frequency Degree, each interface server receives the request of corresponding interface interchange can normal process;If modulated frequency Reach application and call frequency, then whichever interface server receive corresponding interface interchange request all can enter Row limits, it is achieved that the accurate control of interface interchange frequency.
In one embodiment, ask if interface interchange request processing module 1703 is additionally operable to receive interface interchange The time asked exceedes the restriction time, then carry out interface interchange according to interface interchange request, and update and interface mark That knows correspondence calls frequency.
Call frequency reporting module 1701 to be additionally operable to the frequency that calls of interface identifier and renewal is reported to frequency control Control server.
In the present embodiment, just can continue when the restriction time lost efficacy normally to respond the interface that request end is initiated Call request, without frequency control server control under cancel limit, can reduce interface server with Frequency controls the resource consumption brought alternately between server.
In one embodiment, frequency reporting module 1701 is called specifically for adding up according to report cycle and connecing What mouth mark was corresponding calls frequency and reports to frequency control server, and report cycle is less than frequency control week Phase.
In one embodiment, call frequency reporting module 1701 to report specifically for controlling server to frequency Corresponding with request end mark and interface identifier calls frequency.
Interface interchange limitation notification processing module 1702 is specifically for obtaining request according to interface interchange limitation notification End mark, interface identifier and the time of restriction.
Interface interchange request processing module 1703 carries request end mark and interface identifier specifically for receiving Interface interchange is asked.If receiving the time of interface interchange request corresponding with request end mark and interface identifier The restriction time in, then docking port call request limits.
In the present embodiment, it is possible not only to distinguishing interface mark and concrete interface interchange is called the control of frequency System, it is also possible to distinguish request end, the interface interchange of different request ends is controlled so that docking port is adjusted Control more accurate.
In one embodiment, interface interchange request processing module 1703 is specifically for obtaining interface interchange request Entrained request end cluster identity;Judge whether the request end cluster identity obtained exists the application tune of correspondence Use frequency;If there is corresponding application to call frequency, and receive time of interface interchange request with request End cluster identity and in restriction time corresponding to interface identifier, then docking port call request limits.
In one embodiment, interface interchange request processing module 1703 is specifically for obtaining interface interchange request Entrained request end mark;Request end cluster identity belonging to inquiry request end mark;Judgement inquires Whether request end cluster identity exists the application of correspondence is called frequency;If there is corresponding application to call frequency, And receive the time of interface interchange request in the restriction time corresponding with request end cluster identity and interface identifier In, then docking port call request limits.
In the present embodiment, request end is divided into different request end clusters, asking in the cluster of same request end Ask end to share identical application and call frequency, the frequency of the interface interchange to request end can be carried out according to request end cluster Degree is controlled.In actual applications, new request end can be added existing request end cluster to come directly Frequency is called in the application using existing request end cluster identity corresponding, by the request at replacement request end place End cluster just can change corresponding frequency control strategy.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, Can be by computer program and complete to instruct relevant hardware, this computer program can be stored in a meter In calculation machine read/write memory medium, this program is upon execution, it may include such as the stream of the embodiment of above-mentioned each method Journey.Wherein, aforesaid storage medium can be magnetic disc, CD, read-only store-memory body (Read-Only Memory, The non-volatile memory medium such as ROM), or random store-memory body (Random Access Memory, RAM) Deng.
Each technical characteristic of above example can combine arbitrarily, for making description succinct, not to above-mentioned The all possible combination of each technical characteristic in embodiment is all described, but, as long as these technology are special There is not contradiction in the combination levied, is all considered to be the scope that this specification is recorded.
Above example only have expressed the several embodiments of the present invention, and it describes more concrete and detailed, but Can not therefore be construed as limiting the scope of the patent.It should be pointed out that, general for this area For logical technical staff, without departing from the inventive concept of the premise, it is also possible to make some deformation and improvement, These broadly fall into protection scope of the present invention.Therefore, the protection domain of patent of the present invention should be wanted with appended right Ask and be as the criterion.

Claims (13)

1. an interface interchange frequency control method, described method includes:
That collects that each interface server reports corresponding with interface identifier calls frequency;
According to the frequency control cycle, the frequency that calls collected is collected, it is thus achieved that corresponding with described interface identifier Modulated frequency;
Obtain the application corresponding with described interface identifier and call frequency;
If described modulated frequency reaches described application calls frequency, then send out to described each interface server batch Send the interface interchange limit within the restriction time, the interface interchange request corresponding with described interface identifier limited System notice.
Method the most according to claim 1, it is characterised in that each interface server of described collection reports Corresponding with interface identifier call frequency, including:
Collect the tune corresponding with request end mark and interface identifier that each interface server reports according to report cycle With frequency, and described report cycle controls the cycle less than described frequency;
Frequency is called in the described acquisition application corresponding with described interface identifier, including:
Obtain the application corresponding with described request end mark and described interface identifier and call frequency;
Described to described each interface server Batch sending within the restriction time to corresponding with described interface identifier Interface interchange request carries out the interface interchange limitation notification limited, including:
To described each interface server Batch sending within the restriction time to described request end mark and described in connect The interface interchange request of mouth mark correspondence carries out the interface interchange limitation notification limited.
Method the most according to claim 1, it is characterised in that described general according to the frequency control cycle is received The frequency that calls of collection collects, it is thus achieved that the modulated frequency corresponding with described interface identifier, including:
According to collect within the current frequency control cycle call frequency update caching in shared drive with described The modulated frequency that interface identifier is corresponding;
When current frequency controls end cycle by modulated frequency corresponding with described interface identifier for shared drive Reset.
Method the most according to claim 1, it is characterised in that described method also includes:
Reading the application corresponding with interface identifier from database and call frequency, described application calls frequency by frequency Call application platform to write in described database according to the application of calling received;
Described application is called that frequency is corresponding with described interface identifier to be cached in shared drive;
Frequency is called in the described acquisition application corresponding with described interface identifier, including:
From shared drive, read the application corresponding with described interface identifier call frequency.
Method the most according to claim 1, it is characterised in that described general according to the frequency control cycle is received The frequency that calls of collection collects, it is thus achieved that the modulated frequency corresponding with described interface identifier, including:
According to the frequency control cycle, the frequency that calls collected is collected, it is thus achieved that identify and described with request end The modulated frequency that interface identifier is corresponding;
Frequency is called in the described acquisition application corresponding with described interface identifier, including:
Obtain the request end cluster identity corresponding to the mark of described request end, and obtain and described request end cluster Frequency is called in mark and application corresponding to interface identifier;
Described to described each interface server Batch sending within the restriction time to corresponding with described interface identifier Interface interchange request carries out the interface interchange limitation notification limited, including:
To described each interface server Batch sending within the restriction time to described request end mark and described in connect The interface interchange request of mouth mark correspondence carries out the interface interchange limitation notification limited.
6. an interface interchange request processing method, described method includes:
Control server to frequency to report and corresponding with interface identifier call frequency so that described frequency controls clothes The frequency that calls that business device reports according to each interface server carries out collecting and obtains modulated frequency;
Receive described frequency to control server and reach the Shen corresponding with described interface identifier at described modulated frequency The interface interchange limitation notification sent when please call frequency;
Described interface identifier and the time of restriction is obtained according to described interface interchange limitation notification;
Receive the interface interchange request carrying described interface identifier;
If receiving the time of described interface interchange request in the described restriction time corresponding with described interface identifier In, then the request of described interface interchange is limited.
Method the most according to claim 6, it is characterised in that described method also includes:
If the time receiving the request of described interface interchange exceedes the described restriction time, then adjust according to described interface Carry out interface interchange with request, and update and corresponding with described interface identifier call frequency;
The frequency that calls of described interface identifier and renewal is reported to described frequency control server.
Method the most according to claim 6, it is characterised in that described to frequency control server report Corresponding with interface identifier calls frequency, including:
According to call frequency and report to described frequency control service corresponding with interface identifier of report cycle statistics Device, and described report cycle is less than the described frequency control cycle.
Method the most according to claim 6, it is characterised in that described to frequency control server report Corresponding with interface identifier calls frequency, including:
To frequency control server report with request end mark and interface identifier corresponding call frequency;
Described according to described interface interchange limitation notification obtain described interface identifier and limit the time, including:
When obtaining described request end mark, described interface identifier according to described interface interchange limitation notification and limit Between;
The request of described interface interchange also carries described request end mark;If described interface interchange is received described Described interface interchange within the described restriction time corresponding with described interface identifier, is then asked by the time of request Limit, including:
If the time receiving the request of described interface interchange is identifying and described interface identifier pair with described request end In the described restriction time answered, then the request of described interface interchange is limited.
Method the most according to claim 6, it is characterised in that receive described interface tune if described With the time of request within the described restriction time corresponding with described interface identifier, then please to described interface interchange Ask and limit, including:
Obtain the request end cluster identity entrained by the request of described interface interchange;
Judge whether the request end cluster identity obtained exists corresponding application and call frequency;
If there is corresponding application to call frequency, and receive the time of described interface interchange request with described Request end cluster identity and in described restriction time corresponding to described interface identifier, then please to described interface interchange Ask and limit.
11. methods according to claim 6, it is characterised in that receive described interface tune if described With the time of request within the described restriction time corresponding with described interface identifier, then please to described interface interchange Ask and limit, including:
Obtain the request end mark entrained by the request of described interface interchange;
Inquire about the request end cluster identity belonging to the mark of described request end;
Judge whether the request end cluster identity inquired exists corresponding application and call frequency;
If there is corresponding application to call frequency, and receive the time of described interface interchange request with described Request end cluster identity and in described restriction time corresponding to described interface identifier, then please to described interface interchange Ask and limit.
12. 1 kinds of interface interchange frequency control device, it is characterised in that described device includes:
Call frequency collection module, for collecting call corresponding with interface identifier that each interface server reports Frequency;
Call frequency summarizing module, for the frequency that calls collected being collected according to the frequency control cycle, Obtain the modulated frequency corresponding with described interface identifier;
Interface interchange control module, calls frequency for obtaining the application corresponding with described interface identifier;If institute State modulated frequency to reach described application and call frequency, then limiting to described each interface server Batch sending In time, the interface interchange corresponding with described interface identifier is asked the interface interchange limitation notification limited.
13. 1 kinds of interface interchange request processing meanss, it is characterised in that described device includes:
Call frequency reporting module, report call frequently corresponding with interface identifier for controlling server to frequency Degree so that described frequency controls the frequency that calls that server reports according to each interface server and collects and obtain Obtain modulated frequency;
Interface interchange limitation notification processing module, is used for receiving described frequency and controls server in described modulated use Frequency reaches the interface interchange limitation notification sent when frequency is called in the application corresponding with described interface identifier;Root Described interface identifier and the time of restriction is obtained according to described interface interchange limitation notification;
Interface interchange request processing module, for receiving the interface interchange request carrying described interface identifier; If receive described interface interchange request time within the described restriction time corresponding with described interface identifier, Then the request of described interface interchange is limited.
CN201610197050.2A 2016-03-31 2016-03-31 Interface calling frequency control method and device and interface calling request processing method and device Active CN105893150B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610197050.2A CN105893150B (en) 2016-03-31 2016-03-31 Interface calling frequency control method and device and interface calling request processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610197050.2A CN105893150B (en) 2016-03-31 2016-03-31 Interface calling frequency control method and device and interface calling request processing method and device

Publications (2)

Publication Number Publication Date
CN105893150A true CN105893150A (en) 2016-08-24
CN105893150B CN105893150B (en) 2021-04-20

Family

ID=57011788

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610197050.2A Active CN105893150B (en) 2016-03-31 2016-03-31 Interface calling frequency control method and device and interface calling request processing method and device

Country Status (1)

Country Link
CN (1) CN105893150B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106254537A (en) * 2016-09-22 2016-12-21 北京小米移动软件有限公司 Interface interchange method and apparatus
CN107070807A (en) * 2017-04-18 2017-08-18 北京思特奇信息技术股份有限公司 Global traffic control method and system that a kind of distributed environment lower interface is called
CN108572898A (en) * 2017-03-07 2018-09-25 北京京东尚科信息技术有限公司 A kind of method, apparatus of control interface, equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2234397A1 (en) * 2009-03-24 2010-09-29 Thomson Licensing Methods for delivering and receiving interactive multimedia data attached to an audio video content
CN102137091A (en) * 2010-11-15 2011-07-27 华为技术有限公司 Overload control method, device and system as well as client-side
CN102868770A (en) * 2011-07-05 2013-01-09 腾讯科技(北京)有限公司 Method, equipment and system for distributing interface
CN103379090A (en) * 2012-04-12 2013-10-30 腾讯科技(北京)有限公司 Open platform access frequency control method and system and frequency server
CN103701709A (en) * 2013-12-13 2014-04-02 北京京东尚科信息技术有限公司 Flow rate control method and system
CN104683457A (en) * 2015-02-13 2015-06-03 小米科技有限责任公司 Concurrency control method and device
CN105262821A (en) * 2015-10-29 2016-01-20 努比亚技术有限公司 Interface management apparatus and method

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2234397A1 (en) * 2009-03-24 2010-09-29 Thomson Licensing Methods for delivering and receiving interactive multimedia data attached to an audio video content
CN102137091A (en) * 2010-11-15 2011-07-27 华为技术有限公司 Overload control method, device and system as well as client-side
CN102868770A (en) * 2011-07-05 2013-01-09 腾讯科技(北京)有限公司 Method, equipment and system for distributing interface
CN103379090A (en) * 2012-04-12 2013-10-30 腾讯科技(北京)有限公司 Open platform access frequency control method and system and frequency server
CN103701709A (en) * 2013-12-13 2014-04-02 北京京东尚科信息技术有限公司 Flow rate control method and system
CN104683457A (en) * 2015-02-13 2015-06-03 小米科技有限责任公司 Concurrency control method and device
CN105262821A (en) * 2015-10-29 2016-01-20 努比亚技术有限公司 Interface management apparatus and method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106254537A (en) * 2016-09-22 2016-12-21 北京小米移动软件有限公司 Interface interchange method and apparatus
CN108572898A (en) * 2017-03-07 2018-09-25 北京京东尚科信息技术有限公司 A kind of method, apparatus of control interface, equipment and storage medium
CN107070807A (en) * 2017-04-18 2017-08-18 北京思特奇信息技术股份有限公司 Global traffic control method and system that a kind of distributed environment lower interface is called

Also Published As

Publication number Publication date
CN105893150B (en) 2021-04-20

Similar Documents

Publication Publication Date Title
CN110401662B (en) Industrial control equipment fingerprint identification method and storage medium
CN106302434A (en) Server adaptation method, device and system
CN102868770B (en) A kind of method of distribution interface, equipment and system
JP2001043158A (en) Management data processor and computer-readable recording medium recorded with management data processing program
CN112261175B (en) Asset information updating method, device, equipment and medium
US20140201356A1 (en) Monitoring system of managing cloud-based hosts and monitoring method using for the same
CN107707377A (en) A kind of method and system for analyzing network node availability
CN105893150A (en) Interface calling frequency control and interface calling request processing method and device
CN108984433B (en) Cache data control method and equipment
CN106066894A (en) Data global buffer method and data global buffer device
CN112491941A (en) Data management method, related product and communication system
CN108616896B (en) Operator identification method and device and internet access system
CN108540582B (en) Terminal identification processing method, server and terminal
CN113794781A (en) Data acquisition method, device, equipment and storage medium
CN108429641A (en) A kind of network device management method and device
CN110248156B (en) Video analysis method, platform equipment, intelligent camera and intelligent monitoring system
CN109587121B (en) Security policy control method and device
CN106790354A (en) A kind of communication means and its device of anti-data congestion
CN113364820A (en) Equipment control method and device of Internet of things service system
CN110519403A (en) A kind of gateway down-hanging device management method and system
CN109412940A (en) Router administration method and router management system
CN104735692A (en) Method, device and system for determining network use data
CN114520784A (en) Dynamic content accelerated access method and device
WO2021121176A1 (en) Method and device for updating status information of sim card, and server
KR100482283B1 (en) Method for managing asymmetric digital subscriber line in tims

Legal Events

Date Code Title Description
C06 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