CN106776756B - Method and device for processing weather resource data by server side and client side - Google Patents

Method and device for processing weather resource data by server side and client side Download PDF

Info

Publication number
CN106776756B
CN106776756B CN201611033681.7A CN201611033681A CN106776756B CN 106776756 B CN106776756 B CN 106776756B CN 201611033681 A CN201611033681 A CN 201611033681A CN 106776756 B CN106776756 B CN 106776756B
Authority
CN
China
Prior art keywords
weather data
weather
data
client
read
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.)
Active
Application number
CN201611033681.7A
Other languages
Chinese (zh)
Other versions
CN106776756A (en
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.)
Hangzhou Lianluo Interactive Information Technology Co ltd
Original Assignee
Hangzhou Lianluo Interactive 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 Hangzhou Lianluo Interactive Information Technology Co ltd filed Critical Hangzhou Lianluo Interactive Information Technology Co ltd
Priority to CN201611033681.7A priority Critical patent/CN106776756B/en
Publication of CN106776756A publication Critical patent/CN106776756A/en
Application granted granted Critical
Publication of CN106776756B publication Critical patent/CN106776756B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/283Multi-dimensional databases or data warehouses, e.g. MOLAP or ROLAP
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/282Hierarchical databases, e.g. IMS, LDAP data stores or Lotus Notes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases
    • G06F16/285Clustering or classification
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/52Network services specially adapted for the location of the user terminal
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Abstract

The scheme provides a method for processing weather resource data at a server, which comprises the following steps: grading each weather data source according to a preset evaluation standard; reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data; reading the weather data of the missing or flaw of the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data; and updating a weather database for the client to read by using the preferred weather data. The server side has good flexibility, and can provide the weather data customized by the client side according to different requirements; the client side does not depend on the updating of the weather data source, and the problems that the data are single to be inquired from a single data source and the resource consumption is large to be inquired from a plurality of data sources are solved.

Description

