Incremental website management method and system based on dynamic subdomain name
By dynamically assigning subdomains to each iteration, an independent website testing environment is formed, solving the problem of high costs in multi-iteration testing and achieving efficient resource utilization.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 上海秉玉软件技术服务有限公司
- Filing Date
- 2022-12-12
- Publication Date
- 2026-04-21
AI Technical Summary
In scenarios involving simultaneous testing across multiple iterations, traditional methods require providing an independent testing environment for each iteration, leading to high costs and wasted resources.
By dynamically assigning subdomains to each iteration, website redirection does not span iterations, forming a relatively independent testing environment. The main website in the base environment and the incremental website form a virtual iterative testing environment, and the incremental website is automatically recycled after the test ends.
It has created a relatively independent website testing environment, avoiding the waste of resources and time and reducing testing costs.
Smart Images

Figure CN115905765B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of software technology, and more specifically, to an incremental website management method and system based on dynamic subdomains. Background Technology
[0002] With the rise of the internet, websites are becoming increasingly feature-rich. The emergence of the front-end and back-end separation development model has brought greater flexibility to the development of front-end websites, and it has become the norm for multiple websites to work together to provide services. In addition, some companies are restructuring their websites, and in this process, both new and old websites will coexist.
[0003] At the same time, the application of agile development model inevitably leads to scenarios where multiple iterations are tested simultaneously in the process of embracing change and responding quickly. The independence of the test environment requires that the website does not jump across iterations when redirecting, which is also the most basic condition to ensure the reliability of test results.
[0004] When faced with multiple iterations being tested simultaneously, the traditional approach is to provide the testing team with as many independent testing environments as there are synchronous iterations. However, independent testing environments include not only all websites but also hundreds or thousands of microservices. Obviously, the cost of such independent environments is very high. Summary of the Invention
[0005] In view of the deficiencies in the existing technology, the purpose of this invention is to provide an incremental website management method and system based on dynamic subdomains.
[0006] An incremental website management method based on dynamic subdomains provided by the present invention includes:
[0007] Step S1: Deploy the entire website to the base environment, create a new iteration, and generate tags for the iteration;
[0008] Step S2: Configure the target website's main domain name in the source website's configuration file;
[0009] Step S3: Add the website to the iteration and deploy the iterated website to the incremental environment;
[0010] Step S4: Obtain the target website's main domain from the source website's configuration file, and append an iteration tag after the target website's main domain to create a link to the actual target website for redirection;
[0011] If no target domain with the same tag suffix is found, redirect to the target main website.
[0012] Preferably, in step S1:
[0013] The underlying environment is an independent cluster that runs the full website, with versions consistent with the production environment; a tag is defined for each iteration, and the tag represents the iteration.
[0014] Preferably, in step S3:
[0015] In each iteration, when the website starts, the website domain name is automatically appended with the iteration tag. The tag can be obtained in the website code, and the tag filtering logic is added to the target website redirection strategy.
[0016] At this point, there are more than two instances of the same website running in the basic environment during the iteration. One instance has a domain name without any suffix, which is called the main website, and its domain name is the main domain name. The domain names of the other instances consist of the main domain name and the iteration tag, which are called incremental websites, and their domain names are called incremental domain names.
[0017] Preferably, in the basic environment, in addition to the full main website, an incremental website with iteration markers is added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other.
[0018] Preferably, the incremental website is automatically recycled after the test ends and the iterative release is completed.
[0019] According to the incremental website management system based on dynamic subdomains provided by the present invention, executing the incremental website management method based on dynamic subdomains includes:
[0020] Iteration Management Module: Generates iteration tags;
[0021] Website management module: Preparing the basic environment, deploying incremental websites, and recycling;
[0022] Iterative selection module: Works on each website, finding the target website through iterative tags.
[0023] Preferably, the basic environment is an independent cluster that runs the full website with the same version as the production environment; a tag is defined for each iteration, and the tag represents the iteration.
[0024] Preferably, in each iteration, when the website starts, the website domain name is automatically appended with an iteration tag. The tag can be obtained in the website code, and the tag filtering logic is added to the target website redirection strategy.
[0025] At this point, there are more than two instances of the same website running in the basic environment during the iteration. One instance has a domain name without any suffix, which is called the main website, and its domain name is the main domain name. The domain names of the other instances consist of the main domain name and the iteration tag, which are called incremental websites, and their domain names are called incremental domain names.
[0026] Preferably, in the basic environment, in addition to the full main website, an incremental website with iteration markers is added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other.
[0027] Preferably, the incremental website is automatically recycled after the test ends and the iterative release is completed.
[0028] Compared with the prior art, the present invention has the following beneficial effects:
[0029] 1. This invention dynamically assigns subdomains to websites in different iterations, enabling website redirection to occur without crossing iterations, thereby creating a relatively independent website testing environment;
[0030] 2. This invention solves the problem of environmental resource waste;
[0031] 3. This invention avoids the waste of resources and time. Attached Figure Description
[0032] Other features, objects, and advantages of the present invention will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings:
[0033] Figure 1 A flowchart of an incremental website management method based on dynamic subdomains provided in this embodiment of the invention;
[0034] Figure 2 This is a schematic diagram of an incremental website management device based on dynamic subdomains, provided as an embodiment of the present invention. Detailed Implementation
[0035] The present invention will now be described in detail with reference to specific embodiments. These embodiments will help those skilled in the art to further understand the present invention, but do not limit the invention in any way. It should be noted that those skilled in the art can make several changes and improvements without departing from the concept of the present invention. These all fall within the protection scope of the present invention.
[0036] Example 1;
[0037] This invention defines a keyword for each iteration and configures a subdomain with the keyword as a suffix for each website. When redirecting between websites, the subdomain is first selected based on the keyword, and then the user is redirected to the corresponding website, thus forming an independent virtual multi-website testing environment. The actual cost is only the website resources of one environment. For each iteration, incremental websites are created as needed and recycled after use.
[0038] According to the present invention, an incremental website management method based on dynamic subdomains is provided, such as... Figures 1-2 As shown, it includes:
[0039] Step S1: Deploy the entire website to the base environment, create a new iteration, and generate tags for the iteration;
[0040] Specifically, in step S1:
[0041] The underlying environment is an independent cluster that runs the full website, with versions consistent with the production environment; a tag is defined for each iteration, and the tag represents the iteration.
[0042] Step S2: Configure the target website's main domain name in the source website's configuration file;
[0043] Step S3: Add the website to the iteration and deploy the iterated website to the incremental environment;
[0044] Specifically, in step S3:
[0045] In each iteration, when the website starts, the website domain name is automatically appended with the iteration tag. The tag can be obtained in the website code, and the tag filtering logic is added to the target website redirection strategy.
[0046] At this point, there are more than two instances of the same website running in the basic environment during the iteration. One instance has a domain name without any suffix, which is called the main website, and its domain name is the main domain name. The domain names of the other instances consist of the main domain name and the iteration tag, which are called incremental websites, and their domain names are called incremental domain names.
[0047] Step S4: Obtain the target website's main domain from the source website's configuration file, and append an iteration tag after the target website's main domain to create a link to the actual target website for redirection;
[0048] If no target domain with the same tag suffix is found, redirect to the target main website.
[0049] Specifically, in the basic environment, in addition to the full main website, incremental websites with iteration tags are added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other.
[0050] Specifically, the incremental website is automatically recycled after the testing ends and the iteration is released.
[0051] Example 2:
[0052] Example 2 is a preferred embodiment of Example 1, and is used to illustrate the present invention in more detail.
[0053] The present invention also provides an incremental website management system based on dynamic subdomains. The incremental website management system based on dynamic subdomains can be implemented by executing the process steps of the incremental website management method based on dynamic subdomains. That is, those skilled in the art can understand the incremental website management method based on dynamic subdomains as a preferred embodiment of the incremental website management system based on dynamic subdomains.
[0054] According to the incremental website management system based on dynamic subdomains provided by the present invention, executing the incremental website management method based on dynamic subdomains includes:
[0055] Iteration Management Module: Generates iteration tags;
[0056] Website management module: Preparing the basic environment, deploying incremental websites, and recycling;
[0057] Iterative selection module: Works on each website, finding the target website through iterative tags.
[0058] Specifically, the basic environment is an independent cluster that runs the full website, with versions consistent with the production environment; a tag is defined for each iteration, and the tag represents the iteration.
[0059] Specifically, in each iteration, when the website starts, the website domain name is automatically appended with an iteration tag. The tag can be obtained in the website's code, and the tag filtering logic is added to the target website's redirection strategy.
[0060] At this point, there are more than two instances of the same website running in the basic environment during the iteration. One instance has a domain name without any suffix, which is called the main website, and its domain name is the main domain name. The domain names of the other instances consist of the main domain name and the iteration tag, which are called incremental websites, and their domain names are called incremental domain names.
[0061] Specifically, in the basic environment, in addition to the full main website, incremental websites with iteration tags are added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other.
[0062] Specifically, the incremental website is automatically recycled after the testing ends and the iteration is released.
[0063] Example 3:
[0064] Example 3 is a preferred example of Example 1, and is used to illustrate the present invention in more detail.
[0065] To address the shortcomings of existing technologies, this invention provides an incremental website management method and apparatus based on dynamic subdomains. By dynamically assigning subdomains to websites in different iterations, website jumps can be made without crossing iterations, thereby forming a relatively independent website testing environment while avoiding the waste of resources and time.
[0066] To achieve the above objectives, the technical solution adopted by the present invention includes:
[0067] On the one hand, the technical solution of this invention provides an incremental website management method based on dynamic subdomains, the characteristics of which include:
[0068] Step 1: Prepare a separate cluster, which we call the base environment. This cluster runs the full set of websites (called the main website), and the versions are consistent with the production environment.
[0069] Step 2: Define a keyword (or tag) for each iteration. In this method, the keyword represents the iteration.
[0070] Step 3: To enable website redirection, configure the target website's main domain name in the source website's configuration file;
[0071] Step 3: In each iteration, when the website starts, its domain name is automatically appended with the tag for this iteration. This tag can be obtained in the website's code, and the tag filtering logic can be added to the target website's redirection strategy. At this time, there are more than two instances of the same website running in the basic environment. One instance's domain name does not have any suffix (we call it the main website, and its domain name is the main domain name), and the domain names of the other instances consist of the main domain name and the iteration tag (we call them incremental websites, and their domain names are called incremental domain names).
[0072] Step 4: When the source website redirects to the target website, first retrieve the target website's main domain name from the source website's configuration file, then append the iteration tag to it and use it as the actual target website link for redirection; if no target domain name with the same tag suffix is found, then redirect to the target main website.
[0073] Step 5: Through the above steps, in addition to the full main website, an incremental website with iteration tags has been added to the basic environment. Each incremental website and the main website in each iteration form a virtual iterative testing environment for the full website, and the iterations do not interfere with each other.
[0074] Step 6: Once testing is complete and the iteration is released, the incremental website will be automatically recycled to reduce costs.
[0075] On the other hand, the technical solution of the present invention provides an incremental website management device based on dynamic subdomains, including an iteration management module, a website management module, and an iteration selection module;
[0076] Iteration Management Module: Generates iteration tags;
[0077] Website management module: used for preparing the basic environment, deploying incremental websites, and recycling.
[0078] Iterative selection module: Works on each website, finding suitable target websites through tags.
[0079] Example 4:
[0080] Example 4 is a preferred example of Example 1, which is used to illustrate the present invention in more detail.
[0081] The technical solutions of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.
[0082] This invention provides an incremental website management method based on dynamic subdomains, comprising the following steps:
[0083] This invention provides an incremental website management method and apparatus based on dynamic subdomains. Figure 1 A flowchart of an incremental website management method based on dynamic subdomains is provided for an embodiment of the present invention, as shown below. Figure 1 As shown, the method provided in this embodiment may include the following steps:
[0084] Step S1: Prepare a basic environment and install all main websites.
[0085] The iterative management module prepares a basic environment for both the development and testing environments, and deploys all websites to the basic environment. In this embodiment, only one basic environment is used.
[0086] In this embodiment, the domain name of the main website A is com.sample.portal-a, the domain name of the main website B is com.sample.portal-b, and so on.
[0087] In this embodiment, website A is the entry website, which will redirect to website B, and website B will redirect to website C. Therefore, the configuration of website B needs to be defined in the configuration file of website A, such as: portal-b:com.sample.portal-b; similarly, the configuration of website C needs to be defined in the configuration file of website B: portal-c:com.sample.portal-c.
[0088] In this embodiment, website redirection is achieved through button clicks; that is, there is a button on the page of website A: redirect to website B; and there is a button on the page of website B: redirect to website C.
[0089] Step S2: Create a new iteration and generate a key for it (label = 11).
[0090] By using the iteration management module, a new iteration is created. The iteration management module will automatically generate a tag (keyword) for the iteration. In this embodiment, the tag is assumed to be 11.
[0091] Step S3: Add website B and website C to iteration 11, and denote them as website B11 and website C11 respectively.
[0092] Step S4: Deploy website B11 and website C11 to the incremental environment.
[0093] When deploying an iterative website to the development and testing environments, the website management module will automatically deploy the website to the incremental environment. That is, when generating a domain name for the website, it will automatically add an iteration tag suffix to it.
[0094] After deployment, the domain name of incremental website B11 is: com.sample.portal-b-11, and the domain name of incremental website C11 is: com.sample.portal-c-11. At this time, the pages of website B11 and website C11 can be accessed through the incremental domain names.
[0095] Step S5: Open the page of the portal website A, select the module through iteration, and select iteration 11.
[0096] The iteration selection module is the basic module and works on each website. Once an iteration is selected, a flag for the selected iteration will be automatically appended to the target website address for each jump.
[0097] Step S6: On the page of website A, click the button to jump to website B.
[0098] Since iteration 11 was selected above, the website opened here is the incremental website B11, not B.
[0099] Step S7: On the page of website B11, click the button: jump to website C.
[0100] Since iteration 11 was selected above, the website opened here is the incremental website C11, not C.
[0101] Step S8: Open the page of the portal website A, select the module through iteration, and clear the selected iteration.
[0102] At this point, without selecting any iterations, the website should redirect to the main website.
[0103] Step S9: On the page of website A, click the button to jump to website B.
[0104] Since the iteration selection was cleared above, the website opened here is the main website B, not B11.
[0105] Step S10: On the page of website B, click the button: jump to website C.
[0106] Since the iteration selection was cleared above, the website opened here is the main website C, not C11.
[0107] Once the iterative website is successfully published, the incremental websites B11 and C11 are automatically deleted.
[0108] This invention also provides an incremental website management system, which can be implemented by executing the process steps of the incremental website management method. That is, those skilled in the art can understand the incremental website management method as a preferred embodiment of the incremental website management system. (Refer to...) Figure 2 As shown, the system specifically includes: an iteration management module, a website management module, and an iteration selection module.
[0109] Iteration Management Module: Generates iteration tags;
[0110] Website management module: used for preparing the basic environment, deploying incremental websites, and recycling.
[0111] Iterative selection module: Works on each website, finding suitable target websites through tags.
[0112] Those skilled in the art will understand that, in addition to implementing the system, apparatus, and their modules provided by this invention in purely computer-readable program code, the same program can be implemented in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers by logically programming the method steps. Therefore, the system, apparatus, and their modules provided by this invention can be considered a hardware component, and the modules included therein for implementing various programs can also be considered structures within the hardware component; alternatively, modules for implementing various functions can be considered both software programs implementing the method and structures within the hardware component.
[0113] Specific embodiments of the present invention have been described above. It should be understood that the present invention is not limited to the specific embodiments described above, and those skilled in the art can make various changes or modifications within the scope of the claims, which do not affect the essence of the present invention. Unless otherwise specified, the embodiments and features described in this application can be arbitrarily combined with each other.
Claims
1. An incremental website management method based on dynamic subdomains, characterized in that, include: Step S1: Deploy the entire website to the base environment, create a new iteration, and generate tags for the iteration; Step S2: Configure the target website's main domain name in the source website's configuration file; Step S3: Add the website to the iteration and deploy the iterated website to the incremental environment; Step S4: Obtain the target website's main domain from the source website's configuration file, and append an iteration tag after the target website's main domain to create a link to the actual target website for redirection; If no target domain with the same tag suffix is found, redirect to the target main website; In step S1: The underlying environment is an independent cluster that runs the full website, with versions consistent with the production environment; a tag is defined for each iteration, and the tag represents the iteration; In step S3: In each iteration, when the website starts, the website domain name is automatically appended with the iteration tag. The tag can be obtained in the website code, and the tag filtering logic is added to the target website redirection strategy. At this point, the website with the same name in the iteration is running in more than two instances in the basic environment. One instance's domain name does not have any suffix and is called the main website, and its domain name is the main domain name; the domain names of the other instances consist of the main domain name and the iteration tag, and are called incremental websites, and their domain names are called incremental domain names. In the basic environment, in addition to the full main website, an incremental website with iteration markers was added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other. Once testing is complete and the iteration is released, the incremental website will be automatically recycled.
2. An incremental website management system based on dynamic subdomains, characterized in that, The incremental website management method based on dynamic subdomains as described in claim 1 includes: Iteration Management Module: Generates iteration tags; Website management module: Preparing the basic environment, deploying incremental websites, and recycling; Iterative selection module: Works on each website, finding the target website through iterative tags; The underlying environment is an independent cluster that runs the full website, with versions consistent with the production environment; a tag is defined for each iteration, and the tag represents the iteration; In each iteration, when the website starts, the website domain name is automatically appended with the iteration tag. The tag can be obtained in the website code, and the tag filtering logic is added to the target website redirection strategy. At this point, the website with the same name in the iteration is running in more than two instances in the basic environment. One instance's domain name does not have any suffix and is called the main website, and its domain name is the main domain name; the domain names of the other instances consist of the main domain name and the iteration tag, and are called incremental websites, and their domain names are called incremental domain names. In the basic environment, in addition to the full main website, an incremental website with iteration markers was added; each incremental website and the main website in each iteration form a virtual iterative test environment for the full website, and the iterations do not interfere with each other. Once testing is complete and the iteration is released, the incremental website will be automatically recycled.
Citation Information
Patent Citations
Method and system for realizing cross-domain jumping, browser and domain name servers
CN103546432A
Lightweight webpage performance testing architecture and method
CN104734918A