Summary of the invention
The application provides debug system and a kind of acting server of Flash in the adjustment method of Flash in a kind of browser, a kind of browser; When solving the operation of local Flash in browser, the problem of resource on can't the server at load fault Flash place.
In order to address the above problem, the application discloses the adjustment method of Flash in a kind of browser, comprising:
Acting server receives the Flash request of data information that browser sends, and comprises first address of fault Flash in the wherein said Flash request of data information;
With first map addresses to second address of target Flash;
According to second address, send target Flash to browser.
Preferably, target Flash is sent to browser in said foundation second address, comprising:
On said second address, obtain target Flash;
Said target Flash is sent to browser.
Preferably, also comprise in the said Flash request of data information: the source resource addresses of fault Flash,
After the Flash request of data information that said acting server reception browser sends, further comprise:
Send the server of said Flash request of data information to fault Flash place;
The source resource of the fault Flash that the server at reception fault Flash place sends;
The source resource of said fault Flash is sent to browser.
Preferably, said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preferably, if target Flash is for adding the Flash of output journal, described method further comprises:
The daily record of the Flash that adds daily record output is exported and checked to debug terminal, to confirm the running status of the Flash that said adding daily record is exported.
Preferably, if target Flash is the Flash of locating and displaying, described method further comprises:
Debug terminal checks whether the locating and displaying of target Flash in the browser is normal.
Preferably, described method further comprises:
The fault Flash that debug terminal will be downloaded in advance carries out decompiling;
Exist location of fault to add printout or locating and displaying at fault Flash;
Second address that generates target Flash and preserve said target Flash.
Preferably, debug terminal is built acting server, and in acting server, sets up the mapping relations of first address and second address.
Accordingly, disclosed herein as well is the debug system of Flash in a kind of browser, comprising: the server and the browser at debug terminal, fault Flash place, wherein, said debug terminal comprises acting server,
Said acting server comprises:
First receives submodule, is used to receive the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information;
Mapping submodule is used for second address of first map addresses to target Flash;
First sends submodule, is used to send target Flash to browser.
Preferably, said first sends submodule, comprising:
Acquiring unit is used on said second address, obtaining target Flash;
Transmitting element is used for said target Flash is sent to browser.
Preferably, also comprise in the said Flash requesting data information: the address of the source data of fault Flash, said acting server also comprises:
Second sends submodule, is used to send the server of said Flash request of data information to fault Flash place;
Second receives submodule, is used to receive the source data of the fault Flash that the server at fault Flash place sends;
The 3rd sends submodule, is used for the source data of said fault Flash is sent to browser.
Preferably, said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preferably, if target Flash is for adding the Flash of output journal, said debug terminal also comprises:
Output module is used to export and check the daily record of the Flash that adds daily record output, to confirm the running status of the Flash that said adding daily record is exported.
Preferably, if target Flash is for adding the Flash of output journal, said debug terminal also comprises:
Output module is used for checking whether the locating and displaying of browser target Flash is normal.
Preferably, said debug terminal also comprises:
Download module is used for the fault Flash that downloads is in advance carried out decompiling;
Add module, be used for existing location of fault to add printout or locating and displaying at fault Flash,
Generation module is used to second address that generates target Flash and preserve said target Flash;
Preferably, said debug terminal is used to build acting server, and in acting server, sets up the mapping relations of first address and second address.
Preferably, said browser comprises the configuration submodule,
Said configuration submodule is used for Service-Port is configured to acting server.
Accordingly, disclosed herein as well is a kind of acting server, comprising:
First receives submodule, is used to receive the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information;
Mapping submodule is used for second address of first map addresses to target Flash;
First sends submodule, is used to send target Flash to browser.
Preferably, said first sends submodule, comprising:
Acquiring unit is used on said second address, obtaining target Flash;
Transmitting element is used to send said target Flash and sends to browser.
Preferably, also comprise the address of the source data of fault Flash in the said Flash requesting data information, said acting server also comprises:
Second sends submodule, is used to send the server of said Flash request of data information to fault Flash place;
Second receives submodule, is used for the source data of the fault Flash that the server at fault Flash place sends;
The 3rd sends submodule, is used for the source data of said fault Flash is sent to browser.
Preferably, said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preferably, the mapping relations that comprise first address and second address in the said acting server.
Compared with prior art, the application comprises following advantage:
Acting server receives the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information; With first map addresses to second address of target Flash; According to second address, send target Flash to browser.The application is through the agency of acting server as the server at fault Flash place; Can be when browse request be obtained fault Flash; It is replaced to target Flash, do not have the problem of security strategy, make target Flash be able in browser, move normally; In the time of can not having the operation of target Flash in browser, the problem of resource on can't the server at load fault Flash place.
Embodiment
For above-mentioned purpose, the feature and advantage that make the application can be more obviously understandable, the application is done further detailed explanation below in conjunction with accompanying drawing and embodiment.
Therefore some browsers extract the Flash thread in the page in order to reduce the influence of Flash thread to page process, adopt detached process to move Flash.
When using detached process operation Flash; Sometimes the Flash that moves in the webpage may go wrong; Flash exhibiting pictures continuously for example, but the call number of picture is disappeared when showing, and will analyze this moment is the fault that where occurred of Flash; So as the debugging and improve browser, to the user better service is provided.
The application provides the adjustment method of Flash in a kind of browser; Through the agency of acting server as the server at fault Flash place; Can when browse request is obtained fault Flash, it be replaced to the Flash that adds daily record output, the homology restriction therefore when the related data of browse request Flash, can not occur; The problem that does not have security strategy; The Flash that make to add daily record output is able in browser, move normally, in the time of can not having the operation of Flash in browser that adds daily record output, and the problem of resource on can't the server at load fault Flash place.
With reference to Fig. 1, provided the adjustment method process flow diagram of Flash in the said a kind of browser of the application embodiment.
Step 11, acting server receives the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information;
After acting server is built completion; Can open the original web page at fault Flash place through browser; Can send Flash request of data information during the browser execution original web page and give acting server; Comprise first address of fault Flash in the said Flash request of data information, can get access to fault Flash.
Certainly, browser can also send other request of data information, like address of web page title etc.The application does not do qualification to this.
Acting server can receive the Flash request of data information that browser sends.
Step 12, with first map addresses to second address of target Flash;
Acting server can replace to target Flash with fault Flash after the Flash request of data information that receives request fault Flash, therefore can be with first map addresses of fault Flash to second address of target Flash.
Step 13 according to second address, is sent target Flash and is given browser;
Acting server can be with first map addresses of fault Flash to second address of target Flash, on second address of said target Flash, gets access to target Flash then, and sends to browser.
In sum, acting server receives the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information; With first map addresses to second address of target Flash; According to second address, send target Flash to browser.The application is through the agency of acting server as the server at fault Flash place; Can be when browse request be obtained fault Flash; It is replaced to target Flash, do not have the problem of security strategy, make target Flash be able in browser, move normally; In the time of can not having the operation of target Flash in browser, the problem of resource on can't the server at load fault Flash place.
Specifically discuss the adjustment method of Flash in the browser below with embodiment:
For example, open the homepage of website A, comprising the Flash of a continuous exhibiting pictures, but when this Flash operation, the call number of picture is disappeared, and therefore can regard this Flash as fault Flash, and wherein, the server of website A is the A server.Fault Flash when operation the fault Flash source resources such as picture relevant wherein with fault Flash all to from the A server, obtain.
With reference to Fig. 2, provided the adjustment method process flow diagram of Flash in the said a kind of browser of the application's preferred embodiment.
Step 201 is carried out decompiling with the fault Flash that downloads in advance;
From the A server, download fault Flash in advance, use project file and internal code that the decompiling instrument obtains fault Flash then.
Step 202 exists location of fault to add printout or locating and displaying at fault Flash;
In the prior art, some Flash can't output journal, and the actuating logic of code that therefore can be through analysis of failure Flash adds printout, the daily record that can obtain exporting when making follow-up operation Flash at in-problem key aspect then.
Also having some fault Flash is the existing problems such as picture that wherein show, therefore can show that in-problem picture place can add locating and displaying, for example amplifies said picture, or dwindles said picture etc.
Certainly; Also possibly there is other problem in fault Flash in practical implementation, and promptly to the collocation method of corresponding problem location, the application does not enumerate one by one; Therefore problem and the corresponding collocation method of fault Flash in problem location, the scope that all belongs to the application and protected.
Step 203, second address that generates target Flash and preserve said target Flash.
Target Flash can be generated according to above-mentioned steps, after in-problem key aspect adds printout, the Flash that adds daily record output can be generated; After in-problem key aspect adds locating and displaying, can generate the Flash of locating and displaying, then said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preserve and write down second address of said target Flash then.
Step 204 is built acting server;
Wherein, and in acting server, set up the mapping relations of first address and second address
For example, build an apache server, revise configuration wherein then, for example open rewrite, the proxy module is added and is rewritten configuration.
Wherein, can see RewriteRule as transformation rule or mapping set.
Therefore, if include a plurality of fault Flash in a webpage in the practical implementation, then can generate the target Flash of a plurality of correspondences.In acting server, also to dispose the mapping relations between second address of first address and target Flash of a plurality of fault Flash, i.e. transformation rule (mapping set).
For example, fault Flash-1, fault Flash-2 and fault Flash-3, corresponding target Flash-1, target Flash-2 and target Flash-3.
Then in the transformation rule of acting server, can be provided with: 1, with the map addresses of fault Flash-1 to the address of target Flash-1; 2, with the map addresses of fault Flash-2 to the address of target Flash-2; 3, with the map addresses of fault Flash-3 to the address of target Flash-3.
And write down the information such as address and port arrangement of said acting server.
Step 205, browser is configured to Service-Port on the acting server;
Then, can Service-Port be configured on the acting server by browser, make browser to obtain the page corresponding server data of (like, A server) through acting server.
A kind of method to set up wherein is: select in the browser " Internet (network) option ", select " LAN setting " in " connection " option then, select " for LAN uses acting server ", and fill in the address and the port of said acting server.
Step 206 receives the Flash request of data information that browser sends;
Wherein, first address that comprises fault Flash in the said Flash request of data information;
Browser at first can be opened the original web page at fault Flash place during debugging, and can send Flash request of data information during the browser execution original web page and give acting server.
Wherein, also comprise the source resource of fault Flash and fault Flash, like data such as the picture of fault Flash needs in service, Voice & Videos.
Certainly, the data message of browse request can also comprise title, word content, picture etc., and the application does not do qualification to this.
Step 207, whether detect said Flash request of data information is first address of fault Flash;
If then execution in step 208; If not, execution in step 211 then.
The address that comprises data in the Flash request of data information that browser sends, thus acting server whether can detect said address be first address of fault Flash.
As above in the example, in acting server, be provided with first address of fault Flash, said address is m.cn/open.se/data.flash, and whether the address that can detect data in the request of data this moment is first address of fault Flash.If, follow-up can execution in step 208, if not, follow-up can execution in step 209.
Step 208, with first map addresses of fault Flash to second address of target Flash;
If the address that detects in the request of data is first address of fault Flash, promptly the data of request are fault Flash, then can be with first map addresses of fault Flash to second address of target Flash.
For example, can first address of fault Flash: m.cn/open.se/data.flash be mapped to second address of target Flash: on the http://open.se.x.cn/v2/data.flash [P].
Step 209 is obtained target Flash on second address of said target Flash;
Acting server can be in second address of said target Flash then:
On the http://open.se.x.cn/v2/data.flash [P], obtain said target Flash.
For example, give the second address transmission data request of target Flash, obtain target Flash then.Also possibility target Flash and acting server just can directly call said target Flash on a test machine.The application does not do qualification for the method for obtaining target Flash.
Step 210 sends to browser with said target Flash.
After getting access to target Flash, can said target Flash be sent to browser, let the said target Flash of browser execution.
Step 211 is sent the server of said Flash request of data information to fault Flash place;
If the address that detects in the request of data is not first address of fault Flash; Promptly the data of request are not fault Flash; The acting server server that need arrive fault Flash place obtains corresponding data so, therefore can send the server that Flash request of data information belongs to fault Flash.
Wherein, can comprise the source resource addresses of fault Flash in the said request of data, promptly the data of request are the source resource of fault Flash, like the fault Flash picture that will show in service, the audio or video of broadcast, data such as the literal of appearance.
Certainly, other data in also can requests for page showing, title for example, data such as website picture.
Step 212, the source resource of the fault Flash that the server at reception fault Flash place sends;
Can receive the source resource of the fault Flash that the server at fault Flash place sends then, like the fault Flash picture that will show in service, the audio or video of broadcast, data such as the literal of appearance.Certainly, if be the address of web page title in the request of data, what then receive should be web page title.
Step 213 sends to browser with the source resource of said fault Flash.
After the above-mentioned source resource that gets access to fault Flash, can send in the browser, browser just can be in target Flash Shows Picture, audio plays, displaying video.
Wherein, to browser, first address of the fault Flash that browser sends and the source resource addresses of fault Flash are under the same domain name, therefore do not have the problem of homology restriction.
But when the data of browse request were fault Flash, acting server returns was target Flash and this incident of hiding, so the Flash that moves of browser and not knowing and request is different.
Though that therefore move in the browser is target Flash, can not produce the problem of homology restriction, target Flash can move in browser.
Preferably, described method also comprises:
If target Flash is the Flash that adds output journal, then export and check the daily record of the Flash that adds daily record output, to confirm the running status of the Flash that said adding daily record is exported.
Move in browser if add the Flash of output journal, then can export corresponding daily record, check running status then with the Flash that confirms said adding daily record output.Wherein, can check whether the operation of the Flash that adds daily record output is normal, the there existing problems.
Can also analyze when adopting detached process Flash in the browser according to said daily record, the there possibly have problems, and where can be optimized, and further improves the performance of said detached process.
If target Flash is the Flash of locating and displaying, then debug terminal checks whether the locating and displaying of target Flash in the browser is normal.
If the Flash of locating and displaying moves in browser, just can check directly whether the locating and displaying of target Flash in the browser is normal, for example whether the picture located of position location is exaggerated etc.Can know that then whether normal Flash etc. in detached process.
With reference to Fig. 3, provided the debug system structural drawing of Flash in the said a kind of browser of the application embodiment.
With reference to Fig. 4, provided the structural drawing of acting server in the debug system of the said a kind of browser Flash of the application embodiment.
Accordingly, the application also provides the debug system of Flash in a kind of browser, it is characterized in that, comprising: the server 2 and the browser 3 at debug terminal 1, fault Flash place, wherein,
Said debug terminal is used to build acting server, and in acting server, sets up the mapping relations of first address and second address.
Said debug terminal 1 comprises acting server 14, and said acting server 11 comprises:
First receives submodule 141, is used to receive the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information;
Mapping submodule 142 is used for second address of first map addresses to target Flash;
First sends submodule 143, is used to send target Flash to browser.
Preferably, said first sends submodule 143, comprising:
Acquiring unit 1431 is used on said second address, obtaining target Flash;
Transmitting element 1432 is used for said target Flash is sent to browser.
Preferably, also comprise in the said Flash requesting data information: the address of the source data of fault Flash, said acting server 14 also comprises:
Second sends submodule 144, is used to send the server of said Flash request of data information to fault Flash place;
Second receives submodule 145, is used to receive the source data of the fault Flash that the server at fault Flash place sends;
The 3rd sends submodule 146, is used for the source data of said fault Flash is sent to browser.
Preferably, said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preferably, if target Flash is for adding the Flash of output journal, said debug terminal 1 also comprises:
Output module 15 is used to export and check the daily record of the Flash that adds daily record output, to confirm the running status of the Flash that said adding daily record is exported.
Preferably, if target Flash is for adding the Flash of output journal, said debug terminal 1 also comprises:
Output module 15 is used for checking whether the locating and displaying of browser target Flash is normal.
Preferably, said debug terminal 1 also comprises:
Download module 11 is used for the fault Flash that downloads is in advance carried out decompiling;
Add module 12, be used for adding printout in the in-problem position of fault Flash,
Generation module 13 is used to generate the Flash and the preservation that add daily record output.
Preferably, said browser 3 comprises configuration submodule 31,
Said configuration submodule 31 is used for Service-Port is configured to acting server.
Accordingly, the application also provides a kind of server, comprising:
First receives submodule, is used to receive the Flash request of data information that browser sends, and wherein, comprises first address of fault Flash in the said Flash request of data information;
Mapping submodule is used for second address of first map addresses to target Flash;
First sends submodule, is used to send target Flash to browser.
Preferably, said first sends submodule, comprising:
Acquiring unit is used on said second address, obtaining target Flash;
Transmitting element is used to send said target Flash and sends to browser.
Preferably, also comprise the address of the source data of fault Flash in the said Flash requesting data information, said acting server also comprises:
Second sends submodule, is used to send the server of said Flash request of data information to fault Flash place;
Second receives submodule, is used for the source data of the fault Flash that the server at fault Flash place sends;
The 3rd sends submodule, is used for the source data of said fault Flash is sent to browser.
Said target Flash comprises: add the Flash of output journal and the Flash of locating and displaying.
Preferably, the mapping relations that comprise first address and second address in the said acting server.
Wherein, the acting server basically identical in said acting server and the browser in the debug system of Flash repeats no more here.
For system embodiment, because it is similar basically with method embodiment, so description is fairly simple, relevant part gets final product referring to the part explanation of method embodiment.
Each embodiment in this instructions all adopts the mode of going forward one by one to describe, and what each embodiment stressed all is and the difference of other embodiment that identical similar part is mutually referring to getting final product between each embodiment.
The application can describe in the general context of the computer executable instructions of being carried out by computing machine, for example program module.Usually, program module comprises the routine carrying out particular task or realize particular abstract, program, object, assembly, data structure or the like.Also can in DCE, put into practice the application, in these DCEs, by through communication network connected teleprocessing equipment execute the task.In DCE, program module can be arranged in this locality and the remote computer storage medium that comprises memory device.
At last; Also need to prove; In this article; Relational terms such as first and second grades only is used for an entity or operation are made a distinction with another entity or operation, and not necessarily requires or hint relation or the order that has any this reality between these entities or the operation.And; Term " comprises ", " comprising " or its any other variant are intended to contain comprising of nonexcludability; Thereby make and comprise that process, method, commodity or the equipment of a series of key elements not only comprise those key elements; But also comprise other key elements of clearly not listing, or also be included as this process, method, commodity or equipment intrinsic key element.Under the situation that do not having much more more restrictions, the key element that limits by statement " comprising ... ", and be not precluded within process, method, commodity or the equipment that comprises said key element and also have other identical element.
More than to debug system and a kind of acting server of Flash in the adjustment method of Flash in a kind of browser that the application provided, a kind of browser; Carried out detailed introduction; Used concrete example among this paper the application's principle and embodiment are set forth, the explanation of above embodiment just is used to help to understand the application's method and core concept thereof; Simultaneously, for one of ordinary skill in the art, according to the application's thought, the part that on embodiment and range of application, all can change, in sum, this description should not be construed as the restriction to the application.