CN103218395A - Page compression method and system - Google Patents

Page compression method and system Download PDF

Info

Publication number
CN103218395A
CN103218395A CN2013100674724A CN201310067472A CN103218395A CN 103218395 A CN103218395 A CN 103218395A CN 2013100674724 A CN2013100674724 A CN 2013100674724A CN 201310067472 A CN201310067472 A CN 201310067472A CN 103218395 A CN103218395 A CN 103218395A
Authority
CN
China
Prior art keywords
page
compression
compressed
file
pagefile
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
CN2013100674724A
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.)
Xingyun Rongchuang Beijing Technology Co Ltd
Original Assignee
Nebula Creation (beijing) Information Technology 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 Nebula Creation (beijing) Information Technology Co Ltd filed Critical Nebula Creation (beijing) Information Technology Co Ltd
Priority to CN2013100674724A priority Critical patent/CN103218395A/en
Publication of CN103218395A publication Critical patent/CN103218395A/en
Pending legal-status Critical Current

Links

Images

Abstract

The invention provides a page compression method and a page compression system. The method comprises the steps of agenting a web request of a user browser through a web agent system and obtaining an uncompressed page from a website server; compressing the uncompressed page in the web agent system; and providing the user browser with the compressed page. The page compression system comprises the web agent system; the web agent system comprises a web agent device and a page compression device; the web agent device agents the web request of the user browser, obtains the page from the website server and provides the user browser with the compressed page; and the page compression device compresses the page. According to the page compression method and the page compression system, the page is compressed on the web agent system; when a user visits the page, the page data are automatically compressed and cached in the web agent system without being modified by the original website server; and through page compression, the downloading speed of the page can be improved, so that the page is opened in the browser faster and the user enjoys better online experience.

Description