Method and device for processing weather resource data by server side and client side
Technical Field
The scheme relates to the field of weather resource data processing, in particular to a method and a device for processing weather resource data at a server. The scheme also relates to a method and a device for processing the weather resource data by the client.
Background
In the prior art, a server does not participate in the query of a client on weather data, and the client generally directly queries a weather resource data source providing the weather data. Thus, when a client, especially a mobile client, queries weather data, there are generally two options for the design of the data source:
firstly, a client is limited to inquire from a certain specific weather data source, and the disadvantage is that the source of the weather data is single and the obtained weather data is not comprehensive; moreover, when a weather data source for inquiring weather data is down, the client cannot inquire the weather data; finally, once the server side changes the weather data storage, the client side must immediately perform corresponding updating, otherwise normal query may not be performed.
The second option is that the client can query from several weather data sources. At this time, the client can obtain the weather data with richer contents, and normal query cannot be performed due to the downtime of a certain specific weather data source, but the client has the defects of excessive resource consumption and possible waste of network traffic.
Disclosure of Invention
The scheme provides a method for processing weather resource data by a server and a method for processing weather resource data by a client matched with the server, so as to solve the problems that in the prior art, the weather data inquired by the client has a single source, the data is not comprehensive, the resource consumption is excessive and the like. The scheme also provides a device for processing the weather resource data by the server side and the client side.
The scheme provides a method for processing weather resource data at a server, which comprises the following steps:
classifying each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance;
reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data;
if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or defective data exists in the read weather data according to a preset evaluation standard, reading the weather data which is missing or defective in the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data;
and updating a weather database for the client to read by using the preferred weather data.
Optionally, the preset evaluation criteria include: data accuracy, data immediacy and/or data interface usability; the higher the data accuracy, the data instantaneity and the usability of the data interface are, the higher the evaluation level of the corresponding weather data source is.
Optionally, each weather data source corresponds to one evaluation level.
Optionally, the step of classifying each weather data source according to a preset evaluation criterion and making each weather data source correspond to different evaluation grades includes:
and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
Optionally, the step of reading the weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as the preferred weather data is repeatedly executed according to a preset fixed time interval.
Optionally, after the step of reading the weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, before the step of executing and using the read weather data as the preferred weather data, and after the step of reading the weather data of the required area from the weather data source corresponding to the next evaluation level of the required area, before the step of executing and adding the read weather data to the preferred weather data, the following steps are executed:
judging whether weather data of a required area in a required time period is read or not; if yes, entering the next step; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and entering the next step until the weather data of the required area in the required time period is read.
Optionally, the defect data includes: data that cannot be read, have insufficient bits stored, or have errors transferred.
Optionally, before the step of updating the weather database for the client to read by using the preferred weather data is executed, the following steps are executed:
and creating the weather database for the client to read at the server side.
Optionally, the weather database for the client to read is located locally at the server.
Optionally, the method includes:
according to the requirements of a client on a required area and a required time period of weather data, customizing the weather data of the required area and the required time period corresponding to the client, and storing the weather data customized corresponding to the client in the weather database.
Optionally, when the client requests the weather data, the customized weather data is provided to the client.
This scheme still provides a device of server end processing weather resource data, includes:
the weather data source evaluation grade determining unit is used for grading each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance;
the weather data acquisition and optimization unit is used for reading the weather data of the required area from the weather data source corresponding to the highest evaluation grade of the required area and taking the read weather data as the preferable weather data;
a supplementary preferred weather data unit, configured to, if the weather data corresponding to the required area is incomplete in the weather data source corresponding to the highest evaluation level of the required area, or it is determined according to a predetermined evaluation criterion that defective data exists in the read weather data, read the missing or defective weather data of the required area from the weather data source corresponding to the next evaluation level of the required area, and supplement the read weather data to the preferred weather data;
and the updating weather database unit is used for updating the weather database read by the client by using the preferred weather data.
Optionally, the unit for determining the evaluation level of the weather data source is configured to:
and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
Optionally, the acquiring the preferred weather data unit and supplementing the preferred weather data unit include:
judging whether weather data of a required area in a required time period is read or not; if yes, triggering the next unit; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and triggering the next unit until the weather data of the required area in the required time period is read.
Optionally, the apparatus includes:
and the custom client weather data unit is used for customizing the weather data of the required area and the required time period corresponding to the client according to the requirements of the client on the required area and the required time period of the weather data, and storing the weather data customized corresponding to the client in the weather database.
Optionally, the apparatus includes:
and providing a client customized weather data unit for providing the customized weather data to the client when the client requests the weather data.
The scheme provides a method for processing weather resource data by a client, which comprises the following steps:
receiving weather data of a required area corresponding to a required city from a weather database of a server side according to a city list in a preset city database;
when receiving an update client notification pushed from a server, prompting a user and judging whether the user agrees to execute the update; and if so, downloading a corresponding updating program or data from the server side to execute the updating.
Optionally, when the update client notification pushed from the server is received, the step of prompting the user and determining whether the user agrees to perform the update includes: if not, an entry is provided to the usage principal to learn about the update.
This scheme still provides a device that weather resource data was handled to client, includes:
the system comprises a unit for receiving weather data of a required city, a unit for receiving weather data of the required area corresponding to the required city from a weather database of a server side according to a city list in a preset city database;
the system comprises an update client program and data unit, a server and a server, wherein the update client program and data unit is used for prompting a use subject and judging whether the use subject agrees to execute the update or not when receiving an update client notification pushed from the server; and if so, downloading a corresponding updating program or data from the server side to execute the updating.
This scheme still provides an electronic equipment, includes:
a display;
a processor;
a memory for storing a program for processing weather resource data at a server, the program, when read and executed by the processor, performing the following operations: classifying each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance; reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data; if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or defective data exists in the read weather data according to a preset evaluation standard, reading the weather data which is missing or defective in the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data; and updating a weather database for the client to read by using the preferred weather data.
Compared with the prior art, the scheme has the following advantages:
the client receives the weather resource data processed by the server, the defect of single query data of the client in the prior art can be overcome, and the server provides the weather data which come from a plurality of weather data sources and have richer contents to the client.
The server side of the scheme has good flexibility. The server side can integrate data of different weather data sources according to different weather data distribution strategies, and can customize weather data received by the client side aiming at the client sides with different requirements.
The client side does not depend on a specific weather data source, and normal query of the client side on the weather data cannot be influenced even if the specific weather data source cannot work normally; the client side of the scheme does not depend on a specific program version, and does not influence the correctness of the weather data query result no matter whether the updating is selected or not when the updating is needed.
The client side of the scheme has higher query efficiency and less resource consumption. On one hand, the time-consuming operation in the scheme is not performed at the client, so that better user experience can be obtained at the client; on the other hand, the scheme can provide the pre-customized weather data at the server end according to the specific requirements of the client end on the region and the time period, and the data providing speed is very high.
Drawings
Fig. 1 is a flowchart of an embodiment of a method for processing weather resource data at a server according to a first embodiment of the present disclosure;
fig. 2 is a schematic view of an embodiment of an apparatus for processing weather resource data at a server according to a second embodiment of the present disclosure;
fig. 3 is a flowchart of an embodiment of a method for processing weather resource data by a client according to a third embodiment of the present disclosure;
fig. 4 is a schematic diagram of an embodiment of an apparatus for processing weather resource data by a client according to a fourth embodiment of the present disclosure;
fig. 5 is a schematic view of an embodiment of an electronic device for processing weather resource data at a server according to a fifth embodiment of the present disclosure.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present solution. This solution can be implemented in many ways other than those described herein and those skilled in the art will appreciate that the present solution is not limited to the specific implementations disclosed below without departing from the scope of the present solution.
The present disclosure provides a method for a device for processing weather resource data at a server, a device for processing weather resource data at a server, a method for a device for processing weather resource data at a client, and an electronic device for processing weather resource data at a server, and the following describes embodiments of the present disclosure in detail with reference to the accompanying drawings in sequence.
Please refer to fig. 1, which is a method for processing weather resource data at a server according to a first embodiment of the present disclosure.
The server side of the scheme is the same as other server sides which usually provide data service, and can provide corresponding data for the client side according to the specific data request of the client side; meanwhile, when the program of the client needs to be updated, the server can push an update notification to the client and provide the corresponding updated program and data. The scheme is not described in detail, and the implementation can be implemented by referring to a general server-side method.
The method for processing the weather resource data at the server comprises the following steps:
step S101: and grading each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance.
Classifying all available weather data sources according to a preset weather data source grade evaluation standard; and (4) dividing each weather data source into average grades corresponding to the evaluation grades related to the specific areas.
Before the weather data is acquired by using the weather data sources, available weather data sources are graded to select the weather data sources which are more suitable for specific requirements. In general, the preset evaluation criteria for ranking available weather data sources may include: data accuracy, data immediacy, and/or ease of use of data interfaces. Of course, this evaluation criterion may also include any other factors that may be introduced as necessary, such as network transmission speed, etc. The evaluation criteria may be used alone to rank the weather data sources or may be combined and used as a weighted average.
When the evaluation levels of the weather data sources are graded, the highest evaluation level sequence can be assigned according to the highest evaluation level sequence assigned by the most excellent data source, namely, the higher the data accuracy, the data instantaneity and the data interface usability, the higher the evaluation level of the corresponding weather data source is. Of course, the rank order may be assigned in reverse order in which the best data source is assigned the lowest rating level, and in particular, the best data source may be identified. In this embodiment, the method of assigning the highest rating level to the most elegant data source is adopted.
The rating in this scenario is closely related to the specific area. The client generally specifies an area where weather data is requested, and thus it is necessary that the evaluation level corresponds to an area required by the client.
When the weather data sources are classified, different weather data sources can be classified into different evaluation levels, and a plurality of weather data sources can be classified into the same evaluation level. If a plurality of weather data sources are graded into the same evaluation grade, any one weather data source in the same evaluation grade can be randomly selected when the weather data source is used. The embodiment adopts a method of grading a plurality of weather data sources into the same evaluation level.
For example, in this embodiment, it is assumed that there are 5 available weather data sources A, B, C, D and E, and the data instantaneity is taken as the criterion, and no matter the area, the data instantaneity of the weather data source B is the highest, the weather data source C is the next, the weather data source D is the next, the weather data source E is the next, and the weather data source a is the lowest; assuming that the four weather data sources correspond to two different areas X and Y, the weather data sources a and B cover the area X, and the weather data sources C, D and E cover the area Y; then in ranking, these weather data sources may be sorted, in order from highest ranking to lowest ranking, into weather data source B, A for region X, and weather data sources C, D and E for region Y.
Step S101-1: and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
If a certain weather data source cannot work normally, for example, cannot be read normally, the evaluation level of the weather data source can be reduced to the lowest level until the data source returns to work normally, and then the evaluation level of the data source is returned.
The preferred step is to make an emergency plan for a weather data source, and when a problem occurs in a certain weather data source, the priority of the data source can be reduced to the minimum on the server, and even temporarily disabled until the data source is recovered. Therefore, the probability of reading the weather data source is low, and the adverse effect caused by the fact that the weather data source cannot work normally can be reduced.
For example, in this embodiment, assuming that the weather data source B cannot work normally, the evaluation level of the weather data source B may be reduced to the minimum, and after the weather data source B is degraded, the evaluation levels of the weather data source corresponding to the area X from high to low are respectively: a weather data source A, B.
Step S103: and reading the weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as the preferred weather data.
And reading the weather data of the specific area from the weather data source corresponding to the specific area and having the highest evaluation level, and forming the preferred weather data corresponding to the specific area according to the read weather data.
For example, in this embodiment, assuming that the required area is the area Y, the weather data is read from the weather data source C corresponding to the highest evaluation level of the area Y, and the weather data read from the weather data source C is used as the preferred weather data corresponding to the area Y.
When the weather data of the required area is read from the weather data source corresponding to the highest evaluation level of the required area and the read weather data is taken as the optimal weather data, the weather data can be repeatedly executed according to a preset fixed time interval so as to ensure the instantaneity of the weather database read by the client; the shorter the preset fixed time interval is, the higher the degree of immediacy of the read weather data is.
For example, in the present embodiment, the weather data is read from the weather data source C every 10 minutes.
Step S105: if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or the defect data exists in the read weather data according to the preset evaluation standard, the missing or defective weather data of the required area is read from the weather data source corresponding to the next evaluation level of the required area, and the read weather data is supplemented into the preferred weather data.
If some data in a weather data source is found to be incomplete when the weather data is read from the weather data source corresponding to the highest evaluation level of a specific area, or the read weather data is judged to have defects according to a preset evaluation standard, then the missing or defective part of the weather data in the weather data of the area can be read from the weather data source corresponding to the next evaluation level of the highest evaluation level of the area, and the read part of the weather data is supplemented into the preferred weather data to complement or correct the preferred weather data.
If some data in a certain weather data source is missing, when the weather data is read from the data source, the missing data cannot be read from the data source, and the missing data can be read from other weather data sources to complement the preferred weather data.
The predetermined evaluation criterion is used to determine whether defects exist in the read weather data, and the defect data generally includes weather data which cannot be read, has insufficient storage bits, or has transmission errors. The common feature of these defect data is that the accuracy of the weather data is affected, so it needs to be corrected from other data sources.
For example, in this embodiment, when the weather data is read from the weather data source C corresponding to the highest evaluation level of the area Y, if the data of town V is found to be missing in the read weather data, the data of town Z may be read from the weather data source D of the next evaluation level, and the data of town V may be added to the preferred weather data formed by reading the data from the weather data source C.
For another example, in this embodiment, when the weather data is read from the weather data source C corresponding to the highest evaluation level of the area Y, if it is found that the data of town W in the read weather data cannot be read and becomes defective data, the data of town W may be read from the weather data source D of the next evaluation level, and the data of town W may be corrected and replaced with the data of town W in the preferred weather data formed by reading the data from the weather data source C.
The above steps all relate to the situation related to the area, and in the specific implementation, factors related to the time period are also considered to comprehensively read the weather data and optimize the composition of the weather data.
After the step of reading the weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area in step S103, before the step of executing and using the read weather data as the preferred weather data, and after the step of reading the weather data of the required area from the weather data source corresponding to the next evaluation level of the required area in step S105, and before the step of executing and adding the read weather data to the preferred weather data, the following steps are executed:
steps S103-1 and S105-1: judging whether weather data of a required area in a required time period is read or not; if yes, entering the next step; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and entering the next step until the weather data of the required area in the required time period is read.
After reading the weather data and before taking the read weather data as the preferred weather data, whether the weather data of the required area in the required time period is read or not can be carried out; if the weather data of the time interval is read, the next step can be executed; if the weather data of the time interval cannot be read, reading the weather data of the required area of the required time interval from another weather data source of the next evaluation level of the currently read weather data source; and if the weather data of the required area in the required time period cannot be read from the weather data source of the next evaluation level of the current weather data source, reading from the weather data source of the next evaluation level, repeating the steps until the weather data of the required area in the required time period is read, and then entering the next step.
For example, in this embodiment, when reading weather data from the weather data source C corresponding to the highest evaluation level of the area Y, assuming that 10 am of township needs to be read and weather data is rounded, but the data of township in the weather data source C only reaches nine am at the latest, and there is no 10 am data, the 10 am weather data of township can be read and rounded from the weather data source D of the next and evaluation levels; if the weather data source D does not have the weather data pointing to 10 am in town, the weather data pointing to 10 am in town can be read from the weather data source E until the data is read, and the next step is carried out.
Step S107: and updating a weather database for the client to read by using the preferred weather data.
After the preferred weather data is composed or supplemented, the data may be updated in a weather database for reading by the client.
The weather database for the client to read is created at the server before the weather data is read from the weather data source. Generally, for the reason of improving reading efficiency, the weather database for the client to read is arranged locally at the server. Of course, the weather database for the client to read may also be set on the local area network or even the cloud storage, as long as the reading speed of the data can meet the requirement of the client for data reading.
In order to further improve the response speed of the client to read the weather data, the following steps can be further executed:
step S107-1: according to the requirements of a client on a required area and a required time period of weather data, customizing the weather data of the required area and the required time period corresponding to the client, and storing the weather data customized corresponding to the client in the weather database.
And customizing the weather data of the specific area and the specific time period corresponding to the client according to the requirements of the specific client on the specific area and the specific time period of the weather data, and storing the customized weather data corresponding to the client in a weather database. At this time, the weather database may preferably store the identifier of the client and the weather data customized for the client in the same file, which may further improve the response speed of the client in reading the weather data.
Step S107-3: when a client requests weather data, the customized weather data is provided to the client.
In cooperation with the step S107-1, when the client requests weather data, the weather data of a specific area and a specific time period customized for the client can be directly read from the weather database and provided to the client.
The scheme also provides a device for processing the weather resource data at the server terminal. Please refer to fig. 2, which is a schematic diagram illustrating an embodiment of an apparatus for processing weather resource data at a server according to a second embodiment of the present disclosure. Since the apparatus embodiments are substantially similar to the method embodiments, they are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for relevant points. The device embodiments described below are merely illustrative.
The device for processing the weather resource data at the server end comprises:
a weather data source evaluation level determining unit 201, configured to grade each weather data source according to a preset evaluation criterion, so that each weather data source corresponds to an evaluation level having a regional relevance;
the acquiring preferable weather data unit 203 is used for reading the weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferable weather data;
a supplement preferred weather data unit 205, configured to, if the weather data corresponding to the required area is incomplete in the weather data source corresponding to the highest evaluation level of the required area, or it is determined according to a predetermined evaluation criterion that defective data exists in the read weather data, read the missing or defective weather data of the required area from the weather data source corresponding to the next evaluation level of the required area, and supplement the read weather data to the preferred weather data;
and an update weather database unit 207, configured to update the weather database for the client to read, by using the preferred weather data.
Optionally, the unit 201 for determining an evaluation level of a weather data source is configured to:
and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
Optionally, the acquiring preferred weather data unit 203 and the supplementing preferred weather data unit 205 include:
judging whether weather data of a required area in a required time period is read or not; if yes, triggering the next unit; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and triggering the next unit until the weather data of the required area in the required time period is read.
Optionally, the apparatus includes:
and the custom client weather data unit is used for customizing the weather data of the required area and the required time period corresponding to the client according to the requirements of the client on the required area and the required time period of the weather data, and storing the weather data customized corresponding to the client in the weather database.
Optionally, the apparatus includes:
and providing a client customized weather data unit for providing the customized weather data to the client when the client requests the weather data.
Please refer to fig. 3, which is a schematic diagram illustrating an embodiment of a method for processing weather resource data by a client according to a third embodiment of the present disclosure. The method for processing the weather resource data by the client comprises the following steps:
step S301: and receiving weather data of a required area corresponding to the required city from a weather database of the server side according to a city list in a preset city database.
In the scheme, a city database is preset at each client, and a city list requesting weather data is stored; the city list of the client corresponds to the required area of the server, so that the client can receive the weather data of the area from the weather database of the server to acquire the weather data of the cities in the city list.
For example, in this embodiment, if the areas corresponding to cities in the city database preset by the client are both towns W and V, it may receive weather data of the corresponding towns W and V from the server-side weather database.
Step S303: when receiving an update client notification pushed from a server, prompting a user and judging whether the user agrees to execute the update; and if so, downloading a corresponding updating program or data from the server side to execute the updating.
When receiving a notification of an update client pushed by the server, the client may prompt the user for the update and wait for feedback from the user to determine whether the user agrees to perform the update; if the user agrees to perform the update, the client may download a corresponding update program or data from the server to perform the corresponding update.
Step S303 may also include using a case where the subject does not agree to perform the update: if the usage principal does not agree to perform the update, the usage principal is provided access to learn about the update.
Typically, the entry for the update is a URL, which typically points to a specification file on the update client located on the server side, e.g., specifying the new functionality of the update. The client refuses the update and ignores the update, but provides the client with relevant access to the update, such as viewing new functionality. Of course, the entry to know the update may also be a description file downloaded to the client.
One advantage of this solution is that the client refuses the update and does not affect the correctness of the weather query result, and may only affect the breadth of the weather query result, and the older version client that cannot perform the update can be normally used without being affected.
For example, in the case that the city database needs to be updated, if the client does not perform updating, since the frequency of city list change in the city database stored by the client is low, the use of the client for querying weather data is not greatly influenced.
The scheme also provides a device for processing the weather resource data by the client. Please refer to fig. 4, which is a schematic diagram illustrating an embodiment of an apparatus for processing weather resource data by a client according to a fourth embodiment of the present disclosure. Since the apparatus embodiments are substantially similar to the method embodiments, they are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for relevant points. The device embodiments described below are merely illustrative. The device for processing the weather resource data by the client comprises:
a unit 401 for receiving weather data of a required city, configured to receive weather data of a required area corresponding to the required city from a weather database of a server according to a city list in a preset city database;
an update client program and data unit 403, configured to, when receiving an update client notification pushed from the server, prompt a user and determine whether the user agrees to perform the update; and if so, downloading a corresponding updating program or data from the server side to execute the updating.
The scheme also provides the electronic equipment. Please refer to fig. 5, which is a schematic diagram of an embodiment of an electronic device for processing weather resource data at a server according to a fifth embodiment of the present disclosure. Since the electronic device embodiments are substantially similar to the method embodiments, they are described relatively simply, and reference may be made to some descriptions of the method embodiments for relevant points. The electronic device embodiments described below are merely illustrative. The electronic device includes:
a display 501;
a processor 503;
a memory 505 for storing a program for processing weather resource data at a server, the program, when read and executed by the processor 503, performs the following operations: classifying each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance; reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data; if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or defective data exists in the read weather data according to a preset evaluation standard, reading the weather data which is missing or defective in the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data; and updating a weather database for the client to read by using the preferred weather data.
Although the present invention has been described with reference to the preferred embodiments, it is not intended to be limited to the embodiments, and those skilled in the art can make modifications and changes without departing from the spirit and scope of the present invention.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
1. Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include non-transitory computer readable media (transient media), such as modulated data signals and carrier waves.
2. As will be appreciated by one skilled in the art, embodiments of the present solution may be provided as a method, system, or computer program product. Accordingly, the present solution may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present solution may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.

Claims (18)

1. A method for processing weather resource data at a server side is characterized by comprising the following steps:
classifying each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance;
reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data;
if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or defective data exists in the read weather data according to a preset evaluation standard, reading the weather data which is missing or defective in the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data;
updating a weather database for the client to read by using the preferred weather data;
wherein the method further comprises:
according to the requirements of a client on a required area and a required time period of weather data, the weather data of the required area and the required time period corresponding to the client are customized in advance, and the weather data customized corresponding to the client are stored in the weather database.
2. The method for processing weather resource data at the server side according to claim 1, wherein the preset evaluation criterion includes: data accuracy, data immediacy and/or data interface usability; the higher the data accuracy, the data instantaneity and the usability of the data interface are, the higher the evaluation level of the corresponding weather data source is.
3. The method for processing weather resource data at the server end as claimed in claim 1, wherein each weather data source corresponds to one evaluation level.
4. The method for processing weather resource data at the server side according to claim 1, wherein the step of ranking each weather data source according to a preset evaluation criterion and corresponding the weather data source to different evaluation levels comprises:
and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
5. The method for processing weather resource data at a server side according to claim 1, wherein the step of reading the weather data of the desired area from the weather data source corresponding to the highest evaluation level of the desired area and using the read weather data as the preferred weather data is repeatedly performed at preset fixed time intervals.
6. The method for processing weather resource data at a server side according to claim 1, wherein after the step of reading the weather data of a desired area from the weather data source corresponding to the highest evaluation level of the desired area and before the step of reading the weather data as preferred weather data are performed, and after the step of reading the weather data of a desired area from the weather data source corresponding to the next evaluation level of the desired area and before the step of performing the step of adding the read weather data to the preferred weather data are performed, the following steps are performed:
judging whether weather data of a required area in a required time period is read or not; if yes, entering the next step; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and entering the next step until the weather data of the required area in the required time period is read.
7. The method for processing weather resource data at a server side of claim 1, wherein the defect data comprises: data that cannot be read, have insufficient bits stored, or have errors transferred.
8. The method for processing weather resource data at a server side according to claim 1, wherein before the step of updating a weather database for a client to read using the preferred weather data is performed, the following steps are performed:
and creating the weather database for the client to read at the server side.
9. The method for processing weather resource data at the server side according to claim 1, wherein the weather database for the client side to read is located locally at the server side.
10. The method for processing weather resource data at a server side according to claim 1, wherein the customized weather data is provided to a client when the client requests the weather data.
11. An apparatus for processing weather resource data at a server, comprising:
the weather data source evaluation grade determining unit is used for grading each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance;
the weather data acquisition and optimization unit is used for reading the weather data of the required area from the weather data source corresponding to the highest evaluation grade of the required area and taking the read weather data as the preferable weather data;
a supplementary preferred weather data unit, configured to, if the weather data corresponding to the required area is incomplete in the weather data source corresponding to the highest evaluation level of the required area, or it is determined according to a predetermined evaluation criterion that defective data exists in the read weather data, read the missing or defective weather data of the required area from the weather data source corresponding to the next evaluation level of the required area, and supplement the read weather data to the preferred weather data;
the weather database updating unit is used for updating a weather database for the client to read by using the preferred weather data;
the device also customizes the weather data of the required area and the required time period corresponding to the client in advance according to the requirements of the client on the required area and the required time period of the weather data, and stores the weather data customized corresponding to the client in the weather database.
12. The apparatus for processing weather resource data at a server end according to claim 11, wherein the means for determining the rating level of the weather data source is configured to:
and if the weather data source does not work normally, reducing the evaluation level to the lowest level until the weather data source returns to work normally.
13. The apparatus for processing weather resource data at a server end according to claim 11, wherein the acquiring the preferred weather data unit and supplementing the preferred weather data unit include:
judging whether weather data of a required area in a required time period is read or not; if yes, triggering the next unit; and if not, reading the weather data of the required area in the required time period from the currently read weather data source of the next evaluation level of the weather data source, and triggering the next unit until the weather data of the required area in the required time period is read.
14. The apparatus for processing weather resource data at a server end according to claim 11, comprising:
and providing a client customized weather data unit for providing the customized weather data to the client when the client requests the weather data.
15. A method for processing weather resource data by a client, which is used in combination with the method for processing weather resource data by a server according to any one of claims 1 to 10, and comprises:
receiving weather data of a required area corresponding to a required city from a weather database of a server side according to a city list in a preset city database;
when receiving an update client notification pushed from a server, prompting a user and judging whether the user agrees to execute the update; if yes, downloading a corresponding updating program or data from the server side to execute the updating;
wherein the method further comprises:
and receiving the pre-customized weather data of the required area and the required time period corresponding to the client provided by the server.
16. The method for processing weather resource data at a client side according to claim 15, wherein the step of prompting a user and determining whether the user agrees to perform the update when receiving an update client notification pushed from a server side comprises: if not, an entry is provided to the usage principal to learn about the update.
17. An apparatus for processing weather resource data at a client, which is used with the apparatus for processing weather resource data at a server according to any one of claims 11 to 14, comprising:
the system comprises a unit for receiving weather data of a required city, a unit for receiving weather data of the required area corresponding to the required city from a weather database of a server side according to a city list in a preset city database;
the system comprises an update client program and data unit, a server and a server, wherein the update client program and data unit is used for prompting a use subject and judging whether the use subject agrees to execute the update or not when receiving an update client notification pushed from the server; if yes, downloading a corresponding updating program or data from the server side to execute the updating;
the device also accepts the pre-customized weather data of the required area and the required time period corresponding to the client terminal, which are provided by the server terminal.
18. An electronic device, characterized in that the electronic device comprises:
a display;
a processor;
a memory for storing a program for processing weather resource data at a server, the program, when read and executed by the processor, performing the following operations: classifying each weather data source according to a preset evaluation standard, so that each weather data source corresponds to an evaluation grade with regional relevance; reading weather data of the required area from the weather data source corresponding to the highest evaluation level of the required area, and taking the read weather data as preferred weather data; if the weather data corresponding to the required area in the weather data source corresponding to the highest evaluation level of the required area is incomplete, or defective data exists in the read weather data according to a preset evaluation standard, reading the weather data which is missing or defective in the required area from the weather data source corresponding to the next evaluation level of the required area, and supplementing the read weather data into the preferred weather data; updating a weather database for the client to read by using the preferred weather data; wherein, the following operations are also executed: according to the requirements of a client on a required area and a required time period of weather data, the weather data of the required area and the required time period corresponding to the client are customized in advance, and the weather data customized corresponding to the client are stored in the weather database.
CN201611033681.7A 2016-11-22 2016-11-22 Method and device for processing weather resource data by server side and client side Active CN106776756B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611033681.7A CN106776756B (en) 2016-11-22 2016-11-22 Method and device for processing weather resource data by server side and client side

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611033681.7A CN106776756B (en) 2016-11-22 2016-11-22 Method and device for processing weather resource data by server side and client side

Publications (2)

Publication Number Publication Date
CN106776756A CN106776756A (en) 2017-05-31
CN106776756B true CN106776756B (en) 2020-12-01

Family

ID=58970974

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611033681.7A Active CN106776756B (en) 2016-11-22 2016-11-22 Method and device for processing weather resource data by server side and client side

Country Status (1)

Country Link
CN (1) CN106776756B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107515794A (en) * 2017-08-31 2017-12-26 江西博瑞彤芸科技有限公司 A kind of meteorological data acquisition methods
CN108519984B (en) * 2018-02-07 2022-11-04 平安科技(深圳)有限公司 Weather data processing method, server and computer readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5480305A (en) * 1993-10-29 1996-01-02 Southwest Research Institute Weather simulation system
CN101821736A (en) * 2007-09-06 2010-09-01 王秦胜塞希亚 Method and system of interacting with server, and method and system for generating and presenting search results
CN103262041A (en) * 2010-11-19 2013-08-21 耐斯特实验公司 Methods and systems for data interchange between a network-connected thermostat and cloud-based management server
CN105743773A (en) * 2016-01-26 2016-07-06 广东欧珀移动通信有限公司 Weather data acquisition method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105787134B (en) * 2016-04-07 2019-09-20 上海智臻智能网络科技股份有限公司 Intelligent answer method, apparatus and system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5480305A (en) * 1993-10-29 1996-01-02 Southwest Research Institute Weather simulation system
CN101821736A (en) * 2007-09-06 2010-09-01 王秦胜塞希亚 Method and system of interacting with server, and method and system for generating and presenting search results
CN103262041A (en) * 2010-11-19 2013-08-21 耐斯特实验公司 Methods and systems for data interchange between a network-connected thermostat and cloud-based management server
CN105743773A (en) * 2016-01-26 2016-07-06 广东欧珀移动通信有限公司 Weather data acquisition method and device

