Summary of the invention
The embodiment of the present invention proposes the method and system providing web service, can reduce the requirement to terminal processing capacity.
The embodiment of the present invention is by the following technical solutions:
There is provided a method for web service, the displaying result of each page in website is encoded to video and audio Media Stream and preserves by precoding server, and the identifying information preserving each page and the corresponding relation of video and audio Media Stream of encoding out; The method also comprises:
The web service access request that management server receiving terminal is sent, carries the identification information of the identification information of this terminal, business to be visited in this request; According to the identification information of business preserved and the corresponding relation of the identifying information of the page, obtain the identifying information of the page corresponding to the identification information of this business and send to application server;
Application server, according to the identifying information of the page received, is searched and loads the video and audio Media Stream of the corresponding page; According to the identification information of the terminal of carrying in web service access request, by this video and audio media stream to terminal.
The described displaying result by each page in website is encoded to video and audio Media Stream and comprises: according to the entry address Web page loading of website, carries out video encoding to the displaying result of Web page loading; According to the internal structure of described webpage loaded, carry out video encoding to the displaying result of the page corresponding to each action of this webpage inside, wherein, the action of described webpage inside comprises link action and/or focus motion.
Described method also comprises:
Described application server receives described terminal to the service provision request sent during described page trigger web pages internal actions, the positional information of the key code that the action of wherein carrying current triggering in this service provision request produces and/or the mouse place page;
By application component according to this current key code of trigger action generation and/or position of the mouse place page of obtaining, search the video and audio Media Stream of the corresponding page in position for this key code of this Page-saving and/or the mouse place page, by this video and audio media stream of finding to described terminal.
The step of described coding, preservation comprises: the displaying result of each page in website is encoded to the video and audio Media Stream corresponding to different resolution respectively, and for often kind of different resolution, the identifying information preserving each page respectively and the corresponding corresponding relation of often planting the video and audio Media Stream of different resolution of encoding out;
Further carried terminal resolution information in described web service access request,
Described video and audio Media Stream of searching comprises further: the video and audio Media Stream searching corresponding resolution according to the terminal resolution information carried in web service access request.
After the web service access request that described management server receiving terminal is sent, described method also comprises:
The identification information of management server according to the terminal of carrying in this web service access request and the identification information of business to be visited, verify the access rights of this terminal;
When verifying that this terminal has the authority of this business of access, obtain the identifying information of the page corresponding to the identification information of this business.
A system for web service is provided, comprises:
Precoding server, for the displaying result of each page in website is encoded to video and audio Media Stream, and the identifying information preserving each page and the corresponding relation of video and audio Media Stream of encoding out;
Terminal, for sending web service access request to management server, the wherein identification information of carried terminal, the identification information of business to be visited in this request;
Management server, for receiving the web service access request that described terminal sends, according to the identification information of business of preservation and the corresponding relation of the identifying information of the page, obtain the identifying information of the page corresponding to the identification information of this business, and the identifying information of the described page obtained is sent to application server;
Application server, for according to the page identifying information received, searches and loads the video and audio Media Stream of the corresponding page, according to the identification information of the terminal of carrying in web service access request, giving described terminal by this video and audio media stream.
Described precoding server, also for the entry address Web page loading according to website, carries out video encoding to the displaying result of Web page loading; According to the internal structure of described webpage loaded, carry out video encoding to the displaying result of the page corresponding to each action of this webpage inside, wherein, the action of described webpage inside comprises link action and/or focus motion.
Described application server, also for receiving described terminal to the service provision request sent during described page trigger web pages internal actions, the positional information of the key code that the action of wherein carrying current triggering in this service provision request produces and/or the mouse place page; The key code produced according to this current trigger action and/or the position of the mouse place page, the video and audio Media Stream of the corresponding page in position for this key code of this Page-saving and/or the mouse place page is searched, by this video and audio media stream of finding to described terminal by application component.
Described precoding server, also for the displaying result of each page in website being encoded to respectively the video and audio Media Stream corresponding to different resolution, and for often kind of different resolution, the identifying information preserving each page respectively and the corresponding corresponding relation of often planting the video and audio Media Stream of different resolution of encoding out; The video and audio Media Stream of corresponding resolution is searched according to the terminal resolution information carried in web service access request.
Management server, also for according to the identification information of the terminal of carrying in this web service access request and the identification information of business to be visited, verifies the access rights of this terminal; When verifying that this terminal has the authority of this business of access, obtain the identifying information of the page corresponding to the identification information of this business.
The beneficial effect of the embodiment of the present invention is as follows:
1, in the present invention, need the displaying result of each page represented to carry out video encoding in advance to web service, the video and audio Media Stream obtained after preserving coding, when user is by the service of terminal triggering media, terminal only need send web service access request to network side, network side is according to the identification information of the business to be visited of carrying in this web service access request, determine the identifying information of the page that these needs are accessed and the video and audio Media Stream after coding is supplied to terminal, terminal only need be supplied to user to after the video and audio media stream passed back.
Terminal is without the need to performing the processing capacity of various browser, therefore without the need to integrated browser in the terminal, greatly reduce the requirement to terminal processing capacity, thus make that disposal ability is lower does not support that the terminal of browser function can be embodied as user and provide web service even completely, and then considerably increase practicality of the present invention, improve the satisfaction of user;
2, in the present invention, due to without the need to integrated browser in terminal, therefore provider terminal is without the need to providing the terminal possessing higher position reason ability, also without the need to buying browser to browser provider, thus greatly reduce terminal realize cost;
3, in the present invention, encode in advance owing to needing video and audio Media Stream corresponding to the various webpages that provide and stored, the application server of network side is without the need to after the web service request receiving user, carry out coded treatment web page contents being converted into video and audio Media Stream in real time, but only need the corresponding video and audio media stream that prestores to terminal, therefore make network side application server can provide web service simultaneously for multiple terminal, thus save server resource.
Embodiment
For making the object of the embodiment of the present invention, technical scheme and advantage clearly, below in conjunction with the accompanying drawing in the embodiment of the present invention, technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
Embodiment 1:
Embodiments of the invention 1 propose a kind of method providing web service, see Fig. 1, the method of this embodiment is in step 100: in advance the displaying result of each page in website is encoded to video and audio Media Stream and stores, and the identifying information preserving each page and the corresponding relation of video and audio Media Stream of encoding out.Concrete can be that the displaying result of each page is encoded to video and audio Media Stream by precoding server in the present embodiment.When needs provide web service for user, perform following steps:
Step 101: the web service access request that management server receiving terminal is sent, carries the identification information of the identification information of this terminal, business to be visited in this request.
Step 102: management server, according to the corresponding relation of the identification information of business and the identifying information of the page preserved, obtains the identifying information of the page corresponding to the identification information of this business, and the identifying information of this page of acquisition is sent to application server.
Step 103: application server, according to the identifying information of webpage received, is searched and loads the video and audio Media Stream of the corresponding page, according to the identification information of the terminal of carrying in web service access request, by this video and audio media stream to terminal.
Can find out, in the present invention, need web service the displaying result of each page represented to carry out video encoding in advance, the video and audio Media Stream obtained after preserving coding.When user carries out web page browsing by terminal, terminal only need send web service access request to network side, the web service access request of the management server receiving terminal transmission of network side.
Why terminal needs, by management server, web service access request is sent to application server is in the present embodiment based on following consideration:
Terminal needs a unified access entrance.Because application server is a lot, IP address is different, and terminal does not also know these addresses, so need an allocator to carry out unified Resourse Distribute.
Terminal user ID verifies.Whether management server mainly verification terminal user has the authority of certain service/application procedure service of access.Such as: the service that operator opens has 10 yuan of monthly payments, 30 yuan of monthly payments two kinds, the business (network address) that often kind of service can be accessed is different.When terminal is applied for, management server queries database or communicate with special right management server, according to the identification information of terminal and the identification information of business to be visited, can judge whether this terminal has the authority of this business of access.
When management server verification terminal has the authority of this business of access, according to the identification information of business of preservation and the corresponding relation of the identifying information of the page, obtain the identifying information of the page corresponding to the identification information of this business, the identifying information of this page obtained is sent to the application server of network side by management server.After application server receives the identifying information of this page, search and load the video and audio Media Stream of the corresponding page, and passing this video and audio Media Stream back terminal.User is supplied to after the video and audio media stream that network side is passed back by terminal.
In addition, owing to there is no configure browser in the terminal of the embodiment of the present invention, in order to realize the access of user to different web pages, in the terminal with the form of business or application program for user provides service, the various application programs in similar smart mobile phone.The identifying information of the corresponding specific webpage of each application program.Like this, when user selects this application program or service operation, terminal is directly by the identification information of business sending to management server, the identification information of business of management server according to preservation and the corresponding relation of the identifying information of the page, obtain the identifying information of the page corresponding to the identification information of this business, the identifying information of this page can be the URL(uniform resource locator) (URL) of the page.
Because terminal is in the present embodiment without the need to performing the processing capacity of various browser, therefore without the need to integrated browser in the terminal, greatly reduce the requirement to terminal processing capacity, thus make that disposal ability is lower does not support that the terminal of browser function can be embodied as user and provide web service even completely.
In the method for above-described embodiment 1, in order to ensure that all pages needed for user can both provide web service further, preferably, when in advance the displaying result of each page in website to be carried out video encoding and forms video and audio Media Stream, this coding can carry out for each page, concrete implementation procedure comprises: according to an entry address Web page loading for website, carries out video encoding to the displaying result of the page of Web page loading; According to the internal structure of described webpage loaded, carry out video encoding to the displaying result of the page corresponding to each action of this webpage inside, wherein, the action of described webpage inside comprises link action and/or focus motion.That is, can to a page link to the displaying result of other new page to encode out in advance corresponding video and audio Media Stream, the video and audio Media Stream of correspondence of also can encoding out in advance to the displaying result of the page formed after a page focus change, thus the video and audio Media Stream that the displaying result that can ensure to generate in advance each page that user needs is corresponding, ensure follow-uply to provide more perfect web service for user.
The displaying result of each page can be encoded to video and audio Media Stream by precoding server, and wherein this precoding server can be an independent station server, or is integrated in application server or other server internal.After the displaying result of each page is encoded to video and audio Media Stream by precoding server, the video and audio Media Stream after coding can be kept in database or hard disk.
After terminal is entered web, terminal can send the service provision request of trigger web pages internal actions to application server, the positional information of the key code that the action of wherein carrying current triggering in this service provision request produces and/or the mouse place page; Application server is by application component this current key code of trigger action generation and/or position of the mouse place page according to acquisition, search the video and audio Media Stream of the corresponding page in position for this key code of this Page-saving and/or the mouse place page, by this video and audio media stream of finding to described terminal.
In practice, for the different terminals with different resolution, it can resolve and be supplied to the video and audio Media Stream of user's different resolution, therefore, in order to strengthen the range of application of the embodiment of the present invention 1 further, in the process of above-mentioned precoding, the content of each page in website can be encoded to the video and audio Media Stream corresponding to different resolution respectively and store, and in the process of above-mentioned preservation corresponding relation, for often kind of different resolution, at the corresponding relation of the network side identifying information preserving each page respectively and the video and audio Media Stream of encoding out, in such cases, further carried terminal resolution information in the web page display request that terminal sends, so that network side searches video and audio Media Stream according to the terminal resolution information carried in web service request further, thus ensure the web service that corresponding resolution can both be provided for the terminal of different resolution.
In order to strengthen the fail safe of web service further, the embodiment of the present invention 1 can also complete the process to terminal authorization checking, determines whether providing web service according to the result.Feasible implementation is: management server, when receiving web service access request, according to the identification information of the terminal of carrying in this request and the identification information of business to be visited, is verified the access rights of this terminal; When verifying that this terminal has the authority of this business of access, just perform the identifying information and subsequent treatment that obtain the page corresponding to the identification information of this business, otherwise, no longer perform the follow-up process that web service is provided, refuse the request of terminal, and terminate.
Embodiment 2:
Fig. 2 is the flow chart providing web service in the embodiment of the present invention 2.See Fig. 2, be video/audio code stream for video and audio Media Stream, in concrete business realizing, preferably, provide the process of web service to comprise the steps:
Step 201: mutual by with WEB server of precoding server, is encoded to the video/audio code stream corresponding to different resolution respectively by the displaying result of each page in each for WEB server website.
Step 202: precoding server for often kind of different resolution, the corresponding relation of the identifying information preserving each page respectively and the video/audio code stream of encoding out.
The process of above-mentioned steps 201 to step 202 is the preprocessing process carried out before network side provides concrete web service for user terminal, this preprocessing process can be performed by the precoding server of network side, specifically can be completed by the precoding parts in precoding server.
Precoding component integration browser core.After have input the entry address of some websites, precoding server and WEB server connect, and after first precoding parts utilize browser core to load this webpage, carry out video encoding to the displaying result of this webpage.Then according to the internal structure of this webpage, the action of precoding parts meeting trigger web pages inside (such as: link action, focus motion etc.Link action can trigger browser and load next webpage; Focus motion can trigger the change of this focus, as picture change, font change etc.), carry out video encoding to the displaying result of the page that each action produces, the rest may be inferred, until all travel through complete by the webpage in whole website and encode.
And, in order to ensure the display quality of the page provided to terminal, precoding parts are according to the resolution sizes of conventional display device display screen, respectively each page is encoded to the video/audio code stream of the display screen resolution of applicable corresponding size, and preserves corresponding each link, the concrete zone position information of focus in this display page for this video/audio code stream.Video/audio code stream after coding saves by precoding parts, video/audio code stream after coding can be saved in database or in hard disk by precoding parts, need to record the relation of zone position information corresponding to each trigger action and corresponding video/audio code stream simultaneously, retrieve corresponding video/audio code stream according to user interactive for follow-up and broadcast.
When needing to provide concrete web service by terminal for user, perform the following steps in Fig. 2.
Step 203: user by button or mouse action trigger web pages in terminal browse.
Step 204: web service access request is sent to management server by terminal, the wherein identification information of carried terminal, the identification information of business to be visited and terminal resolution information in this web service access request.
Step 205: management server is according to the terminal authorization information of preserving, and the identification information of the terminal of carrying in web service access request and the identification information of business to be visited, judges whether this terminal has the authority of this business of access, if, perform step 207, otherwise, perform step 206.
In step 205, management server judges whether terminal has corresponding authority, mainly audits the authority whether corresponding user has certain service/application program corresponding with service of access.Such as: the service that operator opens has 10 yuan of monthly payments, 30 yuan of monthly payments two kinds, the business (network address) that often kind of service can be accessed is different.The authority information of concrete each user can be preserved in a database, or is responsible for by special right management server.
Management server can Query Database or communicate with special right management server, according to the identification information of terminal and the identification information of business to be visited, can judge whether this terminal has the authority of access current page.
Step 206: management server returns error message to terminal, terminates current process.
Step 207: management server, according to the identification information of business preserved and the corresponding relation of the identifying information of the page, obtains the identifying information of the page corresponding to the identification information of this business and sends to application server.
Step 208: application server, according to the identifying information of the page received, is searched by application component and loads the video/audio code stream of the corresponding page.
Step 209: the video/audio code stream found, according to the identification information of the terminal of carrying in web service access request, is sent to terminal by application server.
Step 210: the video/audio code stream decoding that end-on receives, is supplied to user by the displaying result of the Webpage of correspondence.
Here, the mode provided comprises: show image, play sound.
Step 211: terminal receives the internal actions of the Webpage that user triggers.
Step 212: terminal sends service provision request to application server, the positional information of the key code that the action of carrying current triggering in this service provision request produces and/or the mouse place page.
Step 213: application server according to this current key code of trigger action generation and/or position of the mouse place page of obtaining, searches the video/audio code stream for the corresponding page of this key code of this Page-saving and/or the position of the mouse place page by application component.
Step 214: the video/audio code stream found is sent to terminal by application server.
Step 215: the video/audio code stream decoding that end-on receives, is supplied to user by the displaying result of the Webpage of correspondence.
In addition, in the present embodiment when the web page browsing that terminal receives user's input stops request, this termination request is sent to management server.Management server stops request according to this web page browsing, and the disconnection of control application server links with terminal room.
Be described with the process of object lesson to above-mentioned steps 211 to step 215: according to the internal structure of Webpage, the action that user understands trigger web pages inside such as links action and/or focus motion, when user's clicking trigger one link action, or during focus motion on change webpage, these actions all can change by triggering page.In such as Fig. 3, the page 1 has one to link A, when focus is on link A, when user is chosen by keyboard or mouse, can trigger the action of this link, terminal sends service provision request to application server, and application server returns the video and audio Media Stream of the page 2 that this link A is linked to terminal, thus in terminal, being loaded with the page 2, the page there occurs change.For another example, Fig. 4 illustrates the trigger action of another page change.This page has several linked terms: " word picture A ", " word picture B ".Current focus is at " word picture A ", and now this focus has a highlighted image effect (with box indicating in figure).Now user can trigger following actuation of keys by keyboard: upper and lower, left and right.When user triggers " right side " key, this focus is transferred to " word picture B ", terminal sends service provision request to application server, application server returns video and audio Media Stream to terminal, this video and audio Media Stream correspondence comprises the new page of the highlight effect of " word picture B ", thus in terminal, load the new page, and therefore the highlight effect of " word picture A " disappears, the highlight effect of " word picture B " is in the display of the new page, and the page there occurs change.
Embodiment 3:
This embodiment 3 proposes a kind of system providing web service, see Fig. 5, comprising:
Precoding server 500, for the displaying result of each page in website is encoded to video and audio Media Stream and stores, and the identifying information preserving each page and the corresponding relation of video and audio Media Stream of encoding out;
Terminal 501, for sending web service access request to management server 502, the wherein identification information of carried terminal, the identification information of business to be visited in this request;
Management server 502, for receiving the web service access request that described terminal 501 sends, according to the identification information of business of preservation and the corresponding relation of the identifying information of the page, obtain the identifying information of the page corresponding to the identification information of this business, and the identifying information of the described page obtained is sent to application server 503;
Application server 503, for according to the identifying information of the page received, searches and loads the video and audio Media Stream of the corresponding page, according to the identification information of the terminal of carrying in web service access request, giving described terminal 501 by this video and audio media stream.
In a system of the invention, described precoding server 500, also for the entry address Web page loading according to website, carries out video encoding to the displaying result of Web page loading; According to the internal structure of described webpage loaded, carry out video encoding to the displaying result of the page corresponding to each action of this webpage inside, wherein, the action of described webpage inside comprises link action and/or focus motion.
In a system of the invention, described application server 503, also for receiving described terminal 501 to the service provision request sent during described page trigger web pages internal actions, the positional information of the key code that the action of wherein carrying current triggering in this service provision request produces and/or the mouse place page; By application component according to this current key code of trigger action generation and/or position of the mouse place page of obtaining, search the video and audio Media Stream of the corresponding page in position for this key code of this Page-saving and/or the mouse place page, by this video and audio media stream of finding to described terminal 501.
In a system of the invention, described precoding server 500, also for the displaying result of each page in website being encoded to respectively the video and audio Media Stream corresponding to different resolution, and for often kind of different resolution, the identifying information preserving each page respectively and the corresponding corresponding relation of often planting the video and audio Media Stream of different resolution of encoding out; The video and audio Media Stream of corresponding resolution is searched according to the terminal resolution information carried in web service request.
In a system of the invention, management server 502, also for according to the identification information of the terminal 501 of carrying in this web service access request and the identification information of business to be visited, verifies the access rights of this terminal 501; When verifying that this terminal has the authority of this business of access, obtain the identifying information of the page corresponding to the identification information of this business.
It should be noted that, this precoding server 500 can be an independent station server in embodiments of the present invention, or it is inner to be built in application server 503, or is built in other server internal, video encoding can be carried out by browser core to the webpage shown.
Technical scheme of the present invention can be applied to the miscellaneous service field served by terminals with web pages.Such as, digital TV field, Web TV (Internet Protocol television, IPTV) field, mobile phone business field, internet arena etc., correspondingly, terminal in the present invention can be the terminal in miscellaneous service field, such as Set Top Box, mobile phone, computer etc.
One of ordinary skill in the art will appreciate that: all or part of step realizing said method embodiment can have been come by the hardware that program command is relevant, aforesaid program can be stored in a computer read/write memory medium, this program, when performing, performs the step comprising said method embodiment; And aforesaid storage medium comprises: ROM, RAM, magnetic disc or CD etc. various can be program code stored medium.
Last it is noted that above embodiment is only in order to illustrate technical scheme of the present invention, be not intended to limit; Although with reference to previous embodiment to invention has been detailed description, those of ordinary skill in the art is to be understood that: it still can be modified to the technical scheme described in foregoing embodiments, or carries out equivalent replacement to wherein portion of techniques feature; And these amendments or replacement, do not make the essence of appropriate technical solution depart from the spirit and scope of various embodiments of the present invention technical scheme.