Page compression method and system
Technical field
The present invention relates to computer network field, relate in particular to page compression method and system.
Background technology
The data that Webpage file that transmits in the computer network and script file have a lot of redundancies, for example invalid space and annotation data, removing these data can not influence the page and normally show.Simultaneously, by compressed page, can improve the speed of download of the page, thereby in browser, open the page quickly, allow user's experience of better being surfed the Net.
The page compression method of prior art is on Website server the page to be compressed, and offers the user then and browses.It has following shortcoming this method: the page after the page compression does not have form clearly, is difficult to safeguard; If both preserved the pagefile of unpressed unprocessed form, preserve the pagefile of compressed format again, there is the inconsistent situation of version so easily, also be difficult to safeguard.
Summary of the invention
Technical matters to be solved by this invention is the above-mentioned shortcoming that overcomes prior art, and a kind of page compression method and system are provided.The present invention need be on Website server so any modification, pagefile can keep original form, page data is compressed automatically when page data is flowed through the web agency plant of page compressibility of the present invention.
A kind of page compression method is provided according to a first aspect of the invention, has comprised step: by with the web request of the web agency plant proxy user browser of user browser and Website server coupling, obtain not compressed page from Website server; In the described not compressed page of web agency plant place compression; By the compressed page of web agency plant after user browser provides compression.
Alternatively, the web of described web agency plant proxy user browser asks clearly, obtain not from Website server that the step of compressed page comprises step: after the accession page request that receives from user browser, the request that the web agency plant is sent here according to user browser is sent the accession page request to Website server that will accession page, and Website server is delivered to the web agency plant according to the request of web agency plant with the not compressed page of ask visit.
Alternatively, the step in the described not compressed page of web agency plant place compression comprises step: first step S310: the not compressed page file cache that will obtain from Website server is buffer; The second step S320: after buffer memory is finished, generate the inotify message that pagefile is written into; Third step S330: after page compression controller listens to the inotify message that pagefile is written into, judge whether and need the not compressed page file of buffer memory be compressed, not compressed page file to buffer memory compresses if desired, then carries out following the 4th step S340; If do not need the not compressed page of buffer memory is compressed, then carry out described step by the compressed page of web agency plant after user browser provides compression; The 4th step S340: page compression controller is created compression duty message, and this message is passed to page compression engine; The 5th step S350: page compression controller is put into the compressed file directory tree with the not compressed page file of buffer memory, and the file path of the not compressed page file of this buffer memory is added the compression duty formation; The 6th step S360: page compression engine is obtained compression duty queue file and is compressed processing; The 7th step S370: cover the not compressed page file of buffer memory with the pagefile after the compression, produce the inotify message that file is capped.Step by the compressed page of web agency plant after user browser provides compression comprises pagefile and the pagefile of reading after compressing after user browser provides compression from buffer.
Alternatively, whether the not compressed page file of monitoring buffer memory is new pagefile with the not compressed page file of judging buffer memory, if the not compressed page file of buffer memory is new pagefile, then needs the not compressed page file of buffer memory is compressed; If the not compressed page file of buffer memory is not new pagefile, do not need the not compressed page file of buffer memory is compressed; Described new pagefile comprises to be created pagefile or upgrades pagefile.
Alternatively, judge by compressed page file modifying time mark not whether the not compressed page file of buffer memory is new pagefile; If the not compressed page file modifying time mark of buffer memory is new time mark, the not compressed page file of then judging buffer memory is new pagefile, if the not compressed page file modifying time mark of buffer memory is not new time mark, judge that then the not compressed page file of buffer memory is not new pagefile.
Alternatively, do not write down not compressed page file modifying time mark during the compressed page file at buffer memory; After replacing not the compressed page file with the pagefile after the compression, the modification time mark of compression pagefile afterwards is with compressed page file modifying time mark is not identical.
Alternatively, describedly compress processing and further comprise step: resolve the file layout of described new pagefile, do not influence the data of the normal redundancy that shows of the page in the deletion page data, and optimize data layout; The data of described redundancy comprise invalid space and/or note.
Alternatively, describedly compress processing and further comprise and use multithreading that file is compressed.
Alternatively, after covering the not compressed page file of buffer memory, the compressed page file of buffer memory is put into the file directory of having compressed set with the pagefile after the compression.
A kind of page compressibility is provided according to a second aspect of the invention, page compressibility comprises the web agency plant, described web agency plant is coupled with Website server with user browser respectively or links to each other, the web agency plant comprises: the web agent apparatus, the web request of proxy user browser obtains the page from Website server (130); Page compression set compresses the described page; Wherein web agent apparatus (122) also is used for the page after user browser provides compression.
Alternatively, described page compression set comprises buffer, page compression controller and page compression engine, and the described page is compressed page not.Buffer is used for buffer memory from the not compressed page file of Website server (130) acquisition or by the pagefile after the compression of page compression engine.Page compression controller is used to monitor the not compressed page file of buffer memory to judge whether and need the not compressed page file of buffer memory be compressed; If the not compressed page file of buffer memory is new pagefile, then need the not compressed page file of buffer memory is compressed, page compression controller is created compression duty message, compression duty message is passed to page compression engine, and compression duty is put in the compression duty formation; If the not compressed page file of buffer memory is not new pagefile, then do not need the not compressed page file of buffer memory is compressed, page compression controller is not created compression duty message; Described new pagefile comprises to be created pagefile or upgrades pagefile.Page compression engine is used for after receiving compression duty message, obtains compression duty queue file and compress described new pagefile also to cover the new pagefile of buffer memory with the pagefile after the compression.After covering the new pagefile of buffer memory with the pagefile after the compression, the web agent apparatus after buffer is read described compression pagefile and provide pagefile after compressing to user browser; If page compression controller judges that the not compressed page file of buffer memory is not new pagefile, then page compression engine is not compressed the not compressed page file of buffer memory, and the web proxy device is directly read pagefile and the pagefile after user browser provides compression after the compression corresponding with the not compressed page file of this buffer memory from buffer.
Alternatively, page compression controller judges by the not compressed page file modifying time mark of buffer memory whether the not compressed page file of buffer memory is new pagefile; If page compression controller judges that the not compressed page file modifying time mark of buffer memory is new time mark, then the not compressed page file of buffer memory is new pagefile; If the not compressed page file modifying time mark of buffer memory is not new time mark, then the not compressed page file of buffer memory is not new pagefile; Wherein do not write down not compressed page file modifying time mark during the compressed page file at buffer memory, replace not after the compressed page file with the pagefile after the compression, the modification time mark of the pagefile after the compression is with compressed page file modifying time mark is not identical.
Alternatively, described page compression engine comprises: file layout, the deletion page data that is used for resolving described new pagefile do not influence the data of the normal redundancy that shows of the page and optimizes the device of data layout, and the data of described redundancy comprise invalid space and/or note.
Alternatively, the web agency plant uses the change notification inotify that adopts file system, after the pagefile that Website server obtains, generates the inotify message that pagefile is written at buffer memory; After having covered the not compressed page file of buffer memory, compressed file produces the inotify message that file is capped; Page compression controller judges whether and need the not compressed page file of buffer memory be compressed after listening to the inotify message that pagefile is written into.
Alternatively, adopt gzip compression protocol or deflate compression protocol to compress.
Alternatively, the page that obtains from Website server (130) comprise the html page at least, call the js file the page, call the page of css file one or more.
The present invention has following advantage: the present invention's data stream to the page on the web agency plant is compressed, and page data is compressed at web agency plant place and buffer memory automatically when user to access pages, does not need former station to make any modification; Support is compressed html, js, css pagefile, supports gzip compression and deflate compression; Preserve packed data by caching mechanism, guarantee same page repeated compression not; By compressed page, can improve the speed of download of the page, thereby in browser, open the page quickly, allow user's experience of better being surfed the Net
Description of drawings
It should be noted that the accompanying drawing in describing below only schematically shows some embodiment, does not comprise all possible embodiment.
Fig. 1 shows the synoptic diagram of network communicating system 100 according to an embodiment of the invention;
Fig. 2 shows the schematic diagram of web agency plant 120 according to an embodiment of the invention;
Fig. 3 shows the synoptic diagram of page compression according to an embodiment of the invention;
Fig. 4 shows the schematic flow diagram of page compression method according to an embodiment of the invention;
Fig. 5 shows the working timing figure that according to an embodiment of the invention page is compressed;
Fig. 6 shows the schematic flow diagram of compressed page according to an embodiment of the invention.
Embodiment
Describe the technical scheme of exemplary embodiment of the present invention in detail below in conjunction with accompanying drawing.Obviously, described embodiment is a part of embodiment of the present invention, rather than whole embodiment.Described embodiment only is used to illustrate, rather than limitation of the scope of the invention.Based on embodiments of the invention, those of ordinary skills belong to the scope of protection of the invention not making the every other embodiment that is obtained under the creative work prerequisite.
Fig. 1 shows the synoptic diagram of network communicating system 100 according to an embodiment of the invention, and the annexation of web agency plant 120 in network according to an embodiment of the invention has been shown in this network communicating system 100.As shown in Figure 1, network communicating system 100 comprises user browser 110, web agency plant 120 and Website server 130, web agency plant 120 be arranged between user browser 110 and the Website server 130 and respectively with family browser 110 with Website server 130 couplings or link to each other.To Website server 130 requests for page, promptly the web of web agency plant 120 proxy user browsers 110 asks user browser 110 by web agency plant 120.When web agency plant 120 after Website server 130 obtains the pages, it does not directly return to the page user browser 110, but the pagefile after user browser 110 provides compression.120 places compress the page at the web agency plant, remove such as invalid space and the redundant data the note, i.e. the compression of the page is carried out at web agency plant 120 places.After having finished page compression, the pagefile after web agency plant 120 will compress offers user browser 110.Though, for simplicity, only show among Fig. 1 by a user browser 110, a web agency plant 120 and the network communicating system 100 that Website server 130 constitutes, but network communicating system of the present invention can comprise a plurality of user browsers 110, a plurality of web agency plant 120 and a plurality of Website server 130.
In the prior art, subscriber computer is usually directly to the Website server requests for page.Even system has page compression function, also just the page is compressed at the Website server place, the pagefile after directly will compressing then offers the browser of subscriber computer, and does not introduce " intermediary " system or process.On Website server the page is compressed, the page that obtains is not often asked clear form, is difficult to safeguard.If both preserved the pagefile of unpressed unprocessed form, preserve the pagefile of compressed format again, there is the inconsistent situation of version so easily, also be difficult to safeguard.And adopt method of the present invention, and need on Website server 130, not make any modification or compression to the page, the page can keep original form, is compressed automatically when it flows through web agency plant 120.
In the present invention, can the various pages from Website server 130 be compressed, for example the html page, call the js file the page, call the page of css file, or the like.
In the present invention, the page compressed for example comprise that deletion does not influence the data of the normal redundancy that shows of the page, the data of described redundancy for example comprise invalid space and/or note.Compress mode of the present invention not only comprises so simple js code or the css code compaction of note and/or invalid space in the deletion page, also comprises the complicated compression of adopting gzip compression protocol or deflate compression protocol.
Fig. 2 is the structural drawing of the web agency plant 120 of an example embodiment of the present invention.As shown in Figure 2, web agency plant 120 comprises web agent apparatus 122 and page compression set 126.Web proxy device 122 is communicated by letter with Website server 130 with user browser 110.The web request of web agent apparatus 122 proxy user browsers obtains the page from Website server 130.For example, web agent apparatus 122 is after the accession page request of receiving from user browser, and the request of sending here according to user browser is sent the accession page request to Website server 130 that will accession page, obtains the pages from Website server 130.In other words, web agent apparatus 122 is known the user's web request from user browser 110 earlier, replaces user browser 110 to obtain the page to Website server 130 requests for page and from Website server 130 then.Should be noted in the discussion above that in the present invention Website server 130 does not need page data is made any compression and modification, the page that web agent apparatus 122 obtains keeps original form.Page compression set 126 is used in the described not compressed page of described web agency plant 120 places compression.
According to one example embodiment, as shown in Figure 3, page compression set 126 comprises buffer 122, page compression controller 127 and page compression engine 128.
Buffer 122 is used for buffer memory from the pagefile of Website server (130) acquisition or by the pagefile after the compression of page compression engine.
As an example embodiment, the present invention adopts the change notification mechanism inotify of file system.For example, after the pagefile that Website server (130) obtains, generate the inotify message that pagefile is written at buffer memory; After having covered the not compressed page file of buffer memory, compressed file produces the inotify message that file is capped.
Page compression controller 127 is used to monitor the not compressed page file of buffer memory to judge whether and need the not compressed page file of buffer memory be compressed; If the not compressed page file of buffer memory is new pagefile, then need the not compressed page file of buffer memory is compressed, page compression controller is created compression duty message, compression duty message is passed to page compression engine, and compression duty is put in the compression duty formation; If the not compressed page file of buffer memory is not new pagefile, then do not need the not compressed page file of buffer memory is compressed, page compression controller is not created compression duty message, in the case, page compression engine is not compressed pagefile, and the web proxy device is directly read pagefile and the pagefile after user browser provides compression after the compression corresponding with the not compressed page file of this buffer memory from buffer.
New pagefile comprises to be created pagefile or upgrades pagefile.
Page compression controller 127 can judge whether and need the not compressed page file of buffer memory be compressed after listen to the inotify message that pagefile is written into.
Page compression controller 127 can judge whether the not compressed page file of buffer memory is new pagefile by the not compressed page file modifying time mark of buffer memory.According to one embodiment of present invention, do not write down not compressed page file modifying time mark during the compressed page file at buffer memory, wherein, after the described not compressed page file of compression, replace not compressed page file with the pagefile after the compression, but the modification time mark of the pagefile after the compression is with compressed page file modifying time mark is not identical.If page compression controller judges that the not compressed page file modifying time mark of buffer memory is new time mark, then the not compressed page file of buffer memory is new pagefile, if the not compressed page file modifying time mark of buffer memory is not new time mark, then the not compressed page file of buffer memory is not new pagefile.
Page compression engine 128 is compressed described new pagefile and is upgraded buffer with the pagefile after the compression after receiving compression duty message.As one embodiment of the present of invention, page compression engine comprises: file layout, the deletion page data that is used for resolving described new pagefile do not influence the data of the normal redundancy that shows of the page and optimizes the device of data layout.
The compression of being undertaken by page compression engine can be the various compressions of finishing at the Website server place in the prior art, comprises the js code or the css code compaction in gzip compression, deflate compression and deletion note and/or invalid space, or the like.When compression finishes, the pagefile after page compression engine 126 will be compressed writes buffer, promptly upgrades buffer with the pagefile after the compression, in buffer buffer memory the pagefile after the compression.
According to one embodiment of present invention, after replacing not the compressed page file with the pagefile after the compression, web agent apparatus 122 after buffer is read compression pagefile and provide the page after compressing to user browser 110.
According to embodiments of the invention, after web proxy device 122 obtains the page, pagefile is carried out buffer memory by the buffer that is coupled with it.Buffer also is coupled with page compression controller, little page compression controller is created compression duty message and is sent compression duty message to page compression engine when page compression controller has monitored at buffer place buffer memory the new page, and page compression engine is compressed this new pagefile after receiving compression duty message.
Fig. 4 shows the schematic flow diagram of page compression method according to an embodiment of the invention.At step S200, by web agency plant 120, the web of proxy user browser request obtains the page from Website server 130.At step S300, at the page of web agency plant 120 places compression from Website server 130 acquisitions.At step S400, by the page of web agency plant 120 after user browser 110 provides compression.
Step S200 comprises step: after the accession page request that receives from user browser, web agency plant 120 sends the accession page request according to the request that user browser is sent here to Website server, and Website server is delivered to web agency plant 120 according to the request of web agency plant 120 with the page of ask visit.
Alternatively, page compression method can also comprise the buffer memory step according to an embodiment of the invention, i.e. pagefile after described web agency plant 120 places buffer memory compression.Preserve compressed page by caching mechanism, can guarantee same page repeated compression not.
Fig. 6 shows the exemplary method in web agency plant 120 place's compressed page.As example embodiment, Fig. 6 shows substep and the described step S400 that described step S300 comprises.As shown in Figure 6, described step S300 in web agency plant 120 place's compressed page comprises:
Step S310: the not compressed page file cache that will obtain from Website server 130 is buffer;
Step S320: after buffer memory is finished, generate buffer memory change message, for example generate the inotify message that pagefile is written into.
Step S330: after page compression controller listens to the inotify message that pagefile is written into, judge whether and need the not compressed page file of buffer memory be compressed, not compressed page file to buffer memory compresses if desired, then carry out following steps S340, if do not need the not compressed page of buffer memory is compressed, then carry out described step S400;
Step S340: page compression controller is created compression duty message, and this message is passed to page compression engine;
Step S350: page compression controller is put into the compressed file directory tree with the not compressed page file of buffer memory, and the file path of the not compressed page file of this buffer memory is added the compression duty formation.Owing to have a large amount of buffer memory pages and will compress, so compression duty is put in the compression duty formation, task queue can guarantee that task carries out successively.
Step S360: page compression engine 128 is obtained compression duty queue file and is compressed processing, for example can use multithreading that file is compressed.
Step S370: cover the not compressed page file of buffer memory with the pagefile after the compression, produce the inotify message that file is capped.
Step S330 comprises step: whether the not compressed page file of monitoring buffer memory is new pagefile with the not compressed page file of judging buffer memory, if the not compressed page file of buffer memory is new pagefile, then need the not compressed page file of buffer memory is compressed; If the not compressed page file of buffer memory is not new pagefile, do not need the not compressed page file of buffer memory is compressed.
As an exemplary embodiment of the present invention, do not write down not compressed page file modifying time mark during the compressed page file at buffer memory, after the described not compressed page file of compression, replace not compressed page file with the pagefile after the compression, but the modification time mark of pagefile after the compression compressed page file modifying time mark is not identical with it.Page compression controller judges by compressed page file modifying time mark not whether the not compressed page file of buffer memory is new pagefile; If the not compressed page file modifying time mark of buffer memory is new time mark, the not compressed page file of then judging buffer memory is new pagefile, if the not compressed page file modifying time mark of buffer memory is not new time mark, judge that then the not compressed page file of buffer memory is not new pagefile.
According to one embodiment of present invention,, describedly compress processing and further comprise step: resolve the file layout of described new pagefile, do not influence the data of the normal redundancy that shows of the page in the deletion page data, and optimize data layout at step S360; The data of described redundancy comprise invalid space and/or note.
Selectively, after step S370, the compressed page file of buffer memory is put into the file directory tree that has compressed.
Described step 400 comprises reads compression pagefile and the pagefile after user browser 110 provides compression afterwards from buffer.
Should be noted that, in each parts of web agency plant of the present invention, according to its function that will realize and wherein parts have been carried out logical partitioning, but, the present invention is not subject to this, can repartition or make up each parts as required, for example, can be single parts with some unit constructions, perhaps some parts further can be decomposed into more subassembly.Being positioned at term " " before the parts or " one " does not get rid of and has a plurality of such parts.
Each parts embodiment of the present invention can realize with hardware, perhaps realizes with the software module of moving on one or more processor, and perhaps the combination with them realizes.It will be understood by those of skill in the art that some or all some or the repertoire of parts that can use microprocessor, digital signal processor (DSP) or field programmable gate array (FPGA) to wait in practice to realize according in the web agency plant of the embodiment of the invention.The present invention can also be embodied as part or all system or the device program (for example, computer program and computer program) that is used to carry out method as described herein.
Should also be noted that; more than the description of embodiments of the invention only is used to illustrate technical scheme of the present invention; rather than limitation of the scope of the invention; the present invention is not limited to disclosed these embodiment; those skilled in the art can make amendment to the technical scheme that aforementioned each embodiment put down in writing; perhaps part technical characterictic wherein is equal to replacement, and these modifications or replace and all should fall into protection scope of the present invention.

Claims (16)

1. page compression method comprises step:
By with the web request of web agency plant (120) the proxy user browser of user browser (110) and Website server (130) coupling, obtain not compressed page from Website server (130);
Locate to compress described not compressed page at web agency plant (120);
By the compressed page of web agency plant (120) after user browser (110) provides compression.
2. page compression method according to claim 1, it is characterized in that, the web request of described web agency plant (120) proxy user browser, obtaining not from Website server (130), the step of compressed page comprises step: after the accession page request that receives from user browser, the request that web agency plant (120) is sent here according to user browser is sent the accession page request to Website server that will accession page, and Website server is delivered to web agency plant (120) according to the request of web agency plant (120) with the not compressed page of ask visit.
3. page compression method according to claim 1, the step that it is characterized in that locating to compress at web agency plant (120) described not compressed page comprises step:
First step (S310): the not compressed page file cache that will obtain from Website server (130) is buffer;
Second step (S320): after buffer memory is finished, generate the inotify message that pagefile is written into;
Third step (S330): after page compression controller listens to the inotify message that pagefile is written into, judge whether and need the not compressed page file of buffer memory be compressed, not compressed page file to buffer memory compresses if desired, then carries out following the 4th step (S340); If do not need the not compressed page of buffer memory is compressed, then carry out described step by the compressed page of web agency plant (120) after user browser (110) provides compression;
The 4th step (S340): page compression controller is created compression duty message, and this message is passed to page compression engine;
The 5th step (S350): page compression controller is put into the compressed file directory tree with the not compressed page file of buffer memory, and the file path of the not compressed page file of this buffer memory is added the compression duty formation;
The 6th step (S360): page compression engine is obtained compression duty queue file and is compressed processing;
The 7th step (S370): cover the not compressed page file of buffer memory with the pagefile after the compression, produce the inotify message that file is capped;
Its feature also is: described step by the compressed page of web agency plant (120) after user browser (110) provides compression comprises reads compression pagefile and the pagefile after user browser (110) provides compression afterwards from buffer.
4. page compression method according to claim 3, it is characterized in that: the judging whether to compress the not compressed page file of buffer memory of third step (S330) comprises step: whether the not compressed page file of monitoring buffer memory is new pagefile with the not compressed page file of judging buffer memory, if the not compressed page file of buffer memory is new pagefile, then need the not compressed page file of buffer memory is compressed; If the not compressed page file of buffer memory is not new pagefile, do not need the not compressed page file of buffer memory is compressed; Described new pagefile comprises to be created pagefile or upgrades pagefile.
5. page compression method according to claim 4 is characterized in that: whether the described not compressed page file of judging buffer memory is that new pagefile comprises by compressed page file modifying time mark not and judges whether the not compressed page file of buffer memory is new pagefile; If the not compressed page file modifying time mark of buffer memory is new time mark, the not compressed page file of then judging buffer memory is new pagefile, if the not compressed page file modifying time mark of buffer memory is not new time mark, judge that then the not compressed page file of buffer memory is not new pagefile.
6. page compression method according to claim 5 is characterized in that: do not write down not compressed page file modifying time mark when page compression and file at buffer memory; After replacing not the compressed page file with the pagefile after the compression, the modification time mark of compression pagefile afterwards is with compressed page file modifying time mark is not identical.
7. according to the described page compression method of arbitrary claim among the claim 3-6, it is characterized in that: the processing of compressing of described the 6th step (S360) further comprises step: the file layout of resolving described new pagefile, do not influence the data of the normal redundancy that shows of the page in the deletion page data, and optimize data layout; The data of described redundancy comprise invalid space and/or note.
8. according to the described page compression method of arbitrary claim among the claim 3-6, it is characterized in that: the processing of compressing of described the 6th step (S360) comprises that further step comprises that the use multithreading compresses file.
9. according to the described page compression method of arbitrary claim among the claim 3-6, it is characterized in that: in the 7th step (S370) afterwards, the compressed page file of buffer memory is put into the file directory tree that has compressed.
10. a page compressibility is characterized in that comprising web agency plant (120), and described web agency plant (120) is coupled with Website server (130) with user browser (110) respectively or links to each other, and web agency plant (120) comprising:
Web agent apparatus (122), the web request of proxy user browser obtains the page from Website server (130);
Page compression set (126) compresses the described page;
Its feature is that also web agent apparatus (122) also is used for the page after user browser (110) provides compression.
11. page compressibility according to claim 10 is characterized in that described page compression set (126) comprises buffer (124), page compression controller (127) and page compression engine (128), the described page is compressed page not, wherein:
Buffer (124) is used for buffer memory from the not compressed page file of Website server (130) acquisition or by the pagefile after the compression of page compression engine;
Page compression controller is used to monitor the not compressed page file of buffer memory to judge whether and need the not compressed page file of buffer memory be compressed; If the not compressed page file of buffer memory is new pagefile, then need the not compressed page file of buffer memory is compressed, page compression controller is created compression duty message, compression duty message is passed to page compression engine, and compression duty is put in the compression duty formation; If the not compressed page file of buffer memory is not new pagefile, then do not need the not compressed page file of buffer memory is compressed, page compression controller is not created compression duty message; Described new pagefile comprises to be created pagefile or upgrades pagefile;
Page compression engine is used for after receiving compression duty message, obtains compression duty queue file and compress described new pagefile also to cover the new pagefile of buffer memory with the pagefile after the compression;
Its feature also is after covering the new pagefile of buffer memory with the pagefile after the compression, web agent apparatus (122) after buffer is read described compression pagefile and provide pagefile after compressing to user browser (110); If page compression controller judges that the not compressed page file of buffer memory is not new pagefile, page compression engine is not compressed the not compressed page file of buffer memory, and the web proxy device is directly read pagefile and the pagefile after user browser provides compression after the compression corresponding with the not compressed page file of this buffer memory from buffer.
12. page compressibility according to claim 11 is characterized in that:
Page compression controller (127) judges by the not compressed page file modifying time mark of buffer memory whether the not compressed page file of buffer memory is new pagefile; If page compression controller judges that the not compressed page file modifying time mark of buffer memory is new time mark, then the not compressed page file of buffer memory is new pagefile; If the not compressed page file modifying time mark of buffer memory is not new time mark, then the not compressed page file of buffer memory is not new pagefile; Wherein do not write down not compressed page file modifying time mark during the compressed page file at buffer memory, replace not after the compressed page file with the pagefile after the compression, the modification time mark of the pagefile after the compression is with compressed page file modifying time mark is not identical.
13. page compressibility according to claim 11 is characterized in that:
Described page compression engine comprises: file layout, the deletion page data that is used for resolving described new pagefile do not influence the data of the normal redundancy that shows of the page and optimizes the device of data layout, and the data of described redundancy comprise invalid space and/or note.
14. according to the described page compressibility of arbitrary claim among the claim 10-13, it is characterized in that: web agency plant (120) uses the change notification inotify that adopts file system, after the pagefile that Website server (130) obtains, generate the inotify message that pagefile is written at buffer memory; After having covered the not compressed page file of buffer memory, compressed file produces the inotify message that file is capped; Page compression controller 127 judges whether and need the not compressed page file of buffer memory be compressed after listening to the inotify message that pagefile is written into.
15., it is characterized in that: adopt gzip compression protocol or deflate compression protocol to compress according to the described page compressibility of arbitrary claim among the claim 10-13.
16. according to the described page compressibility of arbitrary claim among the claim 10-13, it is characterized in that: the page that obtains from Website server (130) comprises the html page at least, call the page of js file, call the page of css file one or more.
CN2013100674724A 2013-03-04 2013-03-04 Page compression method and system Pending CN103218395A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2013100674724A CN103218395A (en) 2013-03-04 2013-03-04 Page compression method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2013100674724A CN103218395A (en) 2013-03-04 2013-03-04 Page compression method and system

Publications (1)

Publication Number Publication Date
CN103218395A true CN103218395A (en) 2013-07-24

Family

ID=48816182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2013100674724A Pending CN103218395A (en) 2013-03-04 2013-03-04 Page compression method and system

Country Status (1)

Country Link
CN (1) CN103218395A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103699846A (en) * 2013-12-25 2014-04-02 浪潮(北京)电子信息产业有限公司 Method and device for intercepting changed files in LINUX system
CN104199951A (en) * 2014-09-12 2014-12-10 百度在线网络技术(北京)有限公司 Webpage processing method and webpage processing device
CN105205080A (en) * 2014-06-26 2015-12-30 阿里巴巴集团控股有限公司 Redundant file clearing method, device and system
CN105205151A (en) * 2015-09-24 2015-12-30 福建天晴数码有限公司 Method and system for saving browser page flow at mobile terminal
CN106055575A (en) * 2016-05-19 2016-10-26 天脉聚源(北京)传媒科技有限公司 Method and device for optimized loading of website page
CN107592553A (en) * 2017-09-01 2018-01-16 清华大学 A kind of compression of images agency balance processing method and processing device
CN110471593A (en) * 2019-07-31 2019-11-19 成都摹客科技有限公司 The method, apparatus, system and storage medium of figure are cut based on web terminal compression
CN111556170A (en) * 2020-05-25 2020-08-18 郑州大学 Method for realizing rapid transmission of B3dm model network
CN111914529A (en) * 2020-08-12 2020-11-10 北京思图场景数据科技服务有限公司 Webpage process recording method and device
CN113721923A (en) * 2021-09-02 2021-11-30 北京天融信网络安全技术有限公司 Webpage code optimization method and device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050050172A1 (en) * 2003-09-03 2005-03-03 International Business Machines Corporation Transport and administration model for offline browsing
US20090063530A1 (en) * 2007-09-04 2009-03-05 Lg Telecom Ltd. System and method for mobile web service
CN101446983A (en) * 2009-01-12 2009-06-03 腾讯科技(深圳)有限公司 Method, system and equipment for realizing web page acquisition by mobile terminal
CN102185923A (en) * 2011-05-16 2011-09-14 广州市动景计算机科技有限公司 Webpage browsing method for mobile communication equipment terminal

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050050172A1 (en) * 2003-09-03 2005-03-03 International Business Machines Corporation Transport and administration model for offline browsing
US20090063530A1 (en) * 2007-09-04 2009-03-05 Lg Telecom Ltd. System and method for mobile web service
CN101446983A (en) * 2009-01-12 2009-06-03 腾讯科技(深圳)有限公司 Method, system and equipment for realizing web page acquisition by mobile terminal
CN102185923A (en) * 2011-05-16 2011-09-14 广州市动景计算机科技有限公司 Webpage browsing method for mobile communication equipment terminal

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
MATTHEW CROWLEY: "《IE8 & 9开发实战:基于下一代IE的应用开发》", 31 January 2012, 清华大学出版社 *
任桥伟: "《LINUX内核修炼之道》", 31 July 2010, 人民邮电出版社 *

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103699846A (en) * 2013-12-25 2014-04-02 浪潮(北京)电子信息产业有限公司 Method and device for intercepting changed files in LINUX system
CN105205080A (en) * 2014-06-26 2015-12-30 阿里巴巴集团控股有限公司 Redundant file clearing method, device and system
CN105205080B (en) * 2014-06-26 2019-08-20 阿里巴巴集团控股有限公司 Redundant file method for cleaning, device and system
CN104199951A (en) * 2014-09-12 2014-12-10 百度在线网络技术(北京)有限公司 Webpage processing method and webpage processing device
CN105205151B (en) * 2015-09-24 2019-07-16 福建天晴数码有限公司 The method and system of browser page flow are saved in mobile terminal
CN105205151A (en) * 2015-09-24 2015-12-30 福建天晴数码有限公司 Method and system for saving browser page flow at mobile terminal
CN106055575A (en) * 2016-05-19 2016-10-26 天脉聚源(北京)传媒科技有限公司 Method and device for optimized loading of website page
CN107592553A (en) * 2017-09-01 2018-01-16 清华大学 A kind of compression of images agency balance processing method and processing device
CN107592553B (en) * 2017-09-01 2020-06-12 清华大学 Image compression agent balance processing method and device
CN110471593A (en) * 2019-07-31 2019-11-19 成都摹客科技有限公司 The method, apparatus, system and storage medium of figure are cut based on web terminal compression
CN111556170A (en) * 2020-05-25 2020-08-18 郑州大学 Method for realizing rapid transmission of B3dm model network
CN111914529A (en) * 2020-08-12 2020-11-10 北京思图场景数据科技服务有限公司 Webpage process recording method and device
CN111914529B (en) * 2020-08-12 2024-03-29 北京思图场景数据科技服务有限公司 Webpage process recording method and device
CN113721923A (en) * 2021-09-02 2021-11-30 北京天融信网络安全技术有限公司 Webpage code optimization method and device, electronic equipment and storage medium
CN113721923B (en) * 2021-09-02 2023-10-13 北京天融信网络安全技术有限公司 Webpage code optimization method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN103218395A (en) Page compression method and system
US11153402B2 (en) Method and apparatus for automatically optimizing the loading of images in a cloud-based proxy service
CN103942225B (en) A kind of resource transfer method, client and the system of mixed type applications client
TWI449372B (en) Method and computer system for offline execution of web based applications
CN106789377B (en) Service parameter updating method of network element cluster
CN102185923A (en) Webpage browsing method for mobile communication equipment terminal
CN102917074B (en) A kind of method realizing server-side browser and server
CN102438045A (en) Method and system for pre-fetching web page, and method for accessing web page
CN101127783A (en) A website buffering method and device
CN102663062A (en) Method and device for processing invalid links in search result
CN105095280A (en) Caching method and apparatus for browser
CN103455478A (en) Webpage access accelerating method and device
CN111010364B (en) System for offline object-based storage and simulation of REST responses
CN103338249A (en) Cache method and device
CN107807937B (en) Website SEO processing method, device and system
CN103118082A (en) Method, device and system for embedding additional information
CN111796983A (en) System and method for monitoring abnormal transaction request of sportsbook
WO2012120658A1 (en) Method and device for recording and reproducing web operation
CN104767653A (en) Method and device for monitoring network interfaces
CN102932469A (en) Method for achieving client browser and client browser
CN108897543A (en) Interim compiling system, method, apparatus and the storage medium of version
CN109145236A (en) Page file processing method, apparatus and system
CN111858255A (en) User behavior acquisition method based on screenshot and related equipment
CN104361007B (en) The processing method of browser and its collection
CN106933569B (en) A kind of webpage method for refreshing and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C41 Transfer of patent application or patent right or utility model
TA01 Transfer of patent application right

Effective date of registration: 20151102

Address after: 100080, room 10, building 1, 3 Haidian Avenue, Beijing,, Haidian District

Applicant after: Xingyun Rongchuang (Beijing) Technology Co., Ltd.

Address before: 100080 Beijing City, Haidian District Haidian Street No. 3 electronic market office building A block 10 layer

Applicant before: Nebula creation (Beijing) Information Technology Co., Ltd.

RJ01 Rejection of invention patent application after publication

Application publication date: 20130724

RJ01 Rejection of invention patent application after publication