Also Published As

Publication number Publication date
CN106776756A (en) 2017-05-31

Similar Documents

Publication Publication Date Title
CN108055264B (en) Scheduling apparatus and method for push streaming server, and computer-readable storage medium
US20150169786A1 (en) Event stream processing partitioning
US8655943B2 (en) Web server providing access to documents having multiple versions
CN107179940B (en) Task execution method and device
CN109445827B (en) Game updating method and device, electronic equipment and storage medium
JP2012155286A (en) Map data distribution server and map data distribution method
CN110365747B (en) Network request processing method and device, server and computer readable storage medium
CN110601978B (en) Flow distribution control method and device
CN106776756B (en) Method and device for processing weather resource data by server side and client side
US20180219745A1 (en) Identification of networking component application programming interfaces
CN107302444B (en) Enterprise-level search application server cluster automatic capacity expansion method and device
CN110209748B (en) Method and apparatus for indexing geofences
CN107025257B (en) Transaction processing method and device
US20170075937A1 (en) Method and system for handling binary large objects
CN111177589A (en) Address information query method, device, equipment and storage medium
CN117687653A (en) Distribution method and device of system update resources, electronic equipment and storage medium
CN105530323A (en) File upgrading method, related equipment and system
US20190158585A1 (en) Systems and Methods for Server Failover and Load Balancing
CN108628901A (en) A kind of data-updating method and device
CN110955460A (en) Service process starting method and device, electronic equipment and storage medium
US20190087156A1 (en) Sorting a table in analytical databases
US11281791B2 (en) Streaming media distribution management
CN114329058A (en) Image gathering method and device and electronic equipment
CN108923938B (en) Channel selection method and equipment
CN113436699A (en) Method, system, electronic device and storage medium for generating new corona nucleic acid detection report

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant