CN105391758B - The method and apparatus of resource allocation in a kind of local area network - Google Patents

The method and apparatus of resource allocation in a kind of local area network Download PDF

Info

Publication number
CN105391758B
CN105391758B CN201510651077.XA CN201510651077A CN105391758B CN 105391758 B CN105391758 B CN 105391758B CN 201510651077 A CN201510651077 A CN 201510651077A CN 105391758 B CN105391758 B CN 105391758B
Authority
CN
China
Prior art keywords
client
grade
active state
state grade
active
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
CN201510651077.XA
Other languages
Chinese (zh)
Other versions
CN105391758A (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.)
Beijing Lajin Zhongbo Technology Co ltd
Tianmai Juyuan Smart Technology (Beijing) Co.,Ltd.
Original Assignee
TVM Beijing Education Technology 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 TVM Beijing Education Technology Co Ltd filed Critical TVM Beijing Education Technology Co Ltd
Priority to CN201510651077.XA priority Critical patent/CN105391758B/en
Publication of CN105391758A publication Critical patent/CN105391758A/en
Application granted granted Critical
Publication of CN105391758B publication Critical patent/CN105391758B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • 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/75Indicating network or usage conditions on the user display

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of method and apparatus of resource allocation in local area network, to improve the reasonability of resource allocation.Local area network include a main control end and at least one client, wherein, main control end is connect with n client, and n is the integer more than or equal to 1, this method comprises: determining the active state grade of each client according to the status information of control window corresponding with each client of connection;According to the active state grade of each client, the quantity n of connection client is updated;According to the updated quantity n, adjust the client currently connected, and corresponding resource is distributed to each client adjusted, in this way, main control end can be that client distributes Internet resources according to different connection quantity, Internet resources can be utilized to large extent, are not easily caused the idle of Internet resources, are reasonably assigned with resource.

Description

The method and apparatus of resource allocation in a kind of local area network
Technical field
The present invention relates to computer communication technology field, in particular to the method and dress of resource allocation in a kind of local area network It sets.
Background technique
Local area network (Local Area Network, LAN) is in the geographic range of a part by various computers, outer Portion's equipment and database etc. link up mutually the computer communication network of composition.It can pass through data communication network or exclusive data Circuit is connected with the local area network in a distant place, database or processing center, constitutes a large-scale information processing system.Local Net can be made of a main control end and multiple client, wherein main control end is connected with one, two or multiple client, and main Internet resources can be distributed for each client of connection by controlling end, to support the transmission of various files.
Currently, the network bandwidth in local area network is typically all fixation, in this way, just defining the client that main control end can connect Hold quantity.Such as: when setting client terminal quantity that main control end can connect as 20, then in the local area network, main control end can only be right This 20 clients distribute resources, and still, some clients disconnect or liveness is not high, the client there is no need to Resource or it is only necessary to less resources, at this point, the local area network still can only carry out resource allocations according to 20 clients, And the quantity connecting with main control end cannot be changed to 19 or other smaller value, and then can not be according to the visitor after change quantity Family end carries out resource allocation.As it can be seen that the client of this fixed quantity connects, the unreasonable of resource allocation will cause.
Summary of the invention
The present invention provides a kind of method and apparatus of resource allocation in local area network, to improve the reasonability of resource allocation.
The present invention provides a kind of method of resource allocation in local area network, local area network include a main control end and and at least one Client, wherein main control end is connect with n client, and n is the integer more than or equal to 1, this method comprises:
According to the status information of control window corresponding with each client of connection, the active state of each client is determined Grade;
According to the active state grade of each client, the quantity n of connection client is updated;
According to the updated quantity n, the client currently connected is adjusted, and to each client distribution adjusted Corresponding resource.
In one embodiment of the invention, the active state grade for stating determining each client includes:
If the current control window is in activation selected state, it is determined that the corresponding current visitor of the current control window The active state grade at family end is most to enliven grade, if the current control window is in un-activation selected state, it is determined that institute The active state grade for stating the corresponding active client of current control window is inactive grade;Or,
If the current control window is in maximum rating, it is determined that the corresponding active client of the current control window Active state grade be most enliven grade, if the current control window is in minimum state, it is determined that the current control The active state grade of the corresponding active client of window is inactive grade.
In one embodiment of the invention, the quantity n for updating connection client includes:
According to the corresponding relationship of the active state grade of preservation and active state grade point, the determining work with each client Jump the corresponding active state grade point of state grade;
The active state grade point of each client is compared with given threshold respectively, is updated and is connected according to comparison result Meet the quantity n of client.
In one embodiment of the invention, the quantity n for updating connection client according to comparison result includes:
If the active state grade point of active client is greater than given threshold, the quantity n is added 1;
If the active state grade point of active client is less than given threshold, the quantity n is subtracted 1.
It is described according to the updated quantity n in one embodiment of the invention, before adjusting the client currently connected, Further include:
Detect the connection status of the main control end;
If detecting when having newly-increased client to connect in the local area network with the main control end, the quantity n is added 1;
If detect that the first client disconnects the connection with the main control end in the client connecting with the main control end, The quantity n is subtracted 1.
The present invention provides a kind of device of resource allocation in local area network, the local area network include a main control end and at least One client, wherein main control end is connect with n client, and n is the integer more than or equal to 1, which includes:
Determination unit determines each visitor for the status information according to control window corresponding with each client of connection The active state grade at family end;
Updating unit updates the quantity n of connection client for the active state grade according to each client;
Allocation unit is adjusted, for adjusting the client currently connected according to the updated quantity n, and to adjustment Each client afterwards distributes corresponding resource.
In one embodiment of the invention, the determination unit is chosen if being in activation specifically for the current control window State, it is determined that the current active state grade for controlling the corresponding active client of window is most to enliven grade, if described Current control window be in un-activation selected state, it is determined that it is described it is current control the corresponding active client of window enliven shape State grade is inactive grade;Or, if the current control window is in maximum rating, it is determined that the current control window pair The active state grade for the active client answered is most to enliven grade, if the current control window is in minimum state, really The fixed current active state grade for controlling the corresponding active client of window is inactive grade.
In one embodiment of the invention, the updating unit includes:
First module, for the corresponding relationship according to the active state grade of preservation and active state grade point, determine with The corresponding active state grade point of the active state grade of each client;
Second module, for the active state grade point of each client to be compared with given threshold respectively, according to Comparison result updates the quantity n of connection client.
In one embodiment of the invention, second module, if the active state grade point specifically for active client is big When given threshold, the quantity n is added 1, it, will be described if the active state grade point of active client is less than given threshold Quantity n subtracts 1.
In one embodiment of the invention, the device further include: detection updating unit, for detecting the connection shape of the main control end The quantity n is added 1, if detecting if detecting when having newly-increased client to connect in the local area network with the main control end by state When the first client disconnects the connection with the main control end in the client connecting with the main control end, the quantity n is subtracted 1.
Some beneficial effects of the embodiment of the present invention may include:
According to the active state grade for each client being connect with main control end, adjusts main control end and currently connect client Quantity, and corresponding resource is distributed for each client adjusted, in this way, main control end is no longer the client with fixed number Connection, but when the client of connection is relatively enlivened, the client number of connection is increased, when the client of connection is inactive When, then the client number of connection is reduced, in this way, main control end can be that client distributes network money according to different connection quantity Source can utilize Internet resources to large extent, do not easily cause the idle of Internet resources, be reasonably assigned with resource.
Other features and advantages of the present invention will be illustrated in the following description, also, partly becomes from specification It obtains it is clear that understand through the implementation of the invention.The objectives and other advantages of the invention can be by written explanation Specifically noted structure is achieved and obtained in book, claims and attached drawing.
Below by drawings and examples, technical scheme of the present invention will be described in further detail.
Detailed description of the invention
Attached drawing is used to provide further understanding of the present invention, and constitutes part of specification, with reality of the invention It applies example to be used to explain the present invention together, not be construed as limiting the invention.In the accompanying drawings:
Fig. 1 is the flow chart of resource allocation in local area network in the embodiment of the present invention one;
Fig. 2 is the flow chart of resource allocation in local area network in the embodiment of the present invention two;
Fig. 3 is the flow chart of resource allocation in local area network in the embodiment of the present invention three;
Fig. 4 is the structure chart of the device of resource allocation in local area network in the embodiment of the present invention four.
Specific embodiment
Hereinafter, preferred embodiments of the present invention will be described with reference to the accompanying drawings, it should be understood that preferred reality described herein Apply example only for the purpose of illustrating and explaining the present invention and is not intended to limit the present invention.
Embodiment one, includes main control end in local area network, and one, two or more clients.Wherein, have n client with Main control end connection, can carry out the transmission of file.The connection quantity n of main control end and client is the integer more than or equal to 1.This implementation In example, the process of resource allocation is as shown in Figure 1 in local area network, comprising:
Step 101: according to the status information of control window corresponding with each client, determining enlivening for each client State grade.
There is multiple client in local area network, wherein n client is connect with main control end, in this way, can generally show in main control end Show control window corresponding with each client of connection, can be believed according to the state of control window corresponding with each client Breath, determines the active state grade of each client.Wherein, status information includes: state of activation information or size state information.
And the active state grade of client can also correspond to multiple ranks, and such as: the active state ranking score of client Grade Dui Ying not enlivened, secondary enliven grade and inactive grade;Alternatively, the active state grade of client respectively corresponds work Jump grade 1 enlivens grade 2, enlivens grade 3, enlivens class 4 ..., wherein it is more bigger more active to enliven grade.
In this way, can be according to the determining active client corresponding with current control window of state of activation of current control window Active state grade.Such as: if currently control window is in activation selected state, it is determined that current control window is corresponding current The active state grade of client is most to enliven grade, if currently control window is in un-activation selected state, it is determined that current The active state grade for controlling the corresponding active client of window is inactive grade.
It certainly, can also be according to the determining active client corresponding with current control window of size state of current control window Active state grade.Such as: if currently control window is in maximum rating, it is determined that current to control the corresponding current visitor of window The active state grade at family end is most to enliven grade, and the current window that controls is in minimum state, it is determined that current control window pair The active state grade for the active client answered is inactive grade.Alternatively, if currently control window is in maximum rating, really The active state grade of the corresponding active client of control window is to enliven class 5 before settled;If currently control window is in secondary Big state, it is determined that the current active state grade for controlling the corresponding active client of window is to enliven class 4;Successively successively decrease, If currently control window is in minimum state, it is determined that currently the active state grade of the corresponding active client of control window is Enliven grade 1.
Step 102: according to the active state grade of each client, updating the quantity n of connection client.
The corresponding relationship of active state grade Yu active state grade point is preset, in this way, when each visitor has been determined It, can be corresponding with the active state grade of each client according to the determination of the corresponding relationship of preservation after the active state grade at family end Active state grade point.Such as: the active state grade of preservation and the corresponding relationship of active state grade point are as shown in table 1:
Active state grade Active state grade point
Enliven grade 1 0
Enliven grade 2 1
Enliven grade 3 2
Enliven class 4 3
…… ……
Table 1
Alternatively, the active state grade saved and the corresponding relationship of active state grade point are as shown in table 1:
Active state grade Active state grade point
Most enliven grade 5
It is secondary to enliven grade 3
Inactive grade 1
Table 2
And the active state grade of each client is not exactly the same, corresponding active state grade point also incomplete phase Together, the active state grade point of each client is compared with given threshold respectively, connection visitor is updated according to comparison result The quantity n at family end.
When discovery has, client is more active, when active state grade point is greater than given threshold, can connect main control end The quantity n of client increases, and finds to have that client is inactive, can be by master when active state grade point is less than given threshold The quantity n for controlling end connection client is reduced.Specifically can include: if the active state grade point of active client is greater than given threshold When, quantity n is added 1;If the active state grade point of active client is less than given threshold, quantity n is subtracted 1.
With table 1, for threshold value=2, if the active state grade point of active client is 3,3 to be greater than threshold value 2, then by quantity N adds 1;The active state grade point of active client is 0,0 less than threshold value 2, then subtracts 1 for quantity n.According to this by each client Active state grade point is compared with given threshold respectively, obtains updated quantity n.
Step 103: according to updated quantity n, adjusting the client currently connected, and give each client adjusted Distribute corresponding resource.
When discovery has the active state grade point of client to be greater than given threshold, main control end can be connected to the number of client When measuring n to increase, and finding to have the active state grade point of client to be less than given threshold, main control end can be connected to the number of client It measures n to reduce, in that way it is possible to which some clients are not connect with main control end, alternatively, needing to increase newly has client to connect with main control end , thus, according to updated quantity n, the client currently connected is adjusted, and corresponding to each client distribution adjusted Resource.
In the embodiment of the present invention, main control end connects client according to the active state grade of each client to update Quantity n, and corresponding client is adjusted, corresponding resource is distributed to each client adjusted.Main control end is no longer and consolidates Determine the client connection of number, but when the client of connection is relatively enlivened, the client number of connection is increased, connection is worked as Client it is inactive when, then the client number of connection is reduced, in this way, main control end can be visitor according to different connection quantity Internet resources are distributed at family end, can utilize Internet resources to large extent, do not easily cause the idle of Internet resources, are reasonably assigned with Resource.
Certainly, in one embodiment of the invention, if there is client to be actively disconnected the connection with main control end, or there is newly-increased visitor Family end is actively connected to main control end, in this way, the quantity n of main control end connection client can have update, therefore, according to updated Quantity n, before adjusting the client that currently connects, further includes: the connection status of main control end is detected, if detecting in local area network has When newly-increased client is connect with main control end, quantity n is added 1, if detecting the first client in the client connecting with main control end When disconnecting the connection with main control end, quantity n is subtracted 1.
Embodiment two in the present embodiment, there is multiple client in local area network, wherein main control end currently with 10 clients Connection, such as: in the local area network constituted in class, the main control end of teacher's manipulation is connected with the client that 10 students manipulate. Referring to fig. 2, the process of resource allocation includes: in local area network in the present embodiment
Step 201: according to the state of activation of control window corresponding with each client, determining enlivening for each client State grade.
Control window corresponding with each client of connection is shown in main control end, as teacher or other manipulators When choosing one or more control windows, selected control window is just activated, and in activation selected state, generally emerges In the forefront at interface.And other remaining control windows are not activated then, are in un-activation selected state.
At this point, if currently control window is in activation selected state, it is determined that the currently corresponding existing customer of control window The active state grade at end is most to enliven grade;If currently control window is in un-activation selected state, it is determined that current control The active state grade of the corresponding active client of window is inactive grade.
Step 202: according to the active state grade of each client, updating the quantity n of connection client.
In above-mentioned steps, it has been determined that the active state grade of each client, selected control window are corresponding Client is in and most enlivens grade, and the corresponding client of other not selected control windows is in inactive grade.In this way, It can be according to the active state grade of preservation and the corresponding relationship of active state grade point, the determining active state with each client Then the corresponding active state grade point of grade carries out the active state grade point of each client with given threshold respectively Compare, the quantity n of connection client is updated according to comparison result.
The corresponding relationship of preservation is as shown in table 2, threshold value 2, in this way, when control window is selected, at corresponding client In most enlivening grade, corresponding active state grade point is 5, is greater than threshold value 2, at this point, quantity n is added 1, if n=10, more N after new is 11.When control window is not selected, corresponding client is in inactive grade, corresponding active state etc. Grade value is 1, is less than threshold value 2, at this point, subtracting 1 for quantity n, if n=10, updated n is 9.According to this by the work of each client Jump state grade value is compared with given threshold respectively, obtains updated quantity n.
Step 203: according to updated quantity n, adjusting the client currently connected, and give each client adjusted Distribute corresponding resource.
After quantity n updates, presumable client is not connect with main control end, alternatively, needing to increase newly has client and master control End is connected to, thus, according to updated quantity n, the client currently connected is adjusted, and to each client adjusted point With corresponding resource.
It can be seen that, if selected control window is more, corresponding more client is active, then main control end energy in this implementation The client of connection is more, and not selected control window is more, and corresponding more client is inactive, then main control end can It is not connect with these sluggish clients, thus, enable the client of connection to be assigned to more Internet resources, without So that Internet resources are idle, Internet resources are reasonably distributed, Internet usage efficiency is improved.
Embodiment three in the present embodiment, there is multiple client in local area network, wherein main control end currently with 20 clients Connection, such as: in the local area network constituted in class, the main control end of teacher's manipulation is connected with the client that 20 students manipulate. Referring to Fig. 3, the process of resource allocation includes: in local area network in the present embodiment
Step 301: determining to control window pair with current according to the size state of control window corresponding with each client The active state grade for the active client answered.
Control window corresponding with each client, the incomplete phase few greatly of each control window are shown in main control end Together.Such as: teacher or other manipulators widen a control window, so that the control window is greater than other all controls Window processed, alternatively, teacher or other manipulators minimize a control window, then the control window is all less than other Control window.
As it can be seen that the control window shown in main control end is of different sizes, some control windows are big, and some control windows It is small, in this way, determining active client corresponding with current control window enlivens shape according to the size state of current control window State grade.Specifically can include: if currently control window is in maximum rating, it is determined that current to control the corresponding existing customer of window The active state grade at end is most to enliven grade;If currently control window is in minimum state, it is determined that current control window pair The active state grade for the active client answered is inactive grade.Certainly, others control window can be determined as secondary active Grade.Alternatively, each control window is ranked up according to size, the corresponding client of maximum control window is enlivened into shape State grade is determined as enlivening grade M, the active state grade of the secondary big corresponding client of control window is determined as active etc. Grade M-1, and so on, it is determined as the active state grade of the corresponding client of the smallest control window to enliven grade 1.This In, M is the integer less than or equal to 20.
Step 302: according to the active state grade of each client, updating the quantity n of connection client.
Equally, it has been determined that the active state grade of each client, the corresponding client of maximum control window are in Most enliven grade, the corresponding client of secondary big control window, which is in, time enlivens grade, and so on, minimum control window is corresponding Client is in inactive grade, and corresponding active state grade point is also different.It equally, can be according to the active state etc. of preservation The corresponding relationship of grade and active state grade point determines active state grade corresponding with the active state grade of each client Value, then, the active state grade point of each client is compared with given threshold respectively, is updated and is connected according to comparison result Meet the quantity n of client.
The corresponding relationship of preservation is as shown in table 1, threshold value 5, in this way, the corresponding client of maximum control window is in most living Jump grade, and corresponding active state grade point is 18, is greater than threshold value 5, at this point, quantity n is added 1, if n=10, after updating N be 11.The corresponding client of control window that size is in centre is in centre and enlivens grade, corresponding active state etc. Grade value is 4, is less than threshold value 5, at this point, subtracting 1 for quantity n, if n=10, updated n is 9.According to this by the work of each client Jump state grade value is compared with given threshold respectively, obtains updated quantity n.
Step 303: according to updated quantity n, adjusting the client currently connected, and give each client adjusted Distribute corresponding resource.
After quantity n updates, presumable client is not connect with main control end, alternatively, needing to increase newly has client and master control End is connected to, thus, according to updated quantity n, the client currently connected is adjusted, and to each client adjusted point With corresponding resource.
As it can be seen that the larger corresponding client of control window is more active, and smaller control window in this implementation Corresponding client is more inactive, and corresponding more client is inactive, then main control end can not be with these sluggish visitors The connection of family end, thus, enable the client of connection to be assigned to more Internet resources, without making Internet resources idle, Internet resources are reasonably distributed, Internet usage efficiency is improved.
Example IV can construct resource allocation in a kind of local area network according to the process of resource allocation in above-mentioned local area network Device, local area network include a main control end and at least one client, wherein main control end is connect with n client, and n is big In the integer for being equal to 1, as shown in figure 4, the device includes: to comprise determining that unit 410, updating unit 420 and adjustment allocation unit 430, wherein
Determination unit 410 is connect with updating unit 420, for according to control window corresponding with each client of connection Status information, determine the active state grade of each client.
Updating unit 420 is connect, for according to each client respectively with determination unit 410 and adjustment allocation unit 430 Active state grade, update connection client quantity n.
Allocation unit 430 is adjusted, is connect with updating unit 420, for adjusting current connection according to updated quantity n Client, and distribute corresponding resource to each client adjusted.
In one embodiment of the invention, determination unit 410, if being specifically used for current control window is in activation selected state, The active state grade for then determining the corresponding active client of current control window is most to enliven grade, if currently at control window In un-activation selected state, it is determined that the current active state grade for controlling the corresponding active client of window is inactive etc. Grade;Or, if currently control window is in maximum rating, it is determined that the current active state for controlling the corresponding active client of window Grade is most to enliven grade, if currently control window is in minimum state, it is determined that current to control the corresponding existing customer of window The active state grade at end is inactive grade.
In one embodiment of the invention, updating unit 420 includes:
First module, for the corresponding relationship according to the active state grade of preservation and active state grade point, determine with The corresponding active state grade point of the active state grade of each client.
Second module, for the active state grade point of each client to be compared with given threshold respectively, according to Comparison result updates the quantity n of connection client.
In one embodiment of the invention, the second module, if specifically for active client active state grade point be greater than set When determining threshold value, quantity n is added 1, if the active state grade point of active client is less than given threshold, quantity n is subtracted 1.
In one embodiment of the invention, device should further include: detection updating unit, for detecting the connection status of main control end, If detecting in local area network when thering is newly-increased client to connect with main control end, quantity n is added 1, is connect if detecting with main control end When the first client disconnects the connection with main control end in client, quantity n is subtracted 1.
The device of resource allocation can be applied in the main control end of local area network in local area network in the embodiment of the present invention.
As it can be seen that in the embodiment of the present invention in local area network the device of resource allocation according to each client being connect with main control end Active state grade, adjustment main control end currently connects the quantity of client, and corresponding for each client distribution adjusted Resource, in this way, main control end is connect with the client of fixed number, but when the client of connection is relatively enlivened, The client number of connection is increased, when the client of connection is inactive, is then reduced the client number of connection, in this way, Main control end can be that client distributes Internet resources according to different connection quantity, can utilize Internet resources to large extent, be not easy The idle of Internet resources is caused, resource is reasonably assigned with.
It should be understood by those skilled in the art that, the embodiment of the present invention can provide as method, system or computer program Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the present invention Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the present invention, which can be used in one or more, The shape for the computer program product implemented in usable storage medium (including but not limited to magnetic disk storage and optical memory etc.) Formula.
The present invention be referring to according to the method for the embodiment of the present invention, the process of equipment (system) and computer program product Figure and/or block diagram describe.It should be understood that every one stream in flowchart and/or the block diagram can be realized by computer program instructions The combination of process and/or box in journey and/or box and flowchart and/or the block diagram.It can provide these computer programs Instruct the processor of general purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices to produce A raw machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for real The device for the function of being specified in present one or more flows of the flowchart and/or one or more blocks of the block diagram.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates, Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one The step of function of being specified in a box or multiple boxes.
Obviously, various changes and modifications can be made to the invention without departing from essence of the invention by those skilled in the art Mind and range.In this way, if these modifications and changes of the present invention belongs to the range of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to include these modifications and variations.

