WO2016146009A1 - Procédé et dispositif de compression de page html - Google Patents

Procédé et dispositif de compression de page html Download PDF

Info

Publication number
WO2016146009A1
WO2016146009A1 PCT/CN2016/075942 CN2016075942W WO2016146009A1 WO 2016146009 A1 WO2016146009 A1 WO 2016146009A1 CN 2016075942 W CN2016075942 W CN 2016075942W WO 2016146009 A1 WO2016146009 A1 WO 2016146009A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
compression
html page
segment
compressed
Prior art date
Application number
PCT/CN2016/075942
Other languages
English (en)
Chinese (zh)
Inventor
张荣华
Original Assignee
阿里巴巴集团控股有限公司
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 阿里巴巴集团控股有限公司 filed Critical 阿里巴巴集团控股有限公司
Publication of WO2016146009A1 publication Critical patent/WO2016146009A1/fr

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor

Definitions

  • the present invention relates to the field of the Internet, and in particular, to a Html page compression method and apparatus.
  • the current Html page compression process is: receiving a browser request, the server returns the Html page corresponding to the request, and dot the Html page, and performs page compression after the dot. Therefore, the current Html page compression, in any request, you need to compress the data of the entire page, resulting in greater server pressure.
  • an embodiment of the present invention provides a Html page compression method, the method comprising:
  • Html page compression data which specifically includes:
  • the static data compressed segment and the dynamic data compressed segment are encapsulated by a compressed header information and a compressed tail information.
  • the method before acquiring the static data compression segment and compressing the dynamic data, the method includes:
  • the static data is compressed into a static data compression segment and cached.
  • the static data is compressed into a static data compression segment and cached, and specifically includes:
  • the static data is compressed in a compression request to generate at least one static data compression segment, and the at least one static data compression segment is stored.
  • the static data or the dynamic data is the header data or the middle data of the Html page.
  • the z_sync_flush function is called to perform compression.
  • invoking the z_full_flush function to compress the central data of the Html page includes:
  • the compression header information formed on the empty string is deleted.
  • each static data compression segment includes dictionary data to be decompressible separately.
  • the merging into the Html page compression data according to the original order of the Html page specifically includes:
  • the static data compression segment and the dynamic data compression segment are assembled into Html page compression data in the order of a character string.
  • the method further includes:
  • an embodiment of the present invention provides an Html page compression apparatus, the apparatus comprising:
  • the calling module is configured to obtain a static data compression segment of the corresponding Html page in the cache according to the http header in the browser request;
  • a compression module configured to compress dynamic data corresponding to the Html page into a dynamic data compression segment
  • a processing module configured to merge the static data compression segment and the dynamic data compression segment into Html page compression data, and send the Html page compression data to a browser.
  • the processing module is configured to:
  • the static data compression segment and the dynamic data segment are merged into Html page compressed data according to the original order of the Html page.
  • the static data compressed segment and the dynamic data compressed segment are encapsulated by a compressed header information and a compressed tail information.
  • the compression module is configured to compress the static data in a compression request to generate at least one static data compression segment
  • the device further includes a storage module, the storage module Used for:
  • the compressed file will contain a compressed header information formed on the empty string. And further deleting the compression header information formed on the empty string to facilitate the subsequent "merging of data compression segments", which will be explained in detail below.
  • the static data compression segment and the dynamic data compression segment are assembled into Html page compression data in the order of the string.
  • the static content on the Html page has been pre-compressed and cached, it avoids a large amount of repeated compression every time the request server is required, which greatly reduces the computing pressure of the server.
  • the dynamic data here is dot data.
  • the compression module 20 is configured to:
  • each compressed package will carry the full DEFLATE header and trailer information. For some browsers, these multiple complete archives are not recognized. So in the java environment, a java implementation version of zlib is introduced: jzlib, jzlib supports the flush_mode (jzlib) in compression, so in this embodiment, the z_full_flush function and the z_sync_flush function are respectively called to compress the above-mentioned partial data to obtain Static data compression segment and dynamic data compression segment.
  • the Html page compression method and apparatus of the present invention can pre-compress and cache the static content on the Html page, and when receiving the browser request, can only compress the dynamic data in the Html page, and Static content is returned after merging. In this way, it avoids a lot of compression every time the request server needs, which greatly reduces the computing pressure of the server.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

L'invention concerne un procédé et un dispositif de compression de page Html. Le procédé consiste à : acquérir une section compressée de données statiques d'une page Html correspondante d'une mémoire cache conformément à un en-tête http d'une demande de navigateur, et compresser des données dynamiques correspondant à la page Html en une section compressée de données dynamiques ; et fusionner la section compressée de données statiques et la section compressée de données dynamiques en données compressées de page Html, et envoyer les données compressées de page Html à un navigateur. Le contenu statique d'une page Html peut être compressé au préalable et mis en mémoire cache et, lorsqu'une demande de navigateur est reçue, il est possible de ne compresser que les données dynamiques de la page Html puis de les fusionner avec le contenu statique et ensuite de les renvoyer. Ceci évite par conséquent d'effectuer une grande quantité de compression à chaque demande d'un serveur, ce qui permet de réduire considérablement la pression de calcul du serveur.
PCT/CN2016/075942 2015-03-17 2016-03-09 Procédé et dispositif de compression de page html WO2016146009A1 (fr)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510115508.0A CN106033448A (zh) 2015-03-17 2015-03-17 Html页面压缩方法及装置
CN201510115508.0 2015-03-17

Publications (1)

Publication Number Publication Date
WO2016146009A1 true WO2016146009A1 (fr) 2016-09-22

Family

ID=56918334

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/075942 WO2016146009A1 (fr) 2015-03-17 2016-03-09 Procédé et dispositif de compression de page html

Country Status (2)

Country Link
CN (1) CN106033448A (fr)
WO (1) WO2016146009A1 (fr)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115065725A (zh) * 2022-05-12 2022-09-16 北京奇艺世纪科技有限公司 数据处理方法、装置、电子设备及存储介质

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106790662A (zh) * 2017-01-20 2017-05-31 济南浪潮高新科技投资发展有限公司 一种使用关键帧压缩的超文本传输协议数据压缩方法
CN113364508B (zh) * 2021-04-30 2022-08-16 深圳震有科技股份有限公司 一种语音数据的传输控制方法、系统及设备
CN113518088B (zh) * 2021-07-12 2023-07-07 北京百度网讯科技有限公司 数据处理方法、装置、服务器、客户端和介质
CN113612516B (zh) * 2021-07-13 2023-05-12 深圳震有科技股份有限公司 一种卫星通信数据包的压缩测试方法、系统及设备

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7484007B2 (en) * 2002-02-01 2009-01-27 Codekko Inc. System and method for partial data compression and data transfer
CN102298630A (zh) * 2011-08-30 2011-12-28 国电南瑞科技股份有限公司 一种基于线型的过程数据有损压缩方法
CN102375884A (zh) * 2011-10-21 2012-03-14 北京百度网讯科技有限公司 一种用于对页面访问对象进行数据压缩的方法及设备
CN104283777A (zh) * 2013-07-03 2015-01-14 华为技术有限公司 报文压缩的方法和装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7484007B2 (en) * 2002-02-01 2009-01-27 Codekko Inc. System and method for partial data compression and data transfer
CN102298630A (zh) * 2011-08-30 2011-12-28 国电南瑞科技股份有限公司 一种基于线型的过程数据有损压缩方法
CN102375884A (zh) * 2011-10-21 2012-03-14 北京百度网讯科技有限公司 一种用于对页面访问对象进行数据压缩的方法及设备
CN104283777A (zh) * 2013-07-03 2015-01-14 华为技术有限公司 报文压缩的方法和装置

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115065725A (zh) * 2022-05-12 2022-09-16 北京奇艺世纪科技有限公司 数据处理方法、装置、电子设备及存储介质
CN115065725B (zh) * 2022-05-12 2024-01-12 北京奇艺世纪科技有限公司 数据处理方法、装置、电子设备及存储介质

Also Published As

Publication number Publication date
CN106033448A (zh) 2016-10-19

Similar Documents

Publication Publication Date Title
WO2016146009A1 (fr) Procédé et dispositif de compression de page html
CN103392179B (zh) 获取页面资源的方法及装置、浏览器及移动终端
US9582600B1 (en) Cloud browser DOM-based client
US9594477B1 (en) Using deep links to restore interactive state of a web page
WO2017114190A1 (fr) Procédé et dispositif de traitement de téléchargement de fichier
CN111683066B (zh) 异构系统集成方法、装置、计算机设备和存储介质
CN103532984B (zh) websocket协议的数据传输方法、设备和系统
US20160072721A1 (en) Managing network connections for processing network resources
US9740791B1 (en) Browser as a service
CN109714406B (zh) 资源描述文件的处理、页面资源的获取方法及设备
CN113992738A (zh) 基于微服务网关的反向代理方法、装置、设备及存储介质
CN109885347B (zh) 一种配置数据的获取方法、装置及终端、系统、存储介质
US8583829B2 (en) Semantic-based lossy compression
CN115914409A (zh) 一种waf安全防护日志实现高效传输、存储的方法及装置
CN104408178A (zh) Web控件加载装置和方法
CN108287874B (zh) 一种db2数据库管理方法及装置
US10749926B2 (en) Proxy for modifying HTTP messages to comply with browser
CN109683916A (zh) 一种自主创建包含应用软件的云主机镜像的方法
CN107368484A (zh) 网页的静态资源文件的压缩方法及装置、获取方法及装置
CN113839902B (zh) 通信协议适配方法、装置、计算机设备和存储介质
CN110213310B (zh) 一种网络服务的路径获取方法、装置和存储介质
CN112149392A (zh) 一种富文本编辑方法和装置
JP3916219B2 (ja) リンク先圧縮システム
CN109617708A (zh) 一种埋点日志的压缩方法、设备及系统
CN110569456B (zh) Web端数据离线缓存方法及装置、电子设备

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16764190

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16764190

Country of ref document: EP

Kind code of ref document: A1