Embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, it is right below in conjunction with drawings and Examples
The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and
It is not used in the restriction present invention.
Fig. 1 is the applied environment figure that access method is applied in one embodiment.Reference picture 1, this applies access method application
In using access system.Include terminal 110 and server 120 using the system of access, wherein terminal 110 passes through network and server
120 connections, server 120 can be individual server or server cluster.Domain name solution is deployed with server 120
Container 122 and application container 124 are analysed, domain name mapping container 122 is applied corresponding to domain name for carrying out parsing using domain name
Application address, at least one application can be disposed in application container 124, the application container being deployed on server 120 can be one
It is individual or multiple.Terminal 110 can access domain name mapping container 122 by server 120, and terminal 110 may be used also by server 120
To access the application in application container 124.Terminal 110 can be fixed terminal or mobile terminal, and fixed terminal can be specifically
At least one of printer, scanner and monitor, mobile terminal can be specifically tablet personal computer, smart mobile phone, individual number
According at least one of assistant and digital camera.Domain name mapping container is the application container for being configured with domain name mapping function;Using
Container is the virtual application container for the service that can provide multiple applications, and application container can be Docker.
Fig. 2 is the internal structure schematic diagram of the server 120 in Fig. 1 application access systems in one embodiment.Such as Fig. 2 institutes
Show, the server 120 includes processor, memory and the network interface connected by system bus.Wherein, server 120
Processor is used to provide calculating and control ability, supports the operation of whole server 120, and memory is used for data storage, code
Instruction etc., network interface are used to carry out network service with terminal 110.The executable finger of at least one computer is stored with memory
Order, the computer executable instructions can be executed by processor, to realize that what is provided in the embodiment of the present application is applied to server 120
Application access method.Memory may include that magnetic disc, CD, read-only memory (Read-Only Memory, ROM) etc. are non-
Volatile storage medium, or random access memory (Random Access Memory, RAM) etc..For example, in one embodiment
In, memory includes non-volatile memory medium and built-in storage;Non-volatile memory medium is stored with operating system and calculating
Machine executable instruction, the computer executable instructions can be executed by processor to realize above-mentioned application access method;Memory storage
Device provides the running environment of cache for the operating system in non-volatile memory medium and computer executable instructions.
As shown in figure 3, in one embodiment, there is provided one kind applies access method, and the present embodiment is applied in this way
For example, specifically including herein below on the domain name mapping container 122 being deployed on server 120:
S302, the application access request that receiving terminal is sent.
Specifically, browser is installed, user inputs what is accessed in a browser by terminal 110 in terminal 110
Using corresponding application domain name.Terminal 110 obtains when detecting the application access instruction that user is triggered by input equipment
The application domain name of user's input, access request is applied according to application domain name generation.Using terminal 110 can be included in access request
At least one of authentication information, terminal iidentification and effective time.Terminal 110 will be sent to service using access request
Domain name mapping container 122 in device 120.The application that domain name mapping container 122 is sent by the receiving terminal 110 of server 120 is visited
Ask request.The entitled unique access identities applied in internet of application domain.
In one embodiment, application is installed, terminal 110 is detecting that user passes through input equipment point in terminal 110
When hitting in terminal 110 application installed, then when access instruction is applied in triggering, obtained and clicked on according to the application access instruction of triggering
The application domain name of application, access request is applied according to the application domain name generation got.
The application domain name in access request is applied in S304, extraction.
Specifically, domain name mapping container 122 is after receiving using access request, to being parsed using access request,
By parsing extraction using the application domain name in access request.
S306, application address corresponding with the application domain name extracted is inquired about in domain name mapping address pool.
Specifically, application address is the virtual network address of the application being deployed in application container, and each application is corresponding
At least one virtual network address.Domain name mapping address pool is provided with domain name mapping container 122, in domain name mapping address pool
Including applying domain name and application address.Domain name mapping container 122 will apply domain name and application address to be correspondingly stored in domain name mapping
In address pool.Container identification can also be included in domain name mapping address pool, container identification is the application being deployed on server 120
The unique mark of container, domain name mapping container 122 can also be by container identification application containers corresponding with being deployed in container identification
In the corresponding application domain name of application corresponding store.
For domain name mapping container 122 after extracting using domain name, that inquires about and extract in domain name mapping address pool should
The application address corresponding to domain name, the application address inquired are the corresponding application address of the application to be accessed.
S308, the application address inquired is sent to terminal, terminal is held according to the application address inquired from application
The application data of matching is obtained in device.
Specifically, the terminal iidentification in access request is applied in the extraction of domain name mapping container 122, will be inquired about according to terminal iidentification
The application address arrived is sent to using the terminal 110 corresponding to access request by server 120.Terminal 110 is receiving domain
After the application address that name parsing container 122 inquires, the application in application container is accessed according to the application address inquired, and obtain
Take corresponding application data.Terminal 110 shows the application data got in five application page.Wherein, domain name mapping container and
Application container to Docker containers by configuring what is obtained.Docker is a kind of transplantable application container increased income, developer
Can pack its exploitation application or rely on bag into Docker, application service is provided a user by Docker, one
Multiple applications can be arranged in Docker.
In the present embodiment, the application access request of terminal transmission is received, according to the application domain name in application access request
Domain name mapping is carried out in domain name mapping address pool, it is corresponding with the application domain name in application access request by domain name mapping inquiry
Application address, the application address inquired is sent can be from application container according to the application address received to terminal, terminal
The middle application data for obtaining matching, so as to realize the access to being applied in application container.The access applied in application container
During, terminal need to only obtain the application domain name of application to be accessed, and application domain is entitled changeless, pass through domain name mapping pond pair
Accurate application address is can obtain using the parsing of domain name, can be answered according to accurate application address in successful access application container
With so as to improve the access efficiency to being applied in application container.
As shown in figure 4, in one embodiment, it is specific before S302 also to include obtaining the step using domain name and application address
Suddenly, the step specifically includes herein below:
S402, obtain the application run in each application container corresponding application domain name and application address.
Specifically, multiple application containers are deployed on server 120, at least one answer is both provided with no application container
With.Domain name mapping container 122 obtains the application deployment record of each application container, and disposing extraction in record from application is deployed in this
Application in application container corresponding application domain name and application address.
In one embodiment, domain name mapping container 122 sends to each application container and monitors notice.Application container 124 exists
After receiving monitoring notice, the container identification of domain name mapping container in notice is monitored in extraction, will according to the container identification extracted
The corresponding application domain name of deployed application and application address are sent to domain name mapping container 122.
S404, by the corresponding storage of the application domain name and application address that get into domain name mapping pond.
Specifically, the corresponding application domain name of domain name mapping container 122 is run in each application container is got application
After application address, the container identification for the application container that the application of operation is matched is obtained, domain name mapping container 122 is by container mark
Know, be correspondingly stored in domain name mapping pond using domain name and application address.Domain name mapping container 122 can be by container identification, application
Domain name and application address are correspondingly stored in the domain name mapping table in domain name mapping pond.
In the present embodiment, domain name mapping container can obtain the corresponding application domain name of the application run in each application container and
Application address, the application domain name and application address that get are stored into domain name mapping pond, ensure answering in domain name mapping pond
It is accurate with domain name and application address so that domain name mapping pond can carry out accurate parsing to application domain name and obtain accurately application ground
Location.
As shown in figure 5, in one embodiment, specifically also include in renewal domain name mapping pond using ground using access method
The step of location, the step specifically include herein below:
S502, receive the application address Notification of Changes that application container is sent.
Specifically, application container 124 obtains the application after the corresponding application address change of the application for detecting operation
Using the application address after domain name and change, application address is generated using the application address after domain name and change according to acquisition
Notification of Changes, application container 124 send the application address Notification of Changes of generation to domain name mapping container 122.Domain name mapping is held
Device 122 receives the application address Notification of Changes that application container 124 is sent.
S504, extract application domain name and application address in application address Notification of Changes.
Specifically, domain name mapping container 122 parses to the application address Notification of Changes received, is extracted by parsing
Application domain name and application address in application address Notification of Changes.Wherein, the entitled application address that occurs of application domain extracted becomes
The corresponding application domain name of application more, the application address extracted are the application address after change.
S506, corresponding with the application domain name extracted in domain name mapping pond apply is updated according to the application address extracted
Address.
Specifically, domain name mapping container 122 inquires about apply corresponding with the application domain name extracted in domain name mapping pond
Address, the application address inquired is replaced with into the application address after change, so as to update the application address in domain name mapping pond.
In the present embodiment, after the corresponding application address change of application in application container, application container hair can be received
The application address Notification of Changes sent, the application domain name and application address in application address Notification of Changes are in domain name mapping pond
Application address be updated, ensure the accuracy of the application address in domain name mapping pond, improve domain name mapping pond to application
The parsing accuracy of domain name.
As shown in fig. 6, in one embodiment, the step being monitored to application container is specifically also included using access method
Suddenly, the step specifically includes herein below:
S602, monitor container operation event.
Specifically, domain name mapping container 122, which is monitored, whether there is container operation event, and container operation event passes through for user
Terminal 110 is operated triggered Action Events to disposing with the application container on server 120.Container operation event can be with
Be in application container the Action Events of application deployment or deleted in application container deployed application when
Between, container operation event, which can also be, is deleted application container, is enabled, being created and the operation of at least one of operation suspension
Corresponding Action Events.
S604, extract container operation type and container identification in the container operation event listened to.
Specifically, domain name mapping container 122 enters when listening to container operation event to the container operation event listened to
Row parsing, by parsing container operation type and container identification in extraction vessel Action Events.Container operation type can wrap
Include using create, using delete, container is created, container is enabled, container is deleted and at least one of container operation suspension operates
Type.Application container corresponding to the container identification extracted is the operation object of container operation event.
S606, address pool update mode is determined according to the container operation type extracted.
Specifically, the address pool update mode corresponding to container operation type, address are store in domain name mapping container 122
Pond update mode includes at least one of address is deleted, address is added and address is replaced.Domain name mapping container 122 is from container
After container operation type is extracted in Action Events, address pool update mode corresponding to the container operation type extracted is inquired about.
S608, application domain name and application ground in domain name mapping address pool are updated according to the address pool update mode of determination
Location.
Specifically, if address pool update mode is added for address, domain name mapping container 122 obtains application domain name to be added
And application address, application domain name to be added and application address are correspondingly stored in domain name mapping address pool.If address pool is more
New paragon is deleted for address, and domain name mapping container 122 obtains the corresponding application domain name and application address of the application deleted, in domain
The application domain name got and application address are inquired about in name parsing address pool and are deleted.If address pool update mode is replaced for address
Changing, domain name mapping container 122 obtains the corresponding application address using after domain name and change of application of application address change,
Application address corresponding to the application domain name got is inquired about in domain name mapping address pool, change is replaced with by the application address inquired
Application address after more.
In one embodiment, enabled if container operation event is container establishment or container, container operation type is corresponding
Address pool update mode be address addition, domain name mapping container obtain create or the container that enables on corresponding to the application that runs
Application domain name and application address, the application domain name and application address that get correspondingly are stored in domain name mapping address pool.
If the container operation time is container deletion or container operation suspension, address pool update mode corresponding to container operation type is ground
Location is deleted, then corresponding the application domain name and application address of the application on the container of acquisition deletion or operation suspension, from domain name solution
The application domain name and application address got is deleted in analysis address pool.
In one embodiment, it is further comprising the steps of after S608:Record the execution time of container operation event;According to
Execution time, the container operation type extracted and the container identification generation monitoring daily record extracted of record.
Specifically, domain name mapping container 122 records the execution time of container operation event, by the execution time of record, carries
Daily record is monitored in the container operation type got and the container identification generation extracted.
In one embodiment, the operating time of container operation Action Events corresponding to application container record, container is recorded
Action type and operation information, application container is by record by operating time, container operation type, operation information and container identification
Send to domain name mapping container 122.Domain name mapping container 122 is according to operating time, container operation type, operation information and container
Daily record is monitored corresponding to mark generation container identification.User with authority is inquired about by server 120 using terminal 110 and monitored
Daily record.
In the present embodiment, by monitoring container operation event, it may be determined that corresponding address pool update mode, according to determination
Address pool update mode renewal domain name mapping address pool, ensure that the application domain name that is stored in domain name mapping pond and application address are
It can be improved with the application of successful access corresponding application domain name and application address using the accurate of domain name and application address
Property, so as to improve the Access Success Rate to application.
As shown in fig. 7, in one embodiment, there is provided one kind applies access mechanism 700, and the device specifically includes:Access
Request receiving module 702, using domain name extraction module 704, application address enquiry module 706 and application address sending module 708.
Access request receiving module 702, the application access request sent for receiving terminal.
Using domain name extraction module 704, for extracting the application domain name applied in access request.
Application address enquiry module 706, the application domain name for inquiring about with extracting in domain name mapping address pool are corresponding
Application address.
Application address sending module 708, for the application address inquired to be sent to terminal, make terminal according to inquiring
Application address the application data of matching is obtained from application container.
In the present embodiment, the application access request of terminal transmission is received, according to the application domain name in application access request
Domain name mapping is carried out in domain name mapping address pool, it is corresponding with the application domain name in application access request by domain name mapping inquiry
Application address, the application address inquired is sent can be from application container according to the application address received to terminal, terminal
The middle application data for obtaining matching, so as to realize the access to being applied in application container.The access applied in application container
During, terminal need to only obtain the application domain name of application to be accessed, and application domain is entitled changeless, pass through domain name mapping pond pair
Accurate application address is can obtain using the parsing of domain name, can be answered according to accurate application address in successful access application container
With so as to improve the access efficiency to being applied in application container.
As shown in figure 8, in one embodiment, specifically also include using access mechanism 700:Application address acquisition module
710th, application address memory module 712, Notification of Changes receiving module 714, domain name addresses extraction module 716 and application address renewal
Module 718.
Application address acquisition module 710, for obtain the corresponding application domain name of the application that is run in each application container and
Application address.
Domain name solution is arrived in application address memory module 712, the corresponding storage of application domain name and application address for that will get
Analyse in pond.
Notification of Changes receiving module 714, for receiving the application address Notification of Changes of application container transmission.
Domain name addresses extraction module 716, for extracting application domain name and application address in application address Notification of Changes.
Application address update module 718, for being updated according to the application address extracted in domain name mapping pond with extracting
Application domain name corresponding to application address.
In the present embodiment, after the corresponding application address change of application in application container, application container hair can be received
The application address Notification of Changes sent, the application domain name and application address in application address Notification of Changes are in domain name mapping pond
Application address be updated, ensure the accuracy of the application address in domain name mapping pond, improve domain name mapping pond to application
The parsing accuracy of domain name.
As shown in figure 9, in one embodiment, specifically also include using access mechanism 700:Operational order monitors module
720th, operational order parsing module 722, update mode determining module 724 and address pool update module 726.
Operational order monitors module 720, for monitoring container operation event.
Operational order parsing module 722, for extracting container operation type and appearance in the container operation event listened to
Device identifies.
Update mode determining module 724, for determining address pool update mode according to the container operation type extracted.
Address pool update module 726, for being updated according to the address pool update mode of determination in domain name mapping address pool
Using domain name and application address.
In the present embodiment, by monitoring container operation event, it may be determined that corresponding address pool update mode, according to determination
Address pool update mode renewal domain name mapping address pool, ensure that the application domain name that is stored in domain name mapping pond and application address are
It can be improved with the application of successful access corresponding application domain name and application address using the accurate of domain name and application address
Property, so as to improve the Access Success Rate to application.
A kind of computer equipment, computer equipment include memory, processor and storage on a memory and can handled
The computer program run on device, following steps are realized during computing device computer program:The application that receiving terminal is sent is visited
Ask request;The application domain name in access request is applied in extraction;The application domain name inquired about and extracted in domain name mapping address pool
Corresponding application address;The application address inquired is sent to terminal, makes terminal according to the application address inquired from application
The application data of matching is obtained in container.
In one embodiment, before the application access request that receiving terminal is sent, in addition to:Obtain in each application container
The application of operation corresponding application domain name and application address;By the corresponding storage of the application domain name and application address that get to domain
In name parsing pond.
In one embodiment, following steps are also realized during computing device computer program:Application container is received to send
Application address Notification of Changes;Extract the application domain name and application address in application address Notification of Changes;Should according to what is extracted
With application address corresponding with the application domain name extracted in the renewal domain name mapping pond of address.
In one embodiment, following steps are also realized during computing device computer program:Monitor container operation event;
Extract the container operation type and container identification in the container operation event listened to;It is true according to the container operation type extracted
Determine address pool update mode;Application domain name and the application in domain name mapping address pool are updated according to the address pool update mode of determination
Address.
In one embodiment, extract container operation type in the container operation event listened to and container identification it
Afterwards, in addition to:Record the execution time of container operation event;According to the execution time of record, the container operation type extracted
Daily record is monitored with the container identification generation extracted.
In the present embodiment, the application access request of terminal transmission is received, according to the application domain name in application access request
Domain name mapping is carried out in domain name mapping address pool, it is corresponding with the application domain name in application access request by domain name mapping inquiry
Application address, the application address inquired is sent can be from application container according to the application address received to terminal, terminal
The middle application data for obtaining matching, so as to realize the access to being applied in application container.The access applied in application container
During, terminal need to only obtain the application domain name of application to be accessed, and application domain is entitled changeless, pass through domain name mapping pond pair
Accurate application address is can obtain using the parsing of domain name, can be answered according to accurate application address in successful access application container
With so as to improve the access efficiency to being applied in application container.
One or more is stored with the storage medium of computer executable instructions, and computer executable instructions are by one or more
During individual computing device so that one or more processors perform following steps:The application access request that receiving terminal is sent;Carry
Take using the application domain name in access request;Apply corresponding with the application domain name extracted is inquired about in domain name mapping address pool
Address;The application address inquired is sent to terminal, terminal is obtained according to the application address inquired from application container
The application data of matching.
In one embodiment, before the application access request that receiving terminal is sent, in addition to:Obtain in each application container
The application of operation corresponding application domain name and application address;By the corresponding storage of the application domain name and application address that get to domain
In name parsing pond.
In one embodiment, processor also performs following steps:It is logical to receive the application address change that application container is sent
Know;Extract the application domain name and application address in application address Notification of Changes;According to the application address extracted more new domain name solution
Application address corresponding to the application domain name that analysis Chi Zhongyu is extracted.
In one embodiment, processor also performs following steps:Monitor container operation event;Extract the container listened to
Container operation type and container identification in Action Events;Container operation type according to extracting determines address pool renewal side
Formula;Application domain name and application address in domain name mapping address pool is updated according to the address pool update mode of determination.
In one embodiment, extract container operation type in the container operation event listened to and container identification it
Afterwards, in addition to:Record the execution time of container operation event;According to the execution time of record, the container operation type extracted
Daily record is monitored with the container identification generation extracted.
In the present embodiment, the application access request of terminal transmission is received, according to the application domain name in application access request
Domain name mapping is carried out in domain name mapping address pool, it is corresponding with the application domain name in application access request by domain name mapping inquiry
Application address, the application address inquired is sent can be from application container according to the application address received to terminal, terminal
The middle application data for obtaining matching, so as to realize the access to being applied in application container.The access applied in application container
During, terminal need to only obtain the application domain name of application to be accessed, and application domain is entitled changeless, pass through domain name mapping pond pair
Accurate application address is can obtain using the parsing of domain name, can be answered according to accurate application address in successful access application container
With so as to improve the access efficiency to being applied in application container.
One of ordinary skill in the art will appreciate that realize all or part of flow in above-described embodiment method, being can be with
The hardware of correlation is instructed to complete by computer program, the computer program can be stored in a computer-readable storage and be situated between
In matter, the program is upon execution, it may include such as the flow of the embodiment of above-mentioned each method.Wherein, foregoing storage medium can be
The non-volatile memory mediums such as magnetic disc, CD, read-only memory (Read-Only Memory, ROM), or random storage note
Recall body (Random Access Memory, RAM) etc..
Each technical characteristic of embodiment described above can be combined arbitrarily, to make description succinct, not to above-mentioned reality
Apply all possible combination of each technical characteristic in example to be all described, as long as however, the combination of these technical characteristics is not deposited
In contradiction, the scope that this specification is recorded all is considered to be.
Embodiment described above only expresses the several embodiments of the present invention, and its description is more specific and detailed, but simultaneously
Can not therefore it be construed as limiting the scope of the patent.It should be pointed out that come for one of ordinary skill in the art
Say, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to the protection of the present invention
Scope.Therefore, the protection domain of patent of the present invention should be determined by the appended claims.