Resource allocation method, device, equipment, medium and product
By obtaining the device's resource configuration template and deployment area, the allocation of resources from the target resource pool is automatically solved, and the problems of low manual allocation efficiency and high cost are improved, and the equipment task processing effect is improved.
Patent Information
- Application Number
- CN202411078969.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-07
- Publication Date
- 2024-11-26
- Estimated Expiration
- 2044-08-07
AI Technical Summary
In the prior art, manually allocating resources to equipment leads to problems such as low allocation efficiency, high cost, and poor equipment processing tasks.
When receiving resource allocation requests, obtain the resource configuration template and deployment area associated with the device, and automatically allocate corresponding resources from the target resource pool based on the resource requirement information in the template, ensure that resources match the device, improve allocation efficiency and reduce costs .
It realizes automation of resource allocation, improves efficiency and task processing effects, ensures that resources meet the needs of equipment in specific scenarios, and reduces allocation costs.
Smart Images

Figure CN119030862A_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present invention relate to the field of big data technology, and in particular to a resource allocation method, device, equipment, medium and product. Background Art
[0002] In the current network equipment construction process, it is usually necessary to allocate corresponding resources to the equipment, such as IP addresses and other resources, so that the equipment can use the allocated resources to perform tasks.
[0003] Currently, the way to allocate resources to devices is usually to manually select available resources from a resource pool and allocate them to devices. This manual offline resource allocation method not only has the problems of low allocation efficiency and high cost, but also causes a mismatch between the device and the allocated resources, resulting in poor performance of the device in processing tasks. Summary of the invention
[0004] The embodiments of the present invention provide a resource allocation method, apparatus, device, medium and product to improve resource allocation efficiency, reduce costs and improve the effect of device processing tasks.
[0005] In a first aspect, an embodiment of the present invention provides a resource allocation method, the method comprising:
[0006] Upon receiving a resource allocation request, obtaining a resource configuration template of a production device associated with the resource allocation request and a deployment area of the production device; wherein the resource configuration template is adapted to an application scenario of the production device;
[0007] Determine a target resource pool corresponding to the production equipment according to the deployment area, and determine a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template;
[0008] The target resources are sent to the production equipment so that the production equipment performs corresponding tasks based on the target resources.
[0009] In a second aspect, an embodiment of the present invention further provides a resource allocation device, the device comprising:
[0010] A data acquisition module, configured to, upon receiving a resource allocation request, acquire a resource configuration template of a production device associated with the resource allocation request and a deployment area of the production device; wherein the resource configuration template is adapted to an application scenario of the production device;
[0011] A target resource determination module, configured to determine a target resource pool corresponding to the production equipment according to the deployment area, and determine a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template;
[0012] The resource delivery module is used to deliver the target resource to the production equipment so that the production equipment performs corresponding tasks based on the target resource.
[0013] In a third aspect, an embodiment of the present invention further provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, a resource allocation method as described in any one of the embodiments of the present invention is implemented.
[0014] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the resource allocation method as described in any one of the embodiments of the present invention.
[0015] In a fifth aspect, an embodiment of the present invention further provides a computer program product, including a computer program, which, when executed by a processor, implements the resource allocation method as described in any one of the embodiments of the present invention.
[0016] In an embodiment of the present invention, when a resource allocation request is received, a resource configuration template of the production equipment associated with the resource allocation request and a deployment area of the production equipment are obtained; the resource configuration template is adapted to the application scenario of the production equipment; a target resource pool corresponding to the production equipment is determined according to the deployment area, and a target resource corresponding to the production equipment is determined from the target resource pool according to the resource demand information in the resource configuration template; the target resource is sent to the production equipment so that the production equipment performs corresponding tasks based on the target resource, thereby solving the problem of manually allocating resources to equipment in the prior art, resulting in low allocation efficiency, high cost, and poor task processing effect, and realizing automatic allocation of target resources that meet the resource demand information to the production equipment from the target resource pool corresponding to the deployment area by considering the deployment area and application scenario of the production equipment and combining the resource demand information in the resource configuration template adapted to the application scenario, thereby improving resource allocation efficiency and reducing allocation cost, and at the same time, ensuring that the allocated target resources meet the task requirements of the production equipment in the application scenario within the deployment area, thereby improving task processing effect. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0018] Figure 1 is a flow chart of a resource allocation method provided according to an embodiment of the present invention;
[0019] Figure 2 is a flow chart of a resource allocation method provided by an embodiment of the present invention;
[0020] Figure 3 is a flow chart of a resource allocation method provided according to an embodiment of the present invention;
[0021] Figure 4 is a flow chart of a resource allocation method provided by an embodiment of the present invention;
[0022] Figure 5 is a flow chart of a resource allocation method provided according to an embodiment of the present invention;
[0023] Figure 6 is a schematic diagram of an interface for characterizing a configuration resource pool provided according to an embodiment of the present invention;
[0024] Figure 7 is a schematic diagram of an interface for characterizing a configuration resource pool provided according to an embodiment of the present invention;
[0025] Figure 8 is a structural schematic diagram of a resource allocation device provided according to an embodiment of the present invention;
[0026] Fig. 9 It is a structural diagram of an electronic device for implementing the resource allocation method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0027] The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the present invention, rather than to limit the present invention. It should also be noted that, for ease of description, only parts related to the present invention, rather than all structures, are shown in the accompanying drawings.
[0028] It should be noted that similar numbers and letters represent similar items in the following figures. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. At the same time, in the description of the present invention, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance. The acquisition, storage, use, and processing of data in the technical solution of this application comply with the relevant provisions of national laws and regulations.
[0029] It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, and they should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.
[0030] Before introducing the technical solution, the application scenario can be described first. The technical solution provided by the embodiment of the present invention can be applied to any scenario where resources need to be allocated. For example, during the network construction process, there may be a need to deploy networking equipment, and different equipment needs to be deployed in the network. At this time, corresponding resources need to be allocated to the deployed equipment to meet the network construction business needs. When allocating resources to the equipment, it can be implemented based on the technical solution provided in this embodiment.
[0031] Figure 1 1 is a flow chart of a resource allocation method provided according to an embodiment of the present invention. This embodiment is applicable to the case of allocating resources to a device. The method can be executed by a resource allocation device, which can be implemented in the form of hardware and / or software. Figure 1 As shown, the method includes:
[0032] S110. When a resource allocation request is received, a resource configuration template of a production device and a deployment area of the production device associated with the resource allocation request are obtained.
[0033] Among them, the resource allocation request may refer to a program or code for requesting resource allocation. The production equipment may refer to a device for which resources need to be allocated. The production equipment may be a single device or a group of devices, for example, the production equipment may be a switch and a router. The resource configuration template is used to describe the resource allocation rules for each / each group of production equipment in different application scenarios. For example, the resource configuration template stores the resource demand information, such as the resource demand information including the number of each IP (Internet Protocol) address or IP address segment required by the device, the number of AS (Autonomous System) number allocated, and other information. The resource configuration template is adapted to the application scenario of the production equipment. The application scenario refers to the business scenario to which the production equipment is actually applied. For example, the application scenario may be a usage scenario such as a home network, an office network, industrial control, a public place, or a functional scenario such as production, testing, and management. It should be noted that the business processed by the same production equipment in different application scenarios may be different, and accordingly, the resources required by it are also different. Therefore, the resource configuration templates corresponding to the same production equipment in different application scenarios are different. The deployment area can be used to represent the working location of the production equipment. It should also be noted that the network conditions of different deployment areas may be different. Accordingly, the resources required for the same production equipment to process services in different deployment areas may also be different.
[0034] In this embodiment, before building the network, the equipment that needs to be put into production in the network can be pre-set, and the resource configuration templates of these production equipment in different application scenarios can be configured, and the area where the production equipment should be deployed can be planned. In this way, when initiating a resource allocation request, the resource configuration template of the production equipment in the specified application scenario can be retrieved through an interface or program, and the deployment area of the production equipment can be determined, so that the resources that are compatible with it can be automatically allocated to the equipment through the resource configuration template and the deployment area. It should be noted that a resource allocation request can also be initiated when there is a demand for newly added production equipment. The newly added production equipment is the production equipment associated with the resource allocation request. At this time, the resource configuration template of the production equipment can be retrieved, and the deployment area of the production equipment can be determined, so that the automatic networking of the equipment can be realized after automatically allocating resources to the newly added production equipment, thereby improving the scalability of network construction.
[0035] For example, see Figure 2 , the resource configuration template corresponding to the production equipment can be read from the scenario solution library to obtain the resource demand information in the resource configuration template.
[0036] S120: Determine a target resource pool corresponding to the equipment to be put into production according to the deployment area, and determine a target resource corresponding to the equipment to be put into production from the target resource pool according to the resource demand information in the resource configuration template.
[0037] The target resource pool is adapted to the deployment area of the production equipment. The target resources can be resources such as IP addresses, AS numbers, interfaces, bandwidth, and routing, or hardware resources such as servers, storage devices, and network devices.
[0038] It should be noted that the network conditions, business processing and management conditions in different deployment areas may be different. In order to meet the business processing performance of the equipment in the deployment area and realize the refined management of resource information in the deployment area, the resource pool information of each deployment area is also different.
[0039] In this embodiment, the target resource pool corresponding to the production equipment can be determined from the resource pool information corresponding to the deployment area of the production equipment. Furthermore, according to the resource demand information in the resource configuration template, the target resource that meets its resource demand and is adapted to its deployment area can be determined for the production equipment, thereby ensuring the performance of the equipment's business processing in the deployment area and meeting the business processing requirements in the application scenario.
[0040] For example, see Figure 2 , read the resource requirement information in the resource configuration template, including IP resource requirements and AS resource requirements, and obtain the resource pool information according to the deployment area, obtain the IP resources corresponding to the IP resource requirements from the resource pool information, obtain the AS resources corresponding to the AS resource requirements, and obtain the target resources. When allocating IP and AS numbers to devices, different data AS numbers and IP addresses / address segments and other target resources are specified for the deployment area and scenario to which the device belongs. The rules for determining the target resources can be specified through the resource configuration template so that the target resources can meet the business processing requirements of the production equipment in this scenario.
[0041] In this embodiment, a target resource pool corresponding to the equipment to be put into production is determined according to the deployment area, and the target resources corresponding to the equipment to be put into production are determined from the target resource pool according to the resource demand information in the resource configuration template, including: determining a target network area corresponding to the deployment area, and obtaining at least two available resource pools corresponding to the target network area; determining at least one target resource pool from at least two available resource pools according to the resource demand information; determining the target resources adapted to the equipment to be put into production according to the resource status of the available resources in the target resource pool, the target query conditions of the target resource pool, and the resource demand information.
[0042] Among them, the target network area can refer to a logically isolated network area; it can also be a network area within a geographical range. For example, the target network area can be a network area such as a local area network, a metropolitan area network or a wide area network. The coverage of different network areas is different. For example, the coverage can be a building, a school, an enterprise or a city. The available resource pool is used to store some resources that can be used. These available resources can be IP addresses, AS numbers, interfaces, bandwidth, routes, etc., of course, but are not limited to these, and will not be elaborated here. The resource status can be used to characterize the usage status of the resource. For example, the resource status can be an allocated but not issued state, an allocated and issued state, or an unallocated state. The target query condition can refer to a condition used to query resource information in a resource pool, which can characterize the usage attributes of the resource information. For example, the target query conditions can be resource pool type (such as computing resource pool, storage resource pool, network resource pool, IP resource pool, AS resource pool, etc.), geographic location (such as data center, availability zone, school, enterprise, etc.), status information (such as online, offline, maintenance), resource specifications (such as CPU model, memory size, disk capacity, address segment, etc.) and business scenario type (such as production, management, etc.).
[0043] In this embodiment, the network area to which the deployment area belongs can be determined, and the network area can be used as the target network area, and then at least two available resource pools configured for the target network area can be obtained. Through the required resource information in the resource demand information, the resource pool corresponding to the required resource information is screened out from the available resource pool as the target resource pool. For example, the required resource information includes an IP address, and the available resource pool storing the IP address can be used as the target resource pool. Furthermore, the available resources that match the resource demand information and whose resource status is unallocated can be searched from the target query conditions of the target resource pool, and the queried available resources can be used as the target resources adapted to the production equipment. The advantage of this setting is that by allocating different resource pools to different network areas, while achieving refined management and allocation of resources, it can also ensure that the production equipment uses the allocated target resources to perform business processing in the deployment area, thereby improving the effectiveness of business processing.
[0044] For example, see Figure 2In the device resource allocation link, you can obtain resource pool information (that is, available resource pools) from the regional resource plan according to the network area (that is, the target network area) to which the production equipment belongs, and read the query conditions of various available resource pools. Then, perform specific allocation for each device based on the resource configuration template obtained from the scenario solution library. For example, according to the IP resource requirements, query the available IP addresses and address segments (as available resources) in the IP resource pool (that is, the target resource pool), obtain the subnet that meets the conditions, and obtain the target resources. At the same time, according to the AS resource requirements read, obtain the AS number (available resource) in the specified range from the available resource pool to the AS resource pool (that is, the target resource pool) of the network area for allocation, and obtain the available AS number (as the target resource).
[0045] In this embodiment, in order to ensure the validity of resource allocation, the resource status of the target resource may be checked before determining the target resource that is compatible with the production equipment, so that the target resource is sent to the production equipment if the check passes. Figure 2 After allocating various IP addresses to the production equipment, you can perform IP status verification. If the verification passes, the target resources will be sent to the production equipment. Otherwise, you need to re-determine the target resources for the production equipment.
[0046] In order to ensure the accuracy of resource allocation, after determining the target resource that is compatible with the production equipment, the resource status of the target resource can be updated to the allocated status to ensure the correctness of subsequent resource allocation according to the resource status and prevent allocation errors. Figure 2 If the status check passes, the resource status of the allocated IP address will be synchronized to the IP resource pool. After the AS number is allocated to the production equipment, the allocated AS number will be registered in the database and its resource status will be updated.
[0047] It should be noted that the resource configuration template of the production equipment and the resource pool information in the network area can be dynamically adjusted according to actual demand changes and network area changes, and the target resources of the production equipment can be dynamically updated according to the adjusted information to ensure that the production equipment can always operate in the optimal state.
[0048] S130: Send the target resources to the production equipment, so that the production equipment performs corresponding tasks based on the target resources.
[0049] In this embodiment, after the target resources are determined, the target resources can be allocated to the production equipment through a preset transmission method. In this way, when the production equipment performs tasks under the application scenario in the target network area, the target resources can be used for business processing. It should be noted that in order to ensure the accuracy of resource distribution, the operating status, configuration information, and network connection status of the production equipment can also be checked before the resources are distributed, so that the target resources can be distributed to the production equipment if the inspection passes, ensuring that the production equipment can receive the resources normally.
[0050] In this embodiment, the production equipment may also be a equipment group, and the corresponding target resources may be issued to each equipment in the equipment group. Specifically, when the number of production equipment in the resource configuration template includes multiple equipment, the target resources corresponding to each production equipment may be determined and issued.
[0051] In actual applications, if the resource configuration template contains multiple production equipment, the target resources corresponding to each production equipment can be issued to the corresponding production equipment respectively, so as to realize batch allocation of resources, improve resource allocation efficiency, and ensure the accuracy of resource issuance.
[0052] The technical solution of this embodiment is as follows: when a resource allocation request is received, a resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment are obtained; the resource configuration template is adapted to the application scenario of the production equipment; a target resource pool corresponding to the production equipment is determined according to the deployment area, and the target resources corresponding to the production equipment are determined from the target resource pool according to the resource demand information in the resource configuration template; the target resources are sent to the production equipment so that the production equipment performs corresponding tasks based on the target resources, which solves the problem of manual resource allocation to equipment in the prior art, resulting in low allocation efficiency, high cost, and poor task processing effect, and realizes automatic allocation of target resources that meet the resource demand information to the production equipment from the target resource pool corresponding to the deployment area by considering the deployment area and application scenario of the production equipment and combining the resource demand information in the resource configuration template adapted to the application scenario, thereby improving resource allocation efficiency and reducing allocation cost. At the same time, it can ensure that the allocated target resources meet the task requirements of the production equipment in the application scenario executed in the deployment area, thereby improving the task processing effect.
[0053] On the basis of the above embodiments, before obtaining the resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment, the resource configuration template corresponding to the production equipment may be pre-configured. Accordingly, the present invention proposes the following embodiments: Figure 3 FIG. 1 is a flow chart of a resource allocation method provided according to an embodiment of the present invention. Figure 3As shown, the resource allocation method includes the following steps:
[0054] S210: Determine at least one scenario to be selected and a configuration template to be filled in the scenario to be selected, so as to determine a resource configuration template corresponding to the production equipment based on the configuration template to be filled.
[0055] The scenario to be selected may refer to an application scenario that can be selected. The resource configuration template is a template obtained after filling in at least one of the fields to be filled in the configuration template. For example, the fields to be filled include but are not limited to a mask field, a resource requirement field, a device quantity field, and an address field. The resource configuration template includes but is not limited to the number of devices put into production, the address requirement and mask corresponding to each device put into production, and the application scenario of the equipment put into production.
[0056] Specifically, corresponding configuration templates to be filled can be configured for different scenarios to be selected. In this case, the configuration templates to be filled contain some fields to be filled. By filling the fields to be filled with content, the resource configuration templates corresponding to the production equipment in different scenarios can be obtained.
[0057] S220 . In response to a trigger operation of a user on a scenario to be selected in a resource configuration interface, determine an application scenario of the equipment to be put into production.
[0058] In this embodiment, a resource configuration interface can be developed in advance, and the resource configuration interface includes different scenarios to be selected. After the production equipment is determined, the scenario to be selected in the resource configuration interface can be triggered by clicking, sliding, touching, etc., and the triggered scenario to be selected is used as the application scenario of the production equipment.
[0059] S230: Display the configuration template to be filled corresponding to the application scenario.
[0060] Specifically, a configuration template to be filled corresponding to the application scenario is retrieved for display.
[0061] S240: In response to an edit operation on at least one field to be filled in the configuration template to be filled, determine a resource configuration template for the equipment to be put into production.
[0062] The filling content of at least one of the to-be-filled fields corresponds to the resource requirement information. The resource requirement information may be some rule information for allocating resources to the equipment, for example, the resource requirement information includes but is not limited to the number of equipment put into production, the address requirement corresponding to each equipment put into production, the mask and the address segment, etc.
[0063] In this embodiment, the user can determine the filling content of each field to be filled in the configuration template to be filled according to the business processing information such as the business function and business type of the production equipment in the application scenario, and / or the software version, operating system, hardware equipment, performance parameters, access network mode and bandwidth requirements required to run by the production equipment, and fill the filling content into the field to be filled. After the filling is completed, the resource configuration template corresponding to the production equipment in the application scenario can be obtained. Accordingly, the resource configuration template corresponding to the production equipment in different application scenarios can be obtained.
[0064] For example, see Figure 4 , specify specific resource requirement information for the production equipment in different scenarios. For example, for scenario A to which the device belongs, configure the number of each IP address or IP address segment allocated, the number of AS numbers allocated and other information required by the device in scenario A in the resource configuration template, store the resource configuration template in the scenario solution library, and obtain the resource configuration template of the device in scenario A from the scenario solution library to obtain the rules for resource allocation for the device.
[0065] The following are examples of resource configuration templates for two scenarios:
[0066] Scenario 1: AS:1 / group; mgt:1 / group; interconnect:4-30 / device; loopback:1 / group.
[0067] Scenario 2: AS:1 / group; mgt:1 / group; loopback:2 / group.
[0068] Among them, AS:1 / group means that each device group has one AS number, which describes the demand for AS numbers; mgt:1 / group means that each device group has one management IP address; loopback:1 / group means that each device group has one loopback IP address. interconnect:4-30 / device means that the interconnect address of each device is 4 addresses with 30-bit masks. Similarly, when describing the address in the resource configuration template, the address line can include the address demand and mask, that is, the number of addresses and the mask can be described together, and its format can be: address type: address demand and mask. It should be noted that when describing multiple address demands and masks, they can be separated by commas, for example: interconnect: hybrid-link interconnection class-network device interconnection address:4-30 / device,1-28 / device. Address types include but are not limited to mgt addresses, production interconnection addresses, management interconnection addresses, production loopback addresses, management loopback addresses, ILO addresses, physical machine production classes, and physical machine management addresses, etc.
[0069] The technical solution provided in this embodiment realizes the requirements of supporting new application scenarios of the system by configuring resource requirement templates for devices in different scenarios, supports the configuration of device resource requirement templates for any new application scenarios, and realizes the scalability of the system. At the same time, after configuring the resource configuration template, the resource configuration template can be directly called to know what resources need to be allocated to the production equipment and how to allocate them, etc., so as to realize the automatic allocation of resources for the equipment and ensure that the allocated resources meet the business processing requirements of the equipment.
[0070] On the basis of the above embodiments, before obtaining the resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment, resources can also be planned in advance according to different network areas to determine the target resources from the resource pool corresponding to the target network area to which the production equipment belongs. Accordingly, the present invention proposes the following embodiments: Figure 5 FIG. 1 is a flow chart of a resource allocation method provided according to an embodiment of the present invention. Figure 5 As shown, the resource allocation method includes the following steps:
[0071] S310: Divide the target area into at least one network area, and configure at least two resource pools for the at least one network area.
[0072] The resource pool is used to store available resources that are compatible with the network area. At least two resource pools store different types of resources, including but not limited to IP addresses and AS numbers. For example, see Figure 4 The AS resource pool stores AS numbers, and the IP resource pool stores IP addresses and address segments.
[0073] In this embodiment, the target area for construction can be divided into at least one network area according to the network construction requirements, and the network coverage of each network area is different. At least two resource pools corresponding to each network area can be configured according to the geographical characteristics of the coverage of each network area, data transmission rate, deployment cost, network security requirements, number of users and other information. For example, the resource pool includes at least an IP resource pool (for storing IP addresses), an AS resource pool (for storing AS numbers) and a port resource pool (for storing port numbers).
[0074] In this embodiment, after determining the resource pool corresponding to the network area, a query condition may be configured for each resource pool, so that after determining the resource pool corresponding to the resource allocation request, the target resource may be determined from the available resources according to the query condition of the resource pool.
[0075] The query conditions may include resource type, scene type corresponding to the resource, etc.
[0076] In this embodiment, query conditions can be configured for each resource pool based on various information corresponding to the resource pool, such as address type, name, geographic location, resource status, business requirements, etc., so as to query the target resources corresponding to the resource configuration template of the production equipment in the corresponding application scenario through the query conditions.
[0077] For example, Figure 4 As shown in the figure, you can configure the query conditions of the IP resource pool in the regional resource plan. The query conditions can be address types, such as MGT addresses (Multi-Gigabit Transceiver, addresses used for management interfaces), production interconnection addresses, management interconnection addresses, production loopback addresses, management loopback addresses, server production addresses, and ilo addresses (Intelligent Platform Management Interface addresses, network addresses used to access and manage servers). Different types of addresses also contain multiple query conditions. For example, the query conditions under the production interconnection address are address segments, masks, etc. See Figure 6 In the regional resource plan, you can also configure the query conditions of the AS resource pool. The query conditions can be different for different business scenarios. Figure 7 After specifying a fixed AS number for each scenario, query the AS number in the corresponding scenario through the query condition. The advantage of this setting is that by providing query conditions for each resource pool, the query conditions of the resource pool can be used later to query the target resources that are compatible with the production equipment from the resource pool, realizing the refined management and allocation of resources while ensuring the compatibility between the determined target resources and the production equipment.
[0078] S320. For each resource pool in the network area, determine available resources that are compatible with the resource pool according to the network area, the resource type of the resource pool, and the resources to be used, so as to determine the target resource from the available resources in the resource pool.
[0079] It should be noted that the method for determining the available resources of the resource pool in each network area is the same, and the method for determining the available resources of any resource pool in any network area may be used as an example for description.
[0080] In this embodiment, the resources to be used can be divided into different network areas, so that the available resources of each network area are different. Furthermore, according to the resource type of the resource pool, the resources adapted to the resource type can be determined from the divided resources as the available resources adapted to the resource pool, so as to determine the target resource from the available resources in the resource pool.
[0081] In this embodiment, based on the network area, the resource type of the resource pool and the resources to be used, the usable resources adapted to the resource pool are determined, including: determining the to-be-allocated resources corresponding to the network area from the resources to be used; based on the resource type of the resource pool, determining the first resource adapted to the resource type from the resources to be allocated; wherein the resource type includes at least one resource function type; for each resource function type, determining the usable resources in the resource pool adapted to the resource function type from the first resource.
[0082] Among them, the resource function type can be used to characterize the function implemented by the resource. For example, if the resource is an IP address, the resource function type of this type of resource can be the address of the management interface, the network address of the access server, the management address of the router, etc.; if the resource is an AS number, the resource function type of this type of resource can be a scene.
[0083] In this embodiment, the resources to be allocated that are compatible with the network area can be determined from the resources to be used based on the network attributes and area attributes of the network area, and the resources to be allocated corresponding to different network areas are different. Furthermore, resource information that is consistent with the resource type of the resource pool can be found from the resources to be allocated as the first resource. For example, if the resource type is an IP address, the IP address in the resources to be allocated is used as the first resource. From the first resources, the corresponding resources are allocated to each resource function type in the resource type as the available resources under the resource function type. Accordingly, the available resources that are compatible with each resource function type in the resource pool can be determined to obtain a resource pool, so as to determine the target resources of the equipment to be put into production from the available resources in the resource pool.
[0084] That is, a resource pool of the same resource type may include sub-resource pools of different resource function types. Figure 6 The IP resource pool includes sub-resource pools under different resource function types. The sub-resource pools can be MGT address pool, production interconnection address pool, management interconnection address pool, production loopback address pool, management loopback address pool, server production address pool and ilo address pool. Different sub-resource pools store available resources corresponding to different resource function types.
[0085] It should be noted that the technical solution provided in this embodiment can be implemented based on the resource allocation device of the resource pool, and the device can be used to realize the automatic allocation of network equipment resources during the network construction process. By managing the network resource pool (such as AS resource pool, IP resource pool, etc.), the query conditions of different types of resource pools are specified for a single network area, and the range of resource pools that can be used in each network area is determined, thereby ensuring that each network area allocates resources according to the pre-planned resource range. Among them, the management method includes resource entry, display, modification, deletion, retrieval, etc.
[0086] It should be noted that after determining the resource configuration template of the production equipment and the available resources that are compatible with the resource pool, a configuration file can be generated based on this information so that when deploying network equipment, resources can be automatically allocated to the production equipment based on the configuration file.
[0087] This embodiment presets resource ranges for different network areas so that the production equipment in each network area can use resources within the specified range, achieving refined resource division while ensuring the performance of the production equipment in the network area. At the same time, by configuring query conditions for resource pools for different network areas, and specifying resource pools under different resource function types for each network area, the resource function type corresponds to the business scenario, so as to plan resources according to network areas while ensuring the effectiveness of production equipment in processing tasks in different business scenarios.
[0088] Figure 8 Schematic diagram of a resource allocation device according to an embodiment of the present invention. Figure 8 As shown, the device includes: a data acquisition module 410, a target resource determination module 420 and a resource delivery module 430.
[0089] Among them, the data acquisition module 410 is used to obtain the resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment when receiving the resource allocation request; wherein the resource configuration template is adapted to the application scenario of the production equipment; the target resource determination module 420 is used to determine the target resource pool corresponding to the production equipment according to the deployment area, and determine the target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template; the resource delivery module 430 is used to deliver the target resource to the production equipment so that the production equipment performs corresponding tasks based on the target resource.
[0090] The technical solution of this embodiment is as follows: when a resource allocation request is received, a resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment are obtained; the resource configuration template is adapted to the application scenario of the production equipment; a target resource pool corresponding to the production equipment is determined according to the deployment area, and the target resources corresponding to the production equipment are determined from the target resource pool according to the resource demand information in the resource configuration template; the target resources are sent to the production equipment so that the production equipment performs corresponding tasks based on the target resources, which solves the problem of manual resource allocation to equipment in the prior art, resulting in low allocation efficiency, high cost, and poor task processing effect, and realizes automatic allocation of target resources that meet the resource demand information to the production equipment from the target resource pool corresponding to the deployment area by considering the deployment area and application scenario of the production equipment and combining the resource demand information in the resource configuration template adapted to the application scenario, thereby improving resource allocation efficiency and reducing allocation cost. At the same time, it can ensure that the allocated target resources meet the task requirements of the production equipment in the application scenario executed in the deployment area, thereby improving the task processing effect.
[0091] On the basis of the above-mentioned device, optionally, the device also includes: a resource pool configuration module, which is used to divide the target area into at least one network area, and configure at least two resource pools for the at least one network area; wherein the resource pool is used to store usable resources that are compatible with the network area, and the resource types stored in the at least two resource pools are different; a resource configuration module, which is used to determine, for each resource pool in the network area, the usable resources that are compatible with the resource pool according to the network area, the resource type of the resource pool and the resources to be used, so as to determine the target resource from the usable resources in the resource pool.
[0092] Based on the above-mentioned device, optionally, the resource configuration module includes: a to-be-allocated resource determination unit, used to determine the to-be-allocated resources corresponding to the network area from the to-be-used resources; a first resource determination unit, used to determine, based on the resource type of the resource pool, a first resource that is adapted to the resource type from the to-be-allocated resources; wherein the resource type includes at least one resource function type; and an available resource determination unit, used to determine, for each of the resource function types, an available resource in the resource pool that is adapted to the resource function type from the first resource.
[0093] Based on the above device, optionally, the device also includes: a query condition configuration unit, used to configure query conditions for each resource pool, so that after determining the resource pool corresponding to the resource allocation request, the target resource is determined from the available resources according to the query conditions of the resource pool.
[0094] On the basis of the above-mentioned device, optionally, the device also includes: a unit for determining a configuration template to be filled, used to determine at least one scenario to be selected and a configuration template to be filled for the scenario to be selected, so as to determine a resource configuration template corresponding to the production equipment based on the configuration template to be filled; wherein the resource configuration template is a template obtained after filling in content for at least one field to be filled in the configuration template to be filled.
[0095] On the basis of the above-mentioned device, optionally, the device also includes: an application scenario determination unit, used to determine the application scenario of the equipment to be put into production in response to the user's triggering operation on the scenario to be selected in the resource configuration interface; a configuration template to be filled determination unit, used to display the configuration template to be filled corresponding to the application scenario; a resource configuration template configuration unit, used to determine the resource configuration template of the equipment to be put into production in response to the editing operation of the at least one field to be filled in the configuration template to be filled; wherein the filling content of the at least one field to be filled corresponds to the resource demand information.
[0096] Based on the above-mentioned device, optionally, the target resource determination module 420 includes: an available resource pool determination unit, used to determine the target network area corresponding to the deployment area, and obtain at least two available resource pools corresponding to the target network area; a target resource pool determination unit, used to determine at least one target resource pool from the at least two available resource pools based on the resource demand information; a target resource determination unit, used to determine the target resources that are compatible with the production equipment based on the resource status of the available resources in the target resource pool, the target query conditions of the target resource pool and the resource demand information.
[0097] Based on the above device, optionally, the resource configuration template includes the number of the production equipment, the address requirement and mask corresponding to each production equipment, and the application scenario of the production equipment.
[0098] On the basis of the above device, optionally, a resource delivery module 430 is used to determine and deliver the target resources corresponding to each production device respectively when the number of production devices in the resource configuration template includes multiple devices.
[0099] Based on the above device, optionally, the device further includes: a state updating unit, configured to update the resource state of the target resource to an allocated state.
[0100] The resource allocation device provided in the embodiment of the present invention can execute the resource allocation method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0101] Fig. 9The present invention is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. Fig. 9 A block diagram of an exemplary electronic device 50 suitable for implementing exemplary embodiments of the present invention is shown. Fig. 9 The electronic device 50 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0102] like Fig. 9 As shown, the electronic device 50 is in the form of a general computing device. The components of the electronic device 50 may include but are not limited to: one or more processors or processing units 501, a system memory 502, and a bus 503 connecting different system components (including the system memory 502 and the processing unit 501).
[0103] Bus 503 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor or a local bus using any of a variety of bus structures. For example, these architectures include but are not limited to Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, Enhanced ISA bus, Video Electronics Standards Association (VESA) local bus and Peripheral Component Interconnect (PCI) bus.
[0104] The electronic device 50 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by the electronic device 50, including volatile and non-volatile media, removable and non-removable media.
[0105] System memory 502 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 504 and / or cache memory 505. Electronic device 50 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 506 may be used to read and write non-removable, non-volatile magnetic media ( Fig. 9 not shown, usually called a "hard drive"). Although Fig. 9 Not shown in the figure, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, a DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to the bus 503 via one or more data medium interfaces. The memory 502 may include at least one program product having a set (e.g., at least one) of program modules that are configured to perform the functions of the embodiments of the present invention.
[0106] A program / utility 508 having a set (at least one) of program modules 507 may be stored, for example, in the memory 502, such program modules 507 including but not limited to an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment. The program modules 507 generally perform the functions and / or methods of the embodiments described herein.
[0107] The electronic device 50 may also communicate with one or more external devices 509 (e.g., keyboards, pointing devices, displays 510, etc.), may communicate with one or more devices that enable a user to interact with the electronic device 50, and / or communicate with any device that enables the electronic device 50 to communicate with one or more other computing devices (e.g., a network card, a modem, etc.). Such communication may be performed through an input / output (I / O) interface 511. Furthermore, the electronic device 50 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 512. As shown, the network adapter 512 communicates with other modules of the electronic device 50 through the bus 503. It should be understood that although Fig. 9 Not shown, other hardware and / or software modules may be used in conjunction with the electronic device 50, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0108] The processing unit 501 executes various functional applications and data processing by running the programs stored in the system memory 502, such as implementing the resource allocation method provided in the embodiment of the present invention.
[0109] An embodiment of the present invention further provides a storage medium containing computer executable instructions, and when the computer executable instructions are executed by a computer processor, they are used to execute a resource allocation method, the method comprising:
[0110] Upon receiving a resource allocation request, obtaining a resource configuration template of a production device associated with the resource allocation request and a deployment area of the production device; wherein the resource configuration template is adapted to an application scenario of the production device;
[0111] Determine a target resource pool corresponding to the production equipment according to the deployment area, and determine a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template;
[0112] The target resources are sent to the production equipment so that the production equipment performs corresponding tasks based on the target resources.
[0113] The computer storage medium of the embodiment of the present invention can adopt any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.
[0114] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, which carry computer-readable program code. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0115] Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
[0116] Computer program code for performing the operation of embodiments of the present invention may be written in one or more programming languages or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0117] An embodiment of the present invention further provides a computer program product, including a computer program, which, when executed by a processor, implements the resource allocation method provided in any embodiment of the present application.
[0118] In the process of implementation, the computer program product can be written in one or more programming languages or a combination thereof to perform the computer program code of the present invention, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).
[0119] Note that the above are only preferred embodiments of the present invention and the technical principles used. Those skilled in the art will understand that the present invention is not limited to the specific embodiments herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in more detail through the above embodiments, the present invention is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present invention, and the scope of the present invention is determined by the scope of the appended claims.
Claims
1. A resource allocation method, characterized in that: include: Upon receiving a resource allocation request, obtaining a resource configuration template of a production device associated with the resource allocation request and a deployment area of the production device; wherein the resource configuration template is adapted to an application scenario of the production device; Determine a target resource pool corresponding to the production equipment according to the deployment area, and determine a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template; The target resources are sent to the production equipment so that the production equipment performs corresponding tasks based on the target resources.
2. The method according to claim 1, characterized in that: Before obtaining the resource configuration template of the production equipment associated with the resource allocation request and the deployment area of the production equipment, the method further includes: Divide the target area into at least one network area, and configure at least two resource pools for the at least one network area; wherein the resource pool is used to store usable resources adapted to the network area, and the resource types stored in the at least two resource pools are different; For each resource pool in the network area, available resources that are compatible with the resource pool are determined according to the network area, resource types of the resource pool, and resources to be used, so as to determine the target resource from the available resources in the resource pool.
3. The method according to claim 2, characterized in that The determining, based on the network area, the resource type of the resource pool, and the resources to be used, available resources adapted to the resource pool includes: Determining resources to be allocated corresponding to the network area from the resources to be used; According to the resource type of the resource pool, determine a first resource that is compatible with the resource type from the resources to be allocated; wherein the resource type includes at least one resource function type; For each resource function type, an available resource in the resource pool that is compatible with the resource function type is determined from the first resources.
4. The method according to claim 2, characterized in that: After determining the resource pool corresponding to the network area, the method further includes: A query condition is configured for each resource pool, so that after determining the resource pool corresponding to the resource allocation request, the target resource is determined from the available resources according to the query condition of the resource pool.
5. The method according to claim 1, characterized in that The method further comprises: Determine at least one scenario to be selected and a configuration template to be filled in the scenario to be selected, so as to determine a resource configuration template corresponding to the production equipment based on the configuration template to be filled; The resource configuration template is a template obtained after filling in content in at least one field to be filled in the configuration template to be filled.
6. The method according to claim 5, characterized in that The method further comprises: In response to a triggering operation of the to-be-selected scenario by a user in a resource configuration interface, determining an application scenario of the production equipment; Display the configuration template to be filled corresponding to the application scenario; In response to an edit operation on the at least one to-be-filled field in the to-be-filled configuration template, determining a resource configuration template for the production equipment; The filling content of the at least one field to be filled corresponds to the resource demand information.
7. The method according to claim 1, characterized in that The step of determining a target resource pool corresponding to the production equipment according to the deployment area, and determining a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template includes: Determine a target network area corresponding to the deployment area, and obtain at least two available resource pools corresponding to the target network area; Determining at least one target resource pool from the at least two available resource pools according to the resource demand information; According to the resource status of the available resources in the target resource pool, the target query condition of the target resource pool and the resource demand information, the target resources adapted to the production equipment are determined.
8. The method according to claim 1, characterized in that The resource configuration template includes the number of the production equipment, the address requirement and mask corresponding to each production equipment, and the application scenario of the production equipment.
9. The method according to claim 8, characterized in that When the number of the production equipment in the resource configuration template includes multiple ones, the target resources corresponding to each production equipment are determined and issued respectively.
10. The method according to claim 1, characterized in that After determining the target resource that is compatible with the production equipment, the method further includes: The resource state of the target resource is updated to an allocated state.
11. A resource allocation device, characterized in that: include: A data acquisition module, configured to, upon receiving a resource allocation request, acquire a resource configuration template of a production device associated with the resource allocation request and a deployment area of the production device; wherein the resource configuration template is adapted to an application scenario of the production device; A target resource determination module, configured to determine a target resource pool corresponding to the production equipment according to the deployment area, and determine a target resource corresponding to the production equipment from the target resource pool according to the resource demand information in the resource configuration template; The resource delivery module is used to deliver the target resource to the production equipment so that the production equipment performs corresponding tasks based on the target resource.
12. The device according to claim 11, characterized in that The device also includes: A resource pool configuration module, used to divide the target area into at least one network area, and configure at least two resource pools for the at least one network area; wherein the resource pool is used to store usable resources adapted to the network area, and the resource types stored in the at least two resource pools are different; The resource configuration module is used to determine, for each resource pool in the network area, available resources that are compatible with the resource pool according to the network area, the resource type of the resource pool and the resources to be used, so as to determine the target resource from the available resources in the resource pool.
13. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the resource allocation method according to any one of claims 1 to 10 when executing the computer program.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the resource allocation method as described in any one of claims 1 to 10 is implemented.
15. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the computer program implements the resource allocation method according to any one of claims 1 to 10.
Citation Information
Patent Citations
Heterogeneous resource arrangement method and device, equipment and storage medium
CN112306680A
Communication service arrangement method and device, computer equipment and storage medium
CN113361913A
Resource configuration method and device, equipment and medium
CN116708322A
Resource allocation method and device, storage medium and electronic equipment
CN117370008A
Systems and methods for automating resource deployment
US11818055B1
