CN108549542A - A kind of file dispositions method, device and equipment - Google Patents

A kind of file dispositions method, device and equipment Download PDF

Info

Publication number
CN108549542A
CN108549542A CN201810322553.7A CN201810322553A CN108549542A CN 108549542 A CN108549542 A CN 108549542A CN 201810322553 A CN201810322553 A CN 201810322553A CN 108549542 A CN108549542 A CN 108549542A
Authority
CN
China
Prior art keywords
file
service
deployment
module
describes
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201810322553.7A
Other languages
Chinese (zh)
Inventor
吴波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Taikang Insurance Group Co Ltd
Taikang Pension Insurance Co Ltd
Original Assignee
Taikang Insurance Group Co Ltd
Taikang Pension Insurance Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Taikang Insurance Group Co Ltd, Taikang Pension Insurance Co Ltd filed Critical Taikang Insurance Group Co Ltd
Priority to CN201810322553.7A priority Critical patent/CN108549542A/en
Publication of CN108549542A publication Critical patent/CN108549542A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Abstract

The present invention discloses a kind of file dispositions method, device, system and equipment, file Disposition Instructions are received by operating in the proxy service module on destination server, file Disposition Instructions carry service identifiers and file store path, proxy service module describes center acquisition service definition corresponding with the service identifiers from service definition and describes file, deployment file is waited for from the acquisition of file storage service center is corresponding with this document store path, file is finally described according to service definition, will wait for that deployment file is deployed on destination server.The application runs on independent proxy service module on destination server, is realized by proxy service module and is disposed to the file of this kind of destination server.Since the application is that the permission that proxy service module is opened is limited, the permission of relevant document deployment is pertained only to, so can map out the work in the file of the server of the difficult support containerization technique of the higher realization of safety using the application.

Description

A kind of file dispositions method, device and equipment
Technical field
This application involves data processing fields, and in particular to a kind of file dispositions method, device and equipment.
Background technology
File deployment refer to will generate wait for that deployment file is deployed on destination server, with realization wait for deployment file in mesh Mark the normal operation on server.It waits for that deployment file can be the new demand servicing software of exploitation, can also be the update of service software File etc..
Currently, being deployed under containerization technique is supported for file is easily achieved, still, due to the existing base of destination server The presence of plinth framework, some possible destination servers are difficult support containerization technique, so, for not supporting containerization to be transformed, How the destination server of upgrading carries out the deployment of file, is current urgent problem to be solved.
Invention content
Can be not support containerization transformation, upgrading the present invention provides a kind of file dispositions method, device and equipment Destination server realizes the deployment of file.
In a first aspect, the present invention provides a kind of file dispositions method, the method is applied to operate on destination server Proxy service module, the method includes:
The proxy service module receives the file Disposition Instructions for carrying service identifiers and file store path;
The proxy service module describes center according to the service identifiers, from service definition and obtains with service mark The service definition of knowledge describes file;The service definition describes center and is retouched for the centrally stored service definition with service identifiers State file;
The proxy service module obtains from file storage service center according to the file store path and waits for deployment text Part;Each deployment file is waited for for managing concentratedly in the file storage service center;
The proxy service module describes file according to the service definition, waits for that deployment file is deployed in the mesh by described It marks on server.
Optionally, the proxy service module describes file according to the service definition, waits for that deployment file is disposed by described In on the destination server, including:
The proxy service module obtains the service definition and describes service profile information in file;
The proxy service module waits for that deployment file is deployed in corresponding centre according to the service profile information, by described In part service, wherein the middleware services run on the destination server.
Optionally, the method further includes:
The proxy service module controls restarting and/or suspending for each middleware services on the destination server.
Optionally, the proxy service module reception carries service identifiers and the file deployment of file store path refers to It enables, including:
What the proxy service module reception assignment instructions queue platform was sent carries service identifiers and file storage road The file Disposition Instructions of diameter;Wherein, the file Disposition Instructions are by the assignment instructions queue platform from described for storing It is obtained in the assignment instructions queue of file Disposition Instructions.
Optionally, what the proxy service module reception assignment instructions queue platform was sent carries service identifiers and file Before the file Disposition Instructions of store path, further include:
The proxy service module describes center from the service definition and obtains itself corresponding assignment instructions queuing message;
The proxy service module creates institute according to the assignment instructions queuing message, in the assignment instructions queue platform State the corresponding assignment instructions queue of service identifiers;It includes assignment instructions queuing message that the service definition, which describes file,.
Optionally, the proxy service module describes file according to the service definition, waits for that deployment file is disposed by described After on the destination server, further include:
The deployment result for waiting for deployment file is uploaded to the service definition and describes center by the proxy service module, File is described so that corresponding service definition is added in the deployment result for waiting for deployment file.
Second aspect, the present invention provides a kind of file dispositions method, the method is applied to deployment services device, the side Method includes:
The deployment services device waits for that deployment file is uploaded to file storage service center by generation, and waits for portion described in acquisition Affix one's name to the file store path of file;Described to wait for that deployment file has service identifiers, the file storage service center is for concentrating It manages and each waits for deployment file;
The deployment services device describes to wait for corresponding of the service identifiers of deployment file described in the inquiry of center in service definition Business instruction queue information;The service definition describes pair that center describes file for centrally stored service identifiers and service definition It should be related to, it includes assignment instructions queuing message that the service definition, which describes file,;
The deployment services device will wait for the service identifiers of deployment file according to the assignment instructions queuing message described in carrying It is sent to corresponding assignment instructions queue with the file Disposition Instructions of file store path, so as to the agency service of destination server Module obtains the file Disposition Instructions from the assignment instructions queue, and is waited for described according to file Disposition Instructions completion The deployment of deployment file.
Optionally, the deployment services device by generation wait for that deployment file is uploaded to file storage service center before, also Including:
The pre-stored program code of deployment services device automatic regular polling, and become detecting that any program code exists When dynamic, deployment file is waited for according to the program code generation that there is variation is corresponding.
The third aspect, the present invention provides a kind of files to dispose device, and described device includes:
Receiving module, for receiving the file Disposition Instructions for carrying service identifiers and file store path;
First acquisition module, for according to the service identifiers, describing center from service definition and obtaining with the service The service definition of mark describes file;The service definition describes center for the centrally stored service definition with service identifiers File is described;
Second acquisition module waits for deployment text for according to the file store path, being obtained from file storage service center Part;Each deployment file is waited for for managing concentratedly in the file storage service center;
Deployment module waits for that deployment file is deployed in the target for describing file according to the service definition by described On server.
Fourth aspect, the present invention provides a kind of files to dispose device, and described device includes:
Uploading module waits for that deployment file is uploaded to file storage service center for what will be generated, and waits for portion described in acquisition Affix one's name to the file store path of file;Described to wait for that deployment file has service identifiers, the file storage service center is for concentrating It manages and each waits for deployment file;
Enquiry module waits for the corresponding task of the service identifiers of deployment file for being described in service definition described in the inquiry of center Instruction queue information;The service definition describes center and describes the corresponding of file with service definition for centrally stored service identifiers Relationship, it includes assignment instructions queuing message that the service definition, which describes file,;Sending module, for according to the assignment instructions The file Disposition Instructions of the service identifiers that deployment file is waited for described in carrying and file store path are sent to correspondence by queuing message Assignment instructions queue, obtain file deployment from the assignment instructions queue so as to the proxy service module of destination server Instruction, and completed to the deployment for waiting for deployment file according to the file Disposition Instructions.
5th aspect, the present invention also provides a kind of file deployment facility, the equipment includes memory and processor,
Said program code is transferred to the processor by the memory for storing program code;
The processor is used to, according to the instruction in said program code, execute above-mentioned file dispositions method.
6th aspect, the present invention also provides a kind of computer readable storage medium, the computer readable storage medium In be stored with instruction, when described instruction is run on the terminal device so that the terminal device executes above-mentioned Documents Department's management side Method.
File dispositions method provided by the embodiments of the present application, is connect by the proxy service module operated on destination server Message in-coming part Disposition Instructions, wherein the file Disposition Instructions carry service identifiers and file store path, proxy service module from Service definition describes center and obtains corresponding with service identifiers service definition to describe file, and from file storage service center Acquisition is corresponding with this document store path to wait for deployment file, finally describes file according to service definition, will wait for deployment file portion It is deployed on destination server.The application runs on independent proxy service module on destination server, is proxy service module The permission for obtaining file Disposition Instructions and waiting for deployment file is assigned, the text to this kind of destination server is realized by proxy service module Part is disposed.Since the application is that the permission that proxy service module is opened is limited, the permission of relevant document deployment is pertained only to, so sharp It can be mapped out the work in the file of the server of the difficult support containerization technique of the higher realization of safety with the application.
Description of the drawings
In order to more clearly explain the technical solutions in the embodiments of the present application, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some embodiments of the present application, for For those of ordinary skill in the art, without having to pay creative labor, it can also be obtained according to these attached drawings His attached drawing.
Fig. 1 is a kind of file dispositions method flow chart provided by the embodiments of the present application;
Fig. 2 is that a kind of file provided by the embodiments of the present application disposes system schematic;
Fig. 3 is another file dispositions method flow chart provided by the embodiments of the present application;
Fig. 4 is a kind of configuration diagram of proxy service module provided by the embodiments of the present application;
Fig. 5 is that a kind of file provided by the embodiments of the present application disposes apparatus structure schematic diagram;
Fig. 6 is that another file provided by the embodiments of the present application disposes apparatus structure schematic diagram;
Fig. 7 is that a kind of file provided by the embodiments of the present application disposes device structure schematic diagram.
Specific implementation mode
Below in conjunction with the attached drawing in the embodiment of the present application, technical solutions in the embodiments of the present application carries out clear, complete Site preparation describes, it is clear that described embodiments are only a part of embodiments of the present application, instead of all the embodiments.It is based on Embodiment in the application, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall in the protection scope of this application.
File deployment refer to will generate wait for that deployment file is deployed on destination server, with realization wait for deployment file in mesh Mark the normal operation on server.It waits for that deployment file can be the new demand servicing software of exploitation, can also be the update of service software File etc..
In practical application, when the new demand servicing software that there is exploitation or when updating the deployment requirements of file, developer can New demand servicing software is submitted on backstage or updates the program code of file, and code is preserved to code storage.Build server Timing is polled code storage, is changed when determining to exist in code storage, when such as there is newly-increased content, is serviced by structure Device starts the construction work for waiting for deployment file according to the code variations in code storage, and then generates and wait for deployment file, finally, by Deployment unit triggering in structure server waits for mapping out the work for deployment file, soft to new demand servicing in destination server to realize Part or the deployment for updating file.
In order to realize it is above-mentioned wait for deployment file mapping out the work in destination server, usually used at present is containerization Technology, that is to say, that the destination server for deployment file need support containerization technique, so as in the scene of containerization Under carry out automation structure and deployment.But due to the presence of the existing architecture of destination server, some possible destination services Device does not support containerization transformation, upgrading, so, containerization skill cannot be enjoyed by mapping out the work for the file of this kind of destination server Art is brought convenient.
In order to solve the problems, such as not support the destination server of containerization transformation, upgrading to carry out file deployment to this kind of, this Application runs on independent proxy service module on destination server, is assigned for proxy service module and obtains file Disposition Instructions With the permission for waiting for deployment file, is realized by proxy service module and the file of this kind of destination server is disposed.Since the application is The permission that proxy service module is opened is limited, the permission of relevant document deployment is pertained only to, so can be in safety using the application Property it is higher in the case of realize destination server file map out the work.
Specifically, with reference to figure 1, a kind of method flow diagram of file deployment is provided for the embodiment of the present application, this method is answered For operating in the proxy service module on destination server, the method includes:
S101:Proxy service module receives the file Disposition Instructions for carrying service identifiers and file store path.
File Disposition Instructions are indicated for the instruction that proxy service module carries out file deployment, which can need It is sent when the file deployment for carrying out destination server, proxy service module starts to execute institute after receiving file Disposition Instructions The correlation step of file deployment on destination server.
Service identifiers and file store path are carried in file Disposition Instructions, wherein service identifiers are waited for for unique mark The corresponding service of deployment file;File store path waits for deployment file for unique mark, passes through file store path, agency's clothes Business module, which can obtain, corresponding waits for deployment file.
The transmission of the generation and file Disposition Instructions that wait for deployment file can be executed by structure server, specifically, structure Server may include file construction unit and file deployment unit, in the code building that file construction unit is submitted according to backstage After deployment file, file deployment unit, which can send to be used to indicate, disposes the file Disposition Instructions for waiting for deployment file.
In a kind of possible embodiment, proxy service module receives the file deployment that assignment instructions queue platform is sent and refers to It enables, this document Disposition Instructions are obtained from the assignment instructions queue for storage file Disposition Instructions by assignment instructions queue platform It takes.Specifically, file Disposition Instructions can be stored in assignment instructions queue and put down by the file deployment unit in structure server Assignment instructions queue in platform, and sent after obtaining file Disposition Instructions in assignment instructions queue by assignment instructions queue platform To proxy service module, after proxy service module receives file Disposition Instructions, the deployment to file is realized.Wherein, task refers to It includes multiple tasks instruction queue to enable queue platform, and each assignment instructions queue is used for storage file Disposition Instructions, assignment instructions Queue platform forms the relay station of structure server and proxy service module about file Disposition Instructions, avoids structure server hair When sending file Disposition Instructions, the loss of command information caused by destination server is not online.
S102:Proxy service module describes center according to the service identifiers, from service definition and obtains the service identifiers Corresponding service definition describes file;The service definition describes center and is described for centrally stored service identifiers and service definition The correspondence of file.
Service definition describes the correspondence that center describes file for centrally stored service identifiers and service definition, In, service definition describes the various configuration informations that file includes service.Proxy service module can be according in file Disposition Instructions The service identifiers of carrying, describe center from service definition and obtain the corresponding service definition of the service identifiers to describe file.
S103:Proxy service module obtains from file storage service center according to the file store path and waits for deployment text Part;Each deployment file is waited for for managing concentratedly in the file storage service center.
It is each after deployment file generation after, can first be centrally stored in file storage service center.Wherein, file storage clothes Business center can be distributed file storage system, and each in file storage service central store waits for that deployment file has file Store path can be inquired at file storage service center by file store path and corresponding wait for deployment file.Actually answer In, proxy service module, can be according to carrying in the file Disposition Instructions received after receiving file Disposition Instructions File store path obtains file corresponding with this document store path from file storage service center, as waits for deployment file. In the application other embodiment, wait for that deployment file can also be sent directly to proxy service module, such as can be with Documents Department Administration instructs while sending, and can also be sent with file Disposition Instructions different time, can also will carry the file for waiting for deployment file Disposition Instructions are directly stored in the assignment instructions queue in assignment instructions queue platform, so that proxy service module is obtaining text While part Disposition Instructions, directly obtained from assignment instructions queue platform it is corresponding wait for deployment file, it is above can conduct Wait for that the transmission mode of deployment file, the application are not limited.
S104:Proxy service module describes file according to the service definition, and to wait for that deployment file is deployed in described by described On destination server.
Proxy service module first obtains service definition and describes the configuration information in file before carrying out file deployment, In, configuration information for example may include waiting for which server deployment file should be deployed in, which port, need among which Part such as is supported at the information, and proxy service module according to configuration information wait for the deployment of deployment file, specifically, being waited for according to this The configuration information of deployment file is deployed on destination server in corresponding middleware services.
In addition, the proxy service module run on destination server can complete obtaining for configuration information in initial phase It takes and configuration work, specifically, describing the service mark that center obtains each service run on destination server from service definition Know corresponding service definition and describe file, and initial configuration is carried out to proxy service module by configuration information therein, it is complete It can complete to treat mapping out the work for deployment file at the proxy service module of configuration.In addition, proxy service module can also be It is installed to the configuration work that configuration information is completed before destination server, that is to say, that be configured with the generation of relevant configuration information After reason service module runs on destination server, you can startup waits for mapping out the work for deployment file.
File dispositions method provided by the embodiments of the present application, is connect by the proxy service module operated on destination server Message in-coming part Disposition Instructions, wherein the file Disposition Instructions carry service identifiers and file store path, proxy service module from Service definition describes center and obtains corresponding with service identifiers service definition to describe file, and from file storage service center Acquisition is corresponding with this document store path to wait for deployment file, finally describes file according to service definition, will wait for deployment file portion It is deployed on the destination server.The application runs on independent proxy service module on destination server, is agency service Module assigns the permission for obtaining file Disposition Instructions and waiting for deployment file, is realized to this kind of destination server by proxy service module File deployment.Since the application is that the permission that proxy service module is opened is limited, the permission of relevant document deployment, institute are pertained only to Using the application work can be disposed in the file of the server of the difficult support containerization technique of the higher realization of safety Make.
Specifically, the embodiment of the present application also provides a kind of file dispositions method, this method is applied to file deployment system, As shown in Fig. 2, this document deployment system includes proxy service module 110 and center service platform 120;Wherein, center service is flat Platform 120 describes center 123 including file storage service center 122, assignment instructions queue platform 121 and service definition, and file is deposited Service centre 122 is stored up, each deployment file is waited for for managing concentratedly;Service definition describes center 123, has for centrally stored The service definition of service identifiers describes file;Assignment instructions queue platform 121 is used for store tasks instruction queue;Agency service Module 110 is run on destination server 100, file Disposition Instructions are carried out by center service platform 120, wait for deployment file and Service definition describes the acquisition of file.
For clearer description file dispositions method provided by the embodiments of the present application, as shown in Fig. 2, except this document is disposed Further include deployment services device 130 outside system, specifically, deployment services device 130 includes monitoring unit 131, file construction unit 132, file deployment unit 133.
Correspondingly, being illustrated with reference to figure 3 applied to the file dispositions method in above-mentioned file deployment system, Fig. 3 is this Apply for the flow chart for another file dispositions method that embodiment provides, including:
S301:The pre-stored program code of deployment services device automatic regular polling, and detecting the presence of any program code When variation, deployment file is waited for according to the program code generation that there is variation is corresponding.
In practical application, the program code of the new demand servicing software of exploitation or update file is being committed to generation by developer Behind code warehouse, the file construction unit 132 in deployment services device 130 according to the code of submission can wait for the structure of deployment file It builds.When specific implementation, monitoring unit 131 can timing code storage is polled, when finding that the code in code storage has When changed, startup file construction unit 132, so that file construction unit 132 carries out corresponding wait for according to there is the code changed The structure of deployment file.
S302:Deployment services device waits for that deployment file is uploaded to file storage service center by generation, and is waited for described in acquisition The file store path of deployment file;Described to wait for that deployment file has service identifiers, the file storage service center is for collecting Middle management is each to wait for deployment file.
It completes after the structure of deployment file, generation is waited for that deployment file is stored in text by file deployment unit 133 Part storage service platform 122, and obtain the file store path for waiting for deployment file.Wherein, file storage service platform 122 is used for It waits for that deployment file progress is centrally stored by each, for waiting for deployment file in file storage service platform 122, text can be passed through Part store path is obtained, and centralized management and the calling that platform 122 may be implemented to treat deployment file are taken by file storage. In addition, file storage service platform 122 can also be realized by way of distributed document storage, it specifically can be for multiple Destination server accesses simultaneously.
S303:Deployment services device describes to wait for corresponding of the service identifiers of deployment file described in the inquiry of center in service definition Business instruction queue information;The service definition describes pair that center describes file for centrally stored service identifiers and service definition It should be related to, it includes assignment instructions queuing message that the service definition, which describes file,.
In practical application, before being disposed to file, the file deployment unit 132 of deployment services device is first from service It defines the inquiry of description center and waits for the corresponding assignment instructions queuing message of the service identifiers of deployment file, wherein assignment instructions queue Information may include queue identity, queue length etc., and the service definition that service definition describes central store describes file and includes Assignment instructions queuing message, so, after determining that service definition describes file by service identifiers, service definition description can be obtained Assignment instructions queuing message in file.
S304:Deployment services device will wait for the service mark of deployment file according to the assignment instructions queuing message described in carrying Know and the file Disposition Instructions of file store path are sent to corresponding assignment instructions queue.
In practical application, the file deployment unit 132 of deployment services device after getting assignment instructions queuing message, according to Assignment instructions queuing message, which will be used to indicate, to be treated the file Disposition Instructions that deployment file is disposed and is sent to corresponding task In instruction queue.
Assignment instructions queue platform 121 is used for store tasks instruction queue, and the number of assignment instructions queue can be one Or it is multiple, each assignment instructions queue is used for storage file Disposition Instructions.The purpose for creating assignment instructions queue is, reduces structure The direct communication between server 130 and destination server 100 is built, caused by possible in the case of online when avoiding the two different Instruction sends the generation for the failure scenarios such as interrupting or losing.
May include a plurality of file Disposition Instructions, a plurality of Documents Department in task instruction queue in a kind of embodiment Administration's instruction can be that the proxy service module on the same destination server of instruction waits for that deployment file is disposed to multiple, can also It is that the proxy service module for indicating respectively on different target server is treated deployment file and disposed.
When multiple destination servers are required to carry out file deployment, can also be stored in assignment instructions queue platform 121 There are multiple tasks instruction queue, each assignment instructions queue to correspond respectively to a destination server, operates in each target clothes The proxy service module of business device can obtain file Disposition Instructions from corresponding assignment instructions queue, formed structure server with Information bridge between proxy service module in each destination server about file Disposition Instructions.
When each destination server all has corresponding assignment instructions queue, file deployment unit 133 is being sent Before file Disposition Instructions, it can also obtain and obtain the corresponding destination server of this document Disposition Instructions in advance, so that it is determined that should The corresponding assignment instructions queue of destination server, so that this document Disposition Instructions are sent to corresponding assignment instructions queue.
In a kind of realization method, service definition describes center 123 and is stored with each to wait for the corresponding service definition of deployment file File is described, wherein service definition describes file and corresponding waits for that deployment file should be deployed in which target clothes for storing The information such as business device, the corresponding assignment instructions queue of the destination server.File deployment unit 133 send file Disposition Instructions it Before, it describes center 123 from service definition and obtains corresponding assignment instructions queue, to complete the accurate hair of this document Disposition Instructions It send, consequently facilitating the proxy service module in the corresponding destination server of assignment instructions queue carries out the standard of file Disposition Instructions Really obtain.
S305:Proxy service module 110 initializes.
In the initial phase of proxy service module 110, center 123 can be described from service definition and obtains and waits for deployment text The corresponding service definition of part describes file, and describes file using the service definition and initialized, to complete to wait disposing with this The relevant configuration of file.Wherein, service definition describes center 123 and describes text for storing each service definition for waiting for deployment file Part, service definition describe file for storing the configuration information of each service, such as the configuration path of a certain service, workable Middleware, version information etc..
As shown in figure 4, being a kind of configuration diagram of proxy service module provided in an embodiment of the present invention.Specifically, When proxy service module 110 starts, proxy service module 110 can utilize the service definition got to describe in file Service-plugin-path service plugs path carries out initial configuration, and agency clothes are described in the service plug path Business module can support which middleware services, each middleware services to support which is instructed and these instructions are specific respectively Realized by which calling, order line etc..Proxy service module 110 is parsed using service-plugin-parser service paths The plug-in description file configured under 401 reading service plug-in unit path of device, specific file format may include:Service unique login name The system command of the common operation such as title, service type, service path, start/stop/restart/deploy/reload, with And availability checks interface (port or url) etc..In a kind of realization method, service path resolver passes through the unique registration of service Title, service type and service path, can parse which middleware services is the proxy service module can support;Pass through The system command of the common operation such as start/stop/restart/deploy/reload, can parse the proxy service module The each middleware services supported support which is instructed and which these instructions specifically called by, order line is realized etc. respectively. Cli-runner orders performer 402 is responsible for the instruction etc. for calling service path resolver to parse.Registry-client is noted Volume user terminal 403 is responsible for describing center with service definition and being communicated, to describe the corresponding service of center acquisition from service definition Definition description file.File-utils file tools 404 are responsible for waiting for deployment file from the download of file storage service center is corresponding. Version-manager revisions managers 405 are responsible for cooperation file tool 404 and record current service version and version updating, Center upload deployment is described for realizing the rollback of service history version, backup and to service definition after file deployment success State etc..Monitor monitors 406 are responsible for the health status to proxy service module during proxy service module is run It is monitored.
In addition, when service definition describe center 123 storage service description file there are when content update, service definition is retouched Update notification information can be generated by stating center 123, and the update notification information is sent to corresponding proxy service module 110, To notify the proxy service module 110 from the service definition to describe center 123 and obtain updated service definition to describe file, into And update the configuration information of respective services.
Service definition describes center 123 and describes file for centrally stored each service definition, and service definition describes file In describe each service and can be deployed in which server, which port, be supported using which middleware.Service Definition description file can support common service configuration system, such as etdc, zookeeper and consul system etc., this The configuration based on git code mandatory systems that the config-server using springboot is realized can also be supported outside, herein The system configuration that service definition describes file support is not limited.
Assignment instructions queue is formed between the proxy service module in structure server and each destination server about text The case where information bridge of part Disposition Instructions, opposite end is without responding caused by avoiding one end from going offline.In proxy service module 110 Initial phase, proxy service module, which by reading service defines the configuration information in description file and obtains corresponding task, to be referred to Enable queuing message, the corresponding assignment instructions queue of destination server can be pre-created in task instruction queue platform 121, with In the storage 100 corresponding file Disposition Instructions of destination server.Create the corresponding assignment instructions queue of destination server and be for Proxy service module can be directly obtained corresponding file Disposition Instructions in corresponding assignment instructions queue, simplify file The acquisition process of Disposition Instructions.
S306:Proxy service module 110 receive assignment instructions queue platform send carry service identifiers and file is deposited Store up the file Disposition Instructions in path;Wherein, the file Disposition Instructions are by the assignment instructions queue platform from for storing It is obtained in the assignment instructions queue of the file Disposition Instructions.
There are when file Disposition Instructions in assignment instructions queue in assignment instructions platform 121, assignment instructions platform can be with This document Disposition Instructions are sent to corresponding proxy service module.
In a kind of realization method, the assignment instructions queue in task instruction queue platform 121 receives file deployment and refers to After order, instruction notification information can be generated, and the instruction notification information is sent to corresponding proxy service module 110, with logical Know that the proxy service module 110 obtains file Disposition Instructions from corresponding assignment instructions queue.
In another realization method, proxy service module 110 can be with corresponding in polling tasks instruction queue platform 121 Business instruction queue, to obtain file Disposition Instructions.It, can be with when proxy service module 110 has corresponding assignment instructions queue The corresponding assignment instructions queue of poll, to obtain file Disposition Instructions.
S307:Proxy service module describes center according to the service identifiers, from service definition and obtains with the service The service definition of mark describes file;The service definition describes center for the centrally stored service definition with service identifiers File is described.
Specifically, can refer to S102, details are not described herein.
Proxy service module 110 can be according to file storage address, and acquisition this document is deposited from file storage service platform 122 Address is corresponding waits for deployment file for storage, wherein file storage service platform 122 each waits for deployment file for storing.Actually answer In, file tool (file-utils) submodule in proxy service module 110 can be used for from file storage service platform It is downloaded in 122 and corresponding waits for deployment file.
S308:Proxy service module obtains from file storage service center according to the file store path and waits for deployment text Part;Each deployment file is waited for for managing concentratedly in the file storage service center.
Specifically, can refer to S103, details are not described herein.
S309:Proxy service module describes file according to the service definition, and to wait for that deployment file is deployed in described by described On destination server.
Proxy service module 110 can be obtained first before carrying out file deployment and wait for the corresponding service definition of deployment file Describe file in configuration information, configuration information for example may include wait for deployment file should be deployed in which server, which Which middleware a port needs information, the proxy service module 110 such as be supported to be carried out waiting for deployment file according to configuration information Deployment.
Usually operation has several middleware services on destination server, treats the deployment of deployment file, will specifically wait for portion Administration's file is deployed in corresponding middleware services, by starting the middleware services and running on destination server, energy It is enough to wait for deployment file normal operation in the destination server so that being deployed in the middleware services.
In addition, in the embodiment of the present application, proxy service module can also take each middleware on destination server Business is restarted and/or is suspended and controlled, specifically, after proxy service module can receive the control instructions of middleware services, Corresponding middleware services are controlled to start and/or suspend.The acquisition methods of specific control instruction can be disposed with reference paper to be referred to The acquisition methods of order are understood that details are not described herein.
S310:The deployment result for waiting for deployment file is uploaded in the service definition description by proxy service module The heart describes file so that corresponding service definition is added in the deployment result for waiting for deployment file.
For the ease of developer understand file deployable state, the embodiment of the present application will wait for deployment file be deployed in target clothes It is engaged in after device 100, file deployable state is sent to service definition by proxy service module 110 and describes center 123, to service It defines description center and the corresponding service definition of the deployment result for waiting for deployment file addition is described into file, serviced subsequently through accessing Defining description center 123 can know that file disposes result.
In practical application, the current service version after proxy service module 110 can be disposed file is completed is sent to clothes Business defines description center 123, is backed up so that service definition describes center 123.Version management in proxy service module 110 Device (version-manager) records the tool of current service version and update status, can realize the history version of corresponding with service This rollback and backup etc., i.e., the new version of service when something goes wrong, the version of the service can be restored to legacy version.
In file dispositions method provided by the embodiments of the present application, deployment services device automatic regular polling program code, and in program When code has variation, generation is corresponding to wait for deployment file, and is uploaded to file storage service center.Then by operating in mesh Proxy service module on mark server obtains the file Disposition Instructions in corresponding assignment instructions queue, and is disposed according to file It instructs the service identifiers carried and file store path to obtain corresponding service definition to describe file and wait for deployment file, final root Describing file according to service definition will wait for that deployment file is deployed on destination server.It is taken in target using independent operating in the application Be engaged in device on proxy service module realize file deployment, proxy service module can to file Disposition Instructions, wait for deployment file File is described with service definition to be obtained, and using the file Disposition Instructions got, waits for that deployment file and service definition describe File can realize that the file on destination server is disposed.Since the application is that the permission that proxy service module is opened is limited, only relate to And the permission of relevant document deployment, so can support containerization to hardly possible in higher realize of safety using the application The file of the server of technology maps out the work.
Based on the embodiment of the above file dispositions method, present invention also provides a kind of files to dispose device, device fortune Row is on destination server, and with reference to figure 5, described device includes:
Receiving module 501, for receiving the file Disposition Instructions for carrying service identifiers and file store path;
First acquisition module 502, for according to the service identifiers, describing center from service definition and obtaining with the clothes The service definition of business mark describes file;It is fixed for the centrally stored service with service identifiers that the service definition describes center Justice description file;
Second acquisition module 503, for according to the file store path, being obtained from file storage service center and waiting disposing File;Each deployment file is waited for for managing concentratedly in the file storage service center;
Deployment module 504 waits for that deployment file is deployed in the mesh for describing file according to the service definition by described It marks on server.
In addition, present invention also provides a kind of files to dispose device, with reference to figure 6, described device includes:
Uploading module 601 waits for that deployment file is uploaded to file storage service center for what will be generated, and is waited for described in acquisition The file store path of deployment file;Described to wait for that deployment file has service identifiers, the file storage service center is for collecting Middle management is each to wait for deployment file;
Enquiry module 602 waits for that the service identifiers of deployment file are corresponding for being described in service definition described in the inquiry of center Assignment instructions queuing message;The service definition describes center and describes file for centrally stored service identifiers and service definition Correspondence, it includes assignment instructions queuing message that the service definition, which describes file,;
Sending module 603, for according to the assignment instructions queuing message, the service mark of deployment file will to be waited for described in carrying Know and the file Disposition Instructions of file store path are sent to corresponding assignment instructions queue, is taken so as to the agency of destination server Module of being engaged in obtains the file Disposition Instructions from the assignment instructions queue, and is completed to described according to the file Disposition Instructions Wait for the deployment of deployment file.
File provided by the embodiments of the present application disposes device, is connect by the proxy service module operated on destination server Message in-coming part Disposition Instructions, according to the file identification that file Disposition Instructions carry, acquisition is corresponding with the file identification to be waited disposing File will wait for that deployment file is deployed on destination server.Independent proxy service module is run on destination service by the application On device, the permission for obtaining file Disposition Instructions and waiting for deployment file is assigned for proxy service module, is realized by proxy service module File deployment to this kind of destination server.Since the application is that the permission that proxy service module is opened is limited, pertain only to related The permission of file deployment, so can be disposed in the higher file for realizing destination server of safety using the application Work.
Correspondingly, the embodiment of the present application also provides a kind of file deployment facility, it is shown in Figure 7, may include:
Processor 701, memory 702, input unit 703 and output device 704.Processor in file deployment facility 701 quantity can be one or more, in Fig. 7 by taking a processor as an example.In some embodiments of the invention, processor 701, memory 702, input unit 703 and output device 704 can be connected by bus or other means, wherein with logical in Fig. 7 It crosses for bus connection.
Memory 702 can be used for storing software program and module, and processor 701 is stored in memory 702 by operation Software program and module, to execute various function application and the data processing of file deployment facility.Memory 702 can Include mainly storing program area and storage data field, wherein storing program area can storage program area, needed at least one function Application program etc., program code can also be transferred to processor 701 by memory 702.In addition, memory 702 may include High-speed random access memory can also include nonvolatile memory, for example, at least disk memory, a flash memories Part or other volatile solid-state parts.Input unit 703 can be used for receiving the number or character information of input, and production Raw signal input related with the user setting of file deployment facility and function control.
Specifically in the present embodiment, processor 701 can be according to following instruction, by one or more application program The corresponding executable file of process be loaded into memory 702, and be stored in memory 702 by processor 701 to run Application program, according in said program code instruction realize the application in file dispositions method function.
For device embodiments, since it corresponds essentially to embodiment of the method, so related place is referring to method reality Apply the part explanation of example.The apparatus embodiments described above are merely exemplary, wherein described be used as separating component The unit of explanation may or may not be physically separated, and the component shown as unit can be or can also It is not physical unit, you can be located at a place, or may be distributed over multiple network units.It can be according to actual It needs that some or all of module therein is selected to achieve the purpose of the solution of this embodiment.Those of ordinary skill in the art are not In the case of making the creative labor, you can to understand and implement.
It should be noted that herein, relational terms such as first and second and the like are used merely to a reality Body or operation are distinguished with another entity or operation, are deposited without necessarily requiring or implying between these entities or operation In any actual relationship or order or sequence.Moreover, the terms "include", "comprise" or its any other variant are intended to Non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only wanted including those Element, but also include other elements that are not explicitly listed, or further include for this process, method, article or equipment Intrinsic element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that There is also other identical elements in process, method, article or equipment including the element.
The method, apparatus and equipment of a kind of file deployment provided above the embodiment of the present application have carried out detailed Jie It continues, specific examples are used herein to illustrate the principle and implementation manner of the present application, and the explanation of above example is only It is to be used to help understand the method for this application and its core ideas;Meanwhile for those of ordinary skill in the art, according to this Shen Thought please, there will be changes in the specific implementation manner and application range, in conclusion the content of the present specification should not manage Solution is the limitation to the application.

Claims (12)

1. a kind of file dispositions method, which is characterized in that the method is applied to operate in the agency service on destination server Module, the method includes:
The proxy service module receives the file Disposition Instructions for carrying service identifiers and file store path;
The proxy service module describes center according to the service identifiers, from service definition and obtains with the service identifiers Service definition describes file;The service definition describes center and describes text for the centrally stored service definition with service identifiers Part;
The proxy service module obtains from file storage service center according to the file store path and waits for deployment file;Institute It states file storage service center and each waits for deployment file for managing concentratedly;
The proxy service module describes file according to the service definition, waits for that deployment file is deployed in the target and takes by described It is engaged on device.
2. file dispositions method according to claim 1, which is characterized in that the proxy service module is according to the service Definition description file, waits for that deployment file is deployed on the destination server by described, including:
The proxy service module obtains the service definition and describes service profile information in file;
The proxy service module waits for that deployment file is deployed in corresponding middleware and takes according to the service profile information, by described In business, wherein the middleware services run on the destination server.
3. file dispositions method according to claim 2, which is characterized in that the method further includes:
The proxy service module controls restarting and/or suspending for each middleware services on the destination server.
4. file dispositions method according to claim 1, which is characterized in that the proxy service module reception carries clothes The file Disposition Instructions of business mark and file store path, including:
What the proxy service module received that assignment instructions queue platform sends carry service identifiers and file store path File Disposition Instructions;Wherein, the file Disposition Instructions are by the assignment instructions queue platform from for storing the file It is obtained in the assignment instructions queue of Disposition Instructions.
5. file dispositions method according to claim 4, which is characterized in that the proxy service module receives assignment instructions Before the file Disposition Instructions for carrying service identifiers and file store path that queue platform is sent, further include:
The proxy service module describes center from the service definition and obtains itself corresponding assignment instructions queuing message;
The proxy service module creates the clothes according to the assignment instructions queuing message, in the assignment instructions queue platform Business identifies corresponding assignment instructions queue;It includes assignment instructions queuing message that the service definition, which describes file,.
6. according to claim 1-5 any one of them file dispositions methods, which is characterized in that the proxy service module according to The service definition describes file, by it is described wait for that deployment file is deployed on the destination server after, further include:
The deployment result for waiting for deployment file is uploaded to the service definition and describes center by the proxy service module, so as to Corresponding service definition is added in the deployment result for waiting for deployment file and describes file.
7. a kind of file dispositions method, which is characterized in that the method is applied to deployment services device, the method includes:
The deployment services device waits for that deployment file is uploaded to file storage service center by generation, and deployment text is waited for described in acquisition The file store path of part;Described to wait for that deployment file has service identifiers, the file storage service center is for managing concentratedly It is each to wait for deployment file;
The deployment services device describes to wait for that the corresponding task of the service identifiers of deployment file refers to described in the inquiry of center in service definition Enable queuing message;The service definition describes the corresponding pass that center describes file for centrally stored service identifiers with service definition System, it includes assignment instructions queuing message that the service definition, which describes file,;
The deployment services device will wait for the service identifiers and text of deployment file according to the assignment instructions queuing message described in carrying The file Disposition Instructions of part store path are sent to corresponding assignment instructions queue, so as to the proxy service module of destination server The file Disposition Instructions are obtained from the assignment instructions queue, and wait disposing to described according to file Disposition Instructions completion The deployment of file.
8. file dispositions method according to claim 1, which is characterized in that the deployment services device waits disposing by generation File is uploaded to before file storage service center, further includes:
The pre-stored program code of deployment services device automatic regular polling, and changed detecting that any program code exists When, wait for deployment file according to the program code generation that there is variation is corresponding.
9. a kind of file disposes device, which is characterized in that described device includes:
Receiving module, for receiving the file Disposition Instructions for carrying service identifiers and file store path;
First acquisition module, for according to the service identifiers, describing center from service definition and obtaining with the service identifiers Service definition file is described;The service definition describes center for the centrally stored service definition description with service identifiers File;
Second acquisition module, for according to the file store path, being obtained from file storage service center and waiting for deployment file;Institute It states file storage service center and each waits for deployment file for managing concentratedly;
Deployment module waits for that deployment file is deployed in the destination service for describing file according to the service definition by described On device.
10. a kind of file disposes device, which is characterized in that described device includes:
Uploading module waits for that deployment file is uploaded to file storage service center for what will be generated, and waits for deployment text described in acquisition The file store path of part;Described to wait for that deployment file has service identifiers, the file storage service center is for managing concentratedly It is each to wait for deployment file;
Enquiry module waits for the corresponding assignment instructions of the service identifiers of deployment file for being described in service definition described in the inquiry of center Queuing message;The service definition describes the corresponding pass that center describes file for centrally stored service identifiers with service definition System, it includes assignment instructions queuing message that the service definition, which describes file,;
Sending module, for according to the assignment instructions queuing message, the service identifiers and text of deployment file will to be waited for described in carrying The file Disposition Instructions of part store path are sent to corresponding assignment instructions queue, so as to the proxy service module of destination server The file Disposition Instructions are obtained from the assignment instructions queue, and wait disposing to described according to file Disposition Instructions completion The deployment of file.
11. a kind of file deployment facility, which is characterized in that the equipment includes memory and processor,
Said program code is transferred to the processor by the memory for storing program code;
The processor is used for according to the instruction in said program code, and perform claim requires the file described in any one of 1-8 Dispositions method.
12. a kind of computer readable storage medium, which is characterized in that instruction is stored in the computer readable storage medium, When described instruction is run on the terminal device so that the terminal device is executed such as claim 1-8 any one of them texts Part dispositions method.
CN201810322553.7A 2018-04-11 2018-04-11 A kind of file dispositions method, device and equipment Pending CN108549542A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810322553.7A CN108549542A (en) 2018-04-11 2018-04-11 A kind of file dispositions method, device and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810322553.7A CN108549542A (en) 2018-04-11 2018-04-11 A kind of file dispositions method, device and equipment

Publications (1)

Publication Number Publication Date
CN108549542A true CN108549542A (en) 2018-09-18

Family

ID=63514526

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810322553.7A Pending CN108549542A (en) 2018-04-11 2018-04-11 A kind of file dispositions method, device and equipment

Country Status (1)

Country Link
CN (1) CN108549542A (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109542462A (en) * 2018-10-17 2019-03-29 平安科技(深圳)有限公司 A kind of system environments dispositions method, storage medium and server
CN110138876A (en) * 2019-05-30 2019-08-16 北京达佳互联信息技术有限公司 Task deployment method, apparatus, equipment and platform
CN110413288A (en) * 2019-07-31 2019-11-05 新华三大数据技术有限公司 Using dispositions method, device, server and storage medium
WO2020143324A1 (en) * 2019-01-08 2020-07-16 平安科技(深圳)有限公司 Service program releasing method and apparatus, and computer device and storage medium
CN111931103A (en) * 2020-07-09 2020-11-13 北京皮尔布莱尼软件有限公司 Website deployment method
CN112181436A (en) * 2019-07-03 2021-01-05 深圳兆日科技股份有限公司 Service deployment method, device, server and readable storage medium
WO2021068348A1 (en) * 2019-10-10 2021-04-15 平安科技(深圳)有限公司 Task deployment method and system, and storage medium
CN113448594A (en) * 2021-06-29 2021-09-28 京东科技控股股份有限公司 Service processing method and device, computer equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104360878A (en) * 2014-10-29 2015-02-18 中国建设银行股份有限公司 Method and device for deploying application software
CN104572202A (en) * 2015-01-08 2015-04-29 浪潮电子信息产业股份有限公司 Method for allocating enterprise-level application software under cloud computing
US20160357544A1 (en) * 2015-06-05 2016-12-08 Apple Inc. On demand resources
CN106325951A (en) * 2016-08-30 2017-01-11 广西电网有限责任公司 Automatic deployment method for application system supporting multiple databases and multiple middleware types
CN106325975A (en) * 2016-09-09 2017-01-11 浪潮软件股份有限公司 Method for automatically deploying and managing big data clusters through Docker container
WO2017095565A1 (en) * 2015-12-01 2017-06-08 Intel Corporation Methods and apparatus to provide for efficient and secure software updates
US20170177314A1 (en) * 2015-12-17 2017-06-22 Architecture Technology Corporation Application randomization mechanism

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104360878A (en) * 2014-10-29 2015-02-18 中国建设银行股份有限公司 Method and device for deploying application software
CN104572202A (en) * 2015-01-08 2015-04-29 浪潮电子信息产业股份有限公司 Method for allocating enterprise-level application software under cloud computing
US20160357544A1 (en) * 2015-06-05 2016-12-08 Apple Inc. On demand resources
WO2017095565A1 (en) * 2015-12-01 2017-06-08 Intel Corporation Methods and apparatus to provide for efficient and secure software updates
US20170177314A1 (en) * 2015-12-17 2017-06-22 Architecture Technology Corporation Application randomization mechanism
CN106325951A (en) * 2016-08-30 2017-01-11 广西电网有限责任公司 Automatic deployment method for application system supporting multiple databases and multiple middleware types
CN106325975A (en) * 2016-09-09 2017-01-11 浪潮软件股份有限公司 Method for automatically deploying and managing big data clusters through Docker container

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109542462A (en) * 2018-10-17 2019-03-29 平安科技(深圳)有限公司 A kind of system environments dispositions method, storage medium and server
WO2020143324A1 (en) * 2019-01-08 2020-07-16 平安科技(深圳)有限公司 Service program releasing method and apparatus, and computer device and storage medium
CN110138876A (en) * 2019-05-30 2019-08-16 北京达佳互联信息技术有限公司 Task deployment method, apparatus, equipment and platform
CN110138876B (en) * 2019-05-30 2022-07-08 北京达佳互联信息技术有限公司 Task deployment method, device, equipment and platform
CN112181436A (en) * 2019-07-03 2021-01-05 深圳兆日科技股份有限公司 Service deployment method, device, server and readable storage medium
CN110413288A (en) * 2019-07-31 2019-11-05 新华三大数据技术有限公司 Using dispositions method, device, server and storage medium
WO2021068348A1 (en) * 2019-10-10 2021-04-15 平安科技(深圳)有限公司 Task deployment method and system, and storage medium
CN111931103A (en) * 2020-07-09 2020-11-13 北京皮尔布莱尼软件有限公司 Website deployment method
CN113448594A (en) * 2021-06-29 2021-09-28 京东科技控股股份有限公司 Service processing method and device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
CN108549542A (en) A kind of file dispositions method, device and equipment
US5832191A (en) Method and apparatus for automatically enabling communication with a network printer
JP3850859B2 (en) Hall management system
US9485134B2 (en) Managing configurations of system management agents in a distributed environment
US9465625B2 (en) Provisioning of operating environments on a server in a networked environment
US20170154017A1 (en) Web Application Management
US8667114B2 (en) Program update management server and program update management method
US20070266120A1 (en) System and method for handling instructions in a pre-boot execution environment
CN101393524A (en) Firmware update method and system using the same
US10313282B1 (en) Flexible middleware messaging system
CN104346198A (en) Information processing apparatus, server apparatus, information processing method, and program
CN110855746A (en) Middleware management method, electronic device and storage medium
CN109104368B (en) Connection request method, device, server and computer readable storage medium
CN116566984B (en) Routing information creation method and device of k8s container cluster and electronic equipment
WO2013132910A1 (en) Host providing system and host providing method
CN100375427C (en) Cluster device batch file transmitting method and file transmission device
US8332494B2 (en) Device management system, servers, method for managing device, and computer readable medium
CN111506388B (en) Container performance detection method, container management platform and computer storage medium
JP2007188183A (en) Information providing device, information providing program and device detecting method
Krainyk et al. Internet-of-Things Device Set Configuration for Connection to Wireless Local Area Network.
CN105049463A (en) Distributed database, method of sharing data, and apparatus for a distributed database
JP2015099547A (en) Software update method, software update apparatus, software update program, and software update system
JP2006113754A (en) Software update device and method
US7444430B2 (en) Terminal apparatus and control method thereof
CN113377385A (en) Client automatic deployment method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20180918