Claims (4)

1. a kind of method of resource allocation in local area network, which is characterized in that the local area network includes a main control end and at least one A client, wherein main control end is connect with n client, and n is the integer more than or equal to 1, this method comprises:
According to the status information of control window corresponding with each client of connection, the active state etc. of each client is determined Grade;
According to the active state grade of each client, the quantity n of connection client is updated;
According to the updated quantity n, the client currently connected is adjusted, and corresponding to each client distribution adjusted Resource;
The active state grade of each client of determination includes:
If the current control window is in activation selected state, it is determined that the corresponding active client of the current control window Active state grade be most enliven grade, if the current control window is in un-activation selected state, it is determined that described to work as The preceding active state grade for controlling the corresponding active client of window is inactive grade;Or,
If the current control window is in maximum rating, it is determined that the current work for controlling the corresponding active client of window Jump state grade is most to enliven grade, if the current control window is in minimum state, it is determined that the current control window The active state grade of corresponding active client is inactive grade;Or,
Each control window is ranked up according to size, by the active state grade of the corresponding client of maximum control window It is determined as enlivening grade M, is determined as the active state grade of the secondary big corresponding client of control window to enliven grade M-1, And so on, it is determined as the active state grade of the corresponding client of the smallest control window to enliven grade 1;
It is described update connection client quantity n include:
It is determining and each client to enliven shape according to the corresponding relationship of the active state grade of preservation and active state grade point The corresponding active state grade point of state grade;
The active state grade point of each client is compared with given threshold respectively, connection visitor is updated according to comparison result The quantity n at family end;
It is described according to comparison result update connection client quantity n include:
If the active state grade point of active client is greater than given threshold, the quantity n is added 1;
If the active state grade point of active client is less than given threshold, the quantity n is subtracted 1.
2. the method as described in claim 1, which is characterized in that it is described according to the updated quantity n, adjust current connection Client before, further includes:
Detect the connection status of the main control end;
If detecting when having newly-increased client to connect in the local area network with the main control end, the quantity n is added 1;
If detect that the first client disconnects the connection with the main control end in the client connecting with the main control end, by institute It states quantity n and subtracts 1.
3. the device of resource allocation in a kind of local area network, which is characterized in that the local area network includes a main control end and at least one A client, wherein main control end is connect with n client, and n is the integer more than or equal to 1, which includes: control window
Determination unit, for according to status information corresponding with each client of connection, determine each client to enliven shape State grade;
Updating unit updates the quantity n of connection client for the active state grade according to each client;
Allocation unit is adjusted, for adjusting the client currently connected according to the updated quantity n, and to adjusted Each client distributes corresponding resource;
The determination unit, if being specifically used for the current control window is in activation selected state, it is determined that the current control The active state grade of the corresponding active client of window processed is most to enliven grade, if the current control window is in un-activation Selected state, it is determined that the current active state grade for controlling the corresponding active client of window is inactive grade;Or, If the current control window is in maximum rating, it is determined that the corresponding active client of the current control window enlivens shape State grade is most to enliven grade, if the current control window is in minimum state, it is determined that the current control window is corresponding Active client active state grade be inactive grade;Or, each control window is ranked up according to size, it will most The active state grade of the big corresponding client of control window is determined as enlivening grade M, and secondary big control window is corresponding The active state grade of client is determined as enlivening grade M-1, and so on, by the corresponding client of the smallest control window Active state grade is determined as enlivening grade 1;
The updating unit includes:
First module, it is determining and each for the active state grade and the corresponding relationship of active state grade point according to preservation The corresponding active state grade point of the active state grade of client;
Second module, for the active state grade point of each client to be compared with given threshold respectively, according to comparing As a result the quantity n of connection client is updated;
Second module, if the active state grade point specifically for active client is greater than given threshold, by the number Amount n adds 1, if the active state grade point of active client is less than given threshold, subtracts 1 for the quantity n.
4. device as claimed in claim 3, which is characterized in that further include:
Updating unit is detected, for detecting the connection status of the main control end, if detecting has newly-increased client in the local area network When end is connect with the main control end, the quantity n is added 1, if detecting the first visitor in the client connecting with the main control end When family end disconnects the connection with the main control end, the quantity n is subtracted 1.
CN201510651077.XA 2015-10-09 2015-10-09 The method and apparatus of resource allocation in a kind of local area network Active CN105391758B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510651077.XA CN105391758B (en) 2015-10-09 2015-10-09 The method and apparatus of resource allocation in a kind of local area network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510651077.XA CN105391758B (en) 2015-10-09 2015-10-09 The method and apparatus of resource allocation in a kind of local area network

Publications (2)

Publication Number Publication Date
CN105391758A CN105391758A (en) 2016-03-09
CN105391758B true CN105391758B (en) 2019-07-02

Family

ID=55423588

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510651077.XA Active CN105391758B (en) 2015-10-09 2015-10-09 The method and apparatus of resource allocation in a kind of local area network

Country Status (1)

Country Link
CN (1) CN105391758B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106991013B (en) 2017-04-18 2018-09-07 腾讯科技(深圳)有限公司 A kind of method and device that resource request is handled
CN109688220A (en) * 2018-12-25 2019-04-26 武汉思普崚技术有限公司 A kind of shared access detection method and device
CN113783728A (en) * 2021-09-10 2021-12-10 咪咕数字传媒有限公司 Connection optimization method and device, computing equipment and computer storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752799A (en) * 2012-06-29 2012-10-24 中国联合网络通信集团有限公司 Routing method, device and system for delay tolerant network
CN104156466A (en) * 2014-08-22 2014-11-19 北京京东尚科信息技术有限公司 Grade-based method and device for allocating resources
CN104462500A (en) * 2014-12-19 2015-03-25 北京奇虎科技有限公司 Method for determining activeness of controls and control processing method and device
CN104766256A (en) * 2015-04-13 2015-07-08 天脉聚源(北京)教育科技有限公司 Method and device for determining activeness
CN104768034A (en) * 2015-04-13 2015-07-08 天脉聚源(北京)教育科技有限公司 Method and device for distributing resources

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8743802B2 (en) * 2010-11-08 2014-06-03 Blackberry Limited Allocating wireless resources

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752799A (en) * 2012-06-29 2012-10-24 中国联合网络通信集团有限公司 Routing method, device and system for delay tolerant network
CN104156466A (en) * 2014-08-22 2014-11-19 北京京东尚科信息技术有限公司 Grade-based method and device for allocating resources
CN104462500A (en) * 2014-12-19 2015-03-25 北京奇虎科技有限公司 Method for determining activeness of controls and control processing method and device
CN104766256A (en) * 2015-04-13 2015-07-08 天脉聚源(北京)教育科技有限公司 Method and device for determining activeness
CN104768034A (en) * 2015-04-13 2015-07-08 天脉聚源(北京)教育科技有限公司 Method and device for distributing resources

Also Published As

Publication number Publication date
CN105391758A (en) 2016-03-09

Similar Documents

Publication Publication Date Title
CN105391758B (en) The method and apparatus of resource allocation in a kind of local area network
CN106899857B (en) Server load adjusting method, device and server
US7738504B1 (en) Method of establishing and updating master node in computer network
CN103152398A (en) Method and system for file synchronization among multiple terminal files
CN111083232B (en) Server-side load balancing method based on improved consistent hash
CN104243405A (en) Request processing method, device and system
CN109525500A (en) A kind of information processing method and information processing unit of self-adjusting threshold value
CN104796496A (en) Cloud storage based load balancing calculating method
CN105743677B (en) A kind of resource allocation method and device
CN108696364B (en) Request message processing method, chat room message server and chat room system
CN105427815A (en) Method and apparatus for adjusting backlight brightness
CN109445827A (en) A kind of method and device of game renewal, electronic equipment, storage medium
CN108875035B (en) Data storage method of distributed file system and related equipment
CN106161280A (en) A kind of band width control method, device and electronic equipment
CN111064776A (en) Method and device for generating blocks in block chain and storage medium
CN110765092A (en) Distributed search system, index distribution method, and storage medium
US20170104683A1 (en) Dynamically segmenting traffic for a/b testing in a distributed computing environment
CN105139020B (en) A kind of user clustering method and device
CN107066405A (en) A kind of sharing method of memory device, interconnection subsystem and internal memory
CN102056201B (en) Method and device for processing abnormal condition in service process
CN106209926A (en) A kind of data-updating method and equipment
CN107491352B (en) Resource scheduling method and device
CN109728937A (en) A kind of method and device of the updating network state of voice mould group
CN111522788B (en) Method and device for processing access request and updating storage system
CN105704173A (en) Cluster system data distribution method and server

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder

Address after: Floor 8, Block E, Yonghe Building, 28 Andingmen East Street, Dongcheng District, Beijing 100007

Patentee after: Tianmai Juyuan Smart Technology (Beijing) Co.,Ltd.

Address before: Floor 8, Block E, Yonghe Building, 28 Andingmen East Street, Dongcheng District, Beijing 100007

Patentee before: TVMINING (BEIJING) EDUCATION SCIENCE & TECHNOLOGY Co.,Ltd.

CP01 Change in the name or title of a patent holder
TR01 Transfer of patent right

Effective date of registration: 20220928

Address after: Room 1602, 16th Floor, Building 18, Yard 6, Wenhuayuan West Road, Beijing Economic and Technological Development Zone, Daxing District, Beijing 100176

Patentee after: Beijing Lajin Zhongbo Technology Co.,Ltd.

Address before: Floor 8, Block E, Yonghe Building, 28 Andingmen East Street, Dongcheng District, Beijing 100007

Patentee before: Tianmai Juyuan Smart Technology (Beijing) Co.,Ltd.

TR01 Transfer of patent right