WO2014001600A1 - A method, an apparatus and a computer program for accessing a database - Google Patents

A method, an apparatus and a computer program for accessing a database Download PDF

Info

Publication number
WO2014001600A1
WO2014001600A1 PCT/FI2012/050659 FI2012050659W WO2014001600A1 WO 2014001600 A1 WO2014001600 A1 WO 2014001600A1 FI 2012050659 W FI2012050659 W FI 2012050659W WO 2014001600 A1 WO2014001600 A1 WO 2014001600A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
data items
storage capacity
database
local
Prior art date
Application number
PCT/FI2012/050659
Other languages
French (fr)
Inventor
Don Sanders
Original Assignee
Nokia Corporation
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 Nokia Corporation filed Critical Nokia Corporation
Priority to PCT/FI2012/050659 priority Critical patent/WO2014001600A1/en
Publication of WO2014001600A1 publication Critical patent/WO2014001600A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • 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/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • G06F16/273Asynchronous replication or reconciliation

Definitions

  • the invention relates to a method, to an apparatus and to a computer program for accessing a database.
  • the invention relates to a method, an apparatus and a computer program for a capacity-limited client to access a database hosted by a server to which the client may connect over a network.
  • Using a client device with limited storage capacity to access a database stored on a server device may pose challenges with respect to making the information of the da- tabase that is most relevant to the user of the client device available also when the client device is not connected to the server device. This may be especially pronounced in case the client device is used to access a number of databases.
  • an apparatus comprising a memory management portion for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database and a database management portion.
  • the memory management portion is configured to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine re- quired storage capacity for storing the data selected for retrieval, and to, determine available storage capacity for the given local database.
  • the database management portion is configured to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accord- ance with a predetermined rule to increase storage capacity available for the given local database.
  • an apparatus comprising at least one processor and at least one memory including computer program code for one or more programs, the at least one memory and the computer program code configured to, with the at least one processor, cause the apparatus at least to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine re- quired storage capacity for storing the data selected for retrieval , to determine available storage capacity for the given local database; and to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
  • an apparatus comprising means for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, means for determining required storage capacity for storing the data selected for re- trieval, means for determining available storage capacity for the given local database; and means removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local data- base.
  • a method comprising obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determining required storage capacity for storing the data selected for retrieval, determining availa- ble storage capacity for the given local database; and removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
  • a computer program including one or more sequences of one or more instructions which, when executed by one or more processors, cause an apparatus at least to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine required storage capacity for storing the data selected for retrieval, to determine available storage capacity for the given local database; and to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
  • the computer program may be embodied on a volatile or a non-volatile computer- readable record medium, for example as a computer program product comprising at least one computer readable non-transitory medium having program code stored thereon, the program which when executed by an apparatus cause the apparatus at least to perform the operations described hereinbefore for the computer program ac- cording to the fifth aspect of the invention.
  • Figure 1 schematically illustrates an exemplifying arrangement in accordance with an embodiment of the invention.
  • Figure 2 schematically illustrates an exemplifying arrangement in accordance with an embodiment of the invention.
  • Figure 3 schematically illustrates a concept of data arranged into a database in accordance with an embodiment of the invention.
  • Figure 4 schematically illustrates some details of a client and a server in accordance with an embodiment of the invention.
  • FIG. 5 illustrates a method in accordance with an embodiment of the invention.
  • Figure 6 illustrates a method in accordance with an embodiment of the invention.
  • Figure 7 schematically illustrates an apparatus in accordance with an embodiment of the invention.
  • FIG. 8 schematically illustrates an apparatus in accordance with an embodiment of the invention.
  • Figure 1 schematically illustrates an exemplifying arrangement 100 comprising clients 1 10, 120, a server 130 and a second server 140.
  • the clients 1 10 120 may be connected to the server 130 via a network 150 and may hence communicate with the server 130 over the network 150.
  • the second server 140 may be connected to the server 130 via the network 150 and may hence communicate with the server 130 over the network 150.
  • the server 130 and the second server 140 are both illustrated as a single entity for clarity of illustration and description. However, in general the server 130 and/or the second server 140 may be considered as logical entities, each of which may be embodied as one or more server devices.
  • the network 150 is illustrated as a single network that is able to connect the client 1 10, 120 to the server 130.
  • the network 150 may comprise a number of networks of similar type and/or a number of networks of different type.
  • the client 1 10, 120 may communicate with the server 130 via a wireless network and/or via a wireline network.
  • the second server 140 typically communicates with the server 130 via a wireline network, although wireless communication between the second server 140 and the server 130 is also possible.
  • the communication between the client 1 10, 120 and the server 130 may comprise transfer of data and/or control information from the client 1 10, 120 to the server 130, from the server 130 to the client 1 10, 120, or in both directions.
  • the communication between the server 130 and the second server 140 may comprise transfer of data and/or control information from the server 130 to the second server 140, from the second server 140 to the server 130, or in both directions.
  • the client 1 10, 120 may be further connected to and communicate with further servers, such as the second server 140 and/or further servers, and the server 130 may be connected to and com- municate with further clients and/or further servers.
  • the client 1 10 may be embodied as a mobile device or a component thereof, the mobile device being connectable to the server 130 via an access network involving a wireless link, whereas the client 120 may be connectable to the server 130 via an access network involving only wireline links.
  • the wireless link and/or the wireline link may employ any communication technology and/or communication protocol suitable for transferring data known in the art.
  • database will be used to refer to data or information stored in a manner exhibiting a predetermined structure and/or facilitating ac- cess to data in a predetermined manner.
  • database although predominantly using the term database to refer to such data storage arrangement, is not limited to a data storage arrangement that is explicitly referred to as a database.
  • the server 130 may be configured to host a database 230 stored in a memory available to the server 130, whereas the client 1 10 may be configured to host a database 210 stored in a memory of the client 1 10 or in a memory otherwise accessible by the client 1 10, as schematically illustrated in Figure 2.
  • the database 210 in the client 1 10 may be referred to as a local database or a local copy of the database 230, whereas the database 230 hosted by the server 130 may be referred to as a remote database.
  • the remote database 230 is typically stored in a single physical device, e.g. a server device acting as the server 130 or comprising the server 130.
  • the server 130 may be a logical entity embodied using one or more server devices, and hence the remote database 230 may be distributed to two or more devices instead of storing the whole remote database 230 in a single device.
  • the information stored into a database may be considered to be conceptually arranged as a number of data items, each data item comprising one or more data elements, as schematically illustrated in Figure 3.
  • Figure 3 illustrates the data items to be arranged as rows of a table and the data elements to be arranged as columns of the table, this is merely for purposes of illustration of the concepts of the data items and the data elements, and the data items and the data elements within the database 210, 220, 230 may be arranged in any order and/or into any suitable data structure(s) in view of the characteristics, structure and requirements of a given database.
  • Figure 3 illustrates data elements of data items of the database 210, 220, 230 to be of identical size, this is just for the purpose of clarity of illustration and respective data elements of data items of a database 210, 220, 230 may have different sizes - consequently possibly resulting in a database 210, 220, 230, comprising data items of different sizes.
  • the information stored into a database 210, 220, 230 may exhibit further structural elements.
  • a database may be arranged into a number of tables, each table of the database 210, 220, 230 comprising a number of data items, each data item comprising one or more data elements. Consequently, Figure 3 may be consid- ered to conceptually illustrate information stored in a table of a database 210, 220, 230.
  • the remote database 230 may be considered as a main database containing a full set of information, whereas the local database 210 typically comprises a subset of the full set of information of the remote database 230.
  • the local database 210 may comprise full set of data elements for a subset of data items stored in the remote database 230.
  • the local database 210 may comprise a subset of data elements for all data items stored in the remote database 230 or the local database 210 may comprise a subset of data elements for a subset of the data items stored in the remote database 230.
  • the local database 210 may comprise a full copy of the information stored in the remote database 230, e.g.
  • the amount of data stored in the local database 210 typically depends e.g. on one or more of the storage capacity available to the client 1 10, processing capacity available to the client 1 10, characteristics of the communication link between the client 1 10 and the server 130, preferences defined by a user/administrator operating the client 1 10 or the local database 210 and/or by a user/administrator operating the server 130 or the remote database 230, etc.
  • the local database 210 hence facilitates ac- cess to at least a portion of the information stored in the remote database 230 also when the client 1 10 is not connected to the server 130 hosting the remote database 230.
  • the client 120 may host a database 220, stored in a memory accessible by the client 120, as further illustrated in Figure 2.
  • the database 220 may be considered as a se- cond local database providing a copy of at least part of the information stored in the remote database 230, as described hereinbefore for the local database 210.
  • the local database 210, 220 may exhibit internal structure different from that of the remote database 230. Alternatively or additionally, the local database 210, 220 may provide access to the information stored therein in a manner different from that pro- vided by the remote database 230. In case the local database 210, 220 employs internal structure different from that of the remote database 230 and, in particular, the means for accessing the local database 210, 230 provide the data in a format different from that suitable for accessing the remote database 230, the client 1 10, 120 may be configured to provide a function for converting data retrieved from the local database 210, 220 to a format suitable for introducing to the remote database 230 and/or a function for converting data obtained from the remote database 230 to a format suitable for storing into the local database 210, 220.
  • the client 1 10 may be configured to enable local modification of the content of the local database 210.
  • the local modification of the content of the local database 210 may comprise deletion of a data item stored in the local database 210, modification of a data item stored in the local database 210 or introduction of a new data item in the local database 210.
  • the modification of a data item may comprise e.g. modification of one or more data elements of the data item, deletion of one or more data elements of the data item and/or introduction of one or more data elements to the data item.
  • the local modification may be initiated by a user operating the client 1 10, 120.
  • the client may be configured to apply local modification of the local database 210, 220 only in case the client 210, 220 is not currently in connection with the server 130 hosting the remote database 230, whereas a modification initiated by a user operating the client 1 10, 120 may be directly applied to the remote database 230 when the client 1 10, 120 is in connected with the server 130 and hence has an access to the remote database 230.
  • Local modification of the local database 210, 220 may hence introduce one or more new data items to the local database 210, 220, delete one or more data items from the local database 210, 220 and/or modify content of one or more data elements of one or more data items of the local database 210, 220.
  • the local database 210, 220 and the remote database 230 which is the main database that may be accessible by a number of clients 1 10, 120, synchronized e.g.
  • deletion of a data item from the local database 210, 220 and/or modification of one or more data elements of a data item in the local database 210, 220 may be indicated as tentative or pending modifications in the client 1 10, 120 to be exported to the remote database 230 as part of a subsequent synchronization between the local database 210, 220 and the remote database 230.
  • a pending modification of a data item may be indicated by setting a data element of the data item provided for indicating a pending modification of the data item and/or the type of the modification.
  • a pending modification in the client 1 10, 120 may be facilitated for example by augmenting a data item of the local database 210, 220 subject to modification with one or more data elements descriptive of the modification.
  • a data item deleted from the local database 210, 220 may be provided or augmented with a data element indicating pending deletion of the respective data item or one or more data elements thereof from the remote da- tabase 230.
  • a data item one or more data elements of which are modified may be provided or augmented with one or more data elements indicating pending change(s) to the data item.
  • a pending introduction of a new data item to the local database 210, 220 may be implemented by inserting a new data item to the local database 210, 220 and providing or augmenting the new data item with a data element indicating the new data item to be a pending new data item to be introduced to the remote database 230.
  • a data structure separate from the local database 210, 220 may be employed.
  • a data structure may be referred to as a (local) modification database.
  • the modification database may exhibit a structure similar to that of the local database 210, 220 with possible further data elements augmented to some or all of the data items of the modification database to in- dicate nature of the respective modification.
  • the modification database may employ a structure different from that of the local database 210, 220.
  • the modification database may, for example, comprise a table or an array comprising tuples providing a reference to a to-be-modified data item of the local database 210, 220 and a data item indicative of the respective pending action, e.g. deletion of a data item, introduction of a new data item or indication of one or more modified data elements of a data item and the modifications thereof.
  • the server 130 may be configured to enable local modification of the content of the remote database 230.
  • the local modification may be initiated e.g. via a client directly connected to the server 130 by the user operating the client for example by applying an operation that results in the client requesting the server 130 to modify the content of the remote database 230. If such local modification of the remote database 230 is carried out e.g. via the client 120, the local modification is reflected to the local database 210 at the client 1 10 only after a subsequent synchronization between the local database 210 and the remote database 230.
  • the local modification of the remote database 230 in the server 130 may be performed in response to a request received from another server, e.g. from the server 140.
  • the client 1 10, 120 and the server 130 may be configured to keep the local database 210, 220 and the remote database 230 synchronized.
  • the remote data- base 230 may be synchronized with one or more local databases 210, 220 hosted by one or more separate clients 1 10, 120.
  • the synchronization between the local data- base 210, 220 and the remote database 230 may be carried out e.g. upon establishing a connection between the client 1 10, 120 and the server 130 and/or upon closing the connection between the client 1 10, 120 and the server 130.
  • the synchronization may be carried out periodically e.g. at fixed temporal intervals, in response to a request initiated e.g.
  • the client 1 10, 120 may be configured to establish a connection with the server 230 periodically, e.g. at fixed temporal intervals, to synchronize the local database 210, 220 with the remote database 230.
  • the synchronization may comprise modification of the content of the remote database 230 based on modifications of the local database 210, 220 that have been applied since the most recent synchronization between the local database 210, 220 and the remote database 230 and/or modification of the content of the local database 210, 220 based on the modifications of the remote database 230 applied since the most recent synchronization between the local database 210, 220 and the remote database 230.
  • modifications of the remote database 230 based on modifications of the local database 210, 220 that have been applied since the most recent synchronization between the local database 210, 220 and the remote database 230.
  • concepts related to synchronization of the remote database 230 hosted by the server 130 with one or more local databases 210, 220, each hosted by separate client 1 10, 120 have been described.
  • a client may host one or more local databases, each local database to be synchronized with a respective remote database.
  • the remote databases may be hosted by one or more servers.
  • the local database 210, 220 may be able to store either the full set of information provided in the remote database 230 or the local database 210, 220 may be able to store only a portion of the information provided in the remote database 230.
  • the limiting factor is the storage capacity available for the client 1 10, 120 for storing the local database 210, 220.
  • the capacity-limiting factor may be the physical capacity of the storage space available for the client 1 10, 120, or there may be other factors that limit the overall storage capacity available for the client 1 10, 120 allocated for storing the local database 210, 220.
  • the client 1 10, 120 is embodied as a multi-purpose client device or as a component of such a device.
  • a multi-purpose client device may be e.g. a smartphone that is typically capable of, in addition to making phone calls, e.g. accessing email account(s), playing music, cap- turing and viewing photographs, etc., hence possibly storing emails of one or more email accounts, music files of one or more music libraries, photographs arranged into one or more albums etc. - each of these possibly constituting a local database of its own that may be synchronized over a network connection with a respective remote database hosted by a server.
  • Such a multi-purpose client device is a device designed to be used as a music player as a primary function, which is typically also capable of accessing email account(s), capturing and viewing photographs, etc.
  • the client 1 10, 120 may host one or more separate local databases making use of the limited overall storage capacity available for the client 1 10, 120, thereby limiting the storage capacity available for a given local database.
  • the client 1 10, 120 may be configured to store only a portion of the information provided in the respective remote database due to a limited storage capacity available for the client 1 10, 120 and/or in order to ensure sufficient storage capacity also for the other local databases, e.g. by storing in the given local database a subset of data items available in the respective remote database and/or by storing in the given local database a subset of data elements available for all or some of the data items in the respective remote database, as described hereinbefore.
  • the client 1 10, 120 may be configured to remove one or more data elements of one or more data items from one or more of the one or more local databases as part of the synchronization process of the given local database in order to ensure that the most relevant pieces of information in the one or more remote databases are available to the client 1 10, 120 also when the client 1 10, 120 is not connected to the server(s) host- ing the respective remote databases.
  • Removing a data element or a data item from a local database may comprise exporting the data element or the data item to the respective remote database and/or deleting the data element or the data item from the local database.
  • Figure 4 schematically illustrates the client 1 10 in further detail in order to illustrate aspects related to synchronizing one or more local databases with respective one or more remote databases.
  • the client 1 10 comprises a memory management portion 1 12 for managing overall storage capacity allocated for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230' and a database management portion 1 14 for managing data transfer to and from the one or more local databases 210, 210'.
  • the memory management portion 1 12 and the database management portion 1 14 are operatively coupled to each other.
  • the client 1 10 is configured to host the one or more local databases 210, 210' stored in a memory 1 16 accessible by the client 1 10.
  • the memory 1 16 may be also employed to store any further information associated with the one or more local databases 210, 210'.
  • Figure 4 further schematically illustrates the server 130 hosting the remote database 230 stored in a memory 136 accessible by the server 130 and a second server 130' hosting the remote database 230' stored in a memory 136' accessible by the server 130'.
  • the memories 136, 136' may be also employed to store any further information associated with the respective remote database 230, 230'.
  • the client 1 10 and the server 130 may be configured to keep the local database 210 and the remote data- base 230 synchronized, whereas the client 1 10 and the server 130' may be configured to keep the local database 210' and the remote database 230' synchronized.
  • the server 130 may be further configured to keep the remote database 230 synchronized with another local database hosted by another client and/or another server (not shown) and the server 130' may be further configured to keep the remote database 230' synchronized with another local database hosted by another client and/or another server (not shown).
  • the remote databases 230, 230' are illustrated to be hosted by separate servers 130, 130', respectively. However, the remote databases 220, 220' may be hosted by a single server, e.g. the server 130 or the second server 130'. Moreover, in Figure 4 the client 1 10 is illustrated with two local databases 210, 210' corresponding to the remote databases 220, 220', respectively. However, the client 1 10 may host only a single local database or the client 1 10 may host more than two local databases with the respective remote databases hosted by one or more servers.
  • the memory management portion 1 12 is configured to obtain information indicative of data selected for retrieval from the remote database 230 for storage in the local database 210.
  • the data selected for retrieval from the remote database 230 comprises one or more data elements of one or more data items in one or more tables of the remote database 230.
  • the selection of data items and/or data elements may be based, for example, on predetermined synchronization settings and/or on a user action resulting in a request for a certain set of data elements of a certain set of data items available in the remote database 230, and the memory management por- tion 1 12 (or the database management portion 1 14) may be configured to select the data for retrieval accordingly.
  • the selection of data items and/or data elements may be based at least in part on the amount of storage capacity currently available for storing the local database 210 and/or the amount of data available for retrieval in the remote database 230.
  • the memory management portion 1 12 (or the database management portion 1 14) may be configured to select a subset of data items, and possibly a subset of data elements of the selected data items, for retrieval in response to the amount of data available for retrieval in the remote data- base 230 exceeds a predetermined threshold such that the data items and data elements thereof are selected in accordance with the amount of storage capacity available for storing the local database 210.
  • the data selected for retrieval may comprise one or more data elements of one or more data items of the remote database that fulfill predetermined criteria.
  • the data items that fulfill the predetermine criteria may comprise basically any subset of the data stored in the remote database 230, e.g. all data elements of all data items of a selected table of the remote database 230, all data elements of one or more selected data items in a selected table of the remote database 230 or one or more selected data elements of one or more selected data items of a selected table of the remote database 230.
  • the data selected for retrieval may comprise all data elements of all data items in all tables of the remote database 230, in other words the predetermined criteria may involve selecting all data available for retrieval in the remote database 230.
  • the data items of the remote database 230 that fulfill predetermined criteria may comprise data items of the remote database 230 that have been modified within a first predetermined period of time. Applying such a period of time as a criterion for selecting the data for retrieval enables, for example, selecting the data items that are most recently introduced to the remote database 230 and/or selecting the data items of the remote database 230 that are most recently modified. This may facilitate selecting the data items of the remote database 230 that are not stored in the local database 210. As another example, application of such a period of time as a criterion for selecting data for retrieval enables selecting the data items introduced and/or modified within an arbitrary time period of interest. As another example of selecting a subset of data items for retrieval, the data items of the remote database 230 that that fulfill predetermined criteria may comprise the data items that have been accessed within a (second) predetermined period of time.
  • the data items of the remote database 230 may comprise a data element indicating the date and time of introduction of respective data item to the database and/or a data element indicating the date and time of the most recent modification of the respective data item, wherein for a newly introduced data item the most recent modification is the introduction (or creation) of the data item.
  • the data items of the remote database 230 may, alternatively or additionally, comprise a data element indicating the most recent access to the data item, thereby facilitating e.g. identification of the most recently accessed data items.
  • the data items of the remote database 230 that that fulfill a predetermined criteria may comprise the data items that have a size not exceeding a predetermined threshold size.
  • the data items of the remote database 230 may comprise a data element indicating the size of the respective data item.
  • the data selected for retrieval may comprise one or more data elements of a predetermined fixed number of data items available in the remote database 230 or a predetermined maximum number of data items available in the remote database 230.
  • such an approach may be applied in order to select a number of most recently introduced data items of the remote database 230, a number of most recently modified data items of the remote database 230 and/or a number of most recently accessed data items of the remote database 230 such that the number of selected data items does not exceed a predefined maximum number of data items.
  • the data selected for retrieval may comprise one or more data elements of one or more data items of the remote database that fulfill predeter- mined criteria.
  • the one or more data elements may comprise all data elements or a predetermined subset of data elements for each data item fulfilling the predetermined criteria. Retrieving a predetermined subset of data elements may facilitate retrieving a fixed predetermined subset of data elements for data items not previously stored in the local database 210 and/or retrieving one or more data elements to complement a data item already stored in the local database 210 by retrieving additional data elements thereof from the remote database 230.
  • the one or more data elements may also be selected in accordance with a criterion, e.g.
  • the data items of the remote database 230 may comprise one or more data elements indicating the sizes of data elements of the respective data item.
  • the size indication may be provided for all data elements of a data item or for a subset of the data elements of a data item.
  • the server 130 hosting the remote database 230 may be configured to provide in- formation characterizing the data stored in the remote database 230 in response to a request.
  • the server 130 may be configured, for example, to provide information indicating the number of all data items stored in the remote database 230, the number of data items stored in a specific table of the remote database 230, the number of data items of the remote database 230 that fulfill predetermined criteria regarding e.g. date and time of introduction of, modification of or access to the respective data item, an identifier of the respective data item indicative e.g. of a sequence number of the respective data item and/or size of the respective data item in response to a request.
  • the memory management portion 1 14 may be configured to request information indicative of the respective number of data item from the server 130.
  • the server 130 may be configured to provide information indicative of sizes of the data items stored in the remote database 230 and/or sizes of one or more data elements of data items stored in the remote database 230 in response to a request.
  • the server 130 may be configured to provide information indicating sizes of one or more data elements of one or more data items that fulfill predetermined criterion regarding e.g. date and time of the most recent modification of and/or access to the respective data item. Consequently, the memory management portion 1 14 may be configured to request such information from the server 130.
  • the memory management portion 1 12 is configured to determine the amount of stor- age capacity required for storing the data selected for retrieval from the remote database 230 in order to facilitate memory management of the overall storage capacity for storing the one or more local databases.
  • Determination of the required storage capacity may comprise obtaining information indicative of the number of data items selected for retrieval from the remote database 230 and information indicative of sizes of the data items selected for retrieval. Infor- mation indicating the number of data items selected for retrieval may be obtained, for example from the server 130 in response to a request, as described hereinbefore.
  • the information indicative of sizes may comprise a size of a data item estimated on basis of an estimated size of a data item or on estimated sizes of one or more data elements of the data items selected for retrieval.
  • An estimated size of a data element may be based, for example, on a priori knowledge of a fixed size of the respective data element or on an average size of the respective data element derived on basis of statistical information on sizes of data elements of respective type.
  • an estimated size of a data item may be based e.g. on a priori knowledge of a fixed size of the respective data item or on an average size of the respective data item derived on basis of statistical information on sizes of data items of respective type.
  • an estimated size of a data item may be based on estimated sizes of data elements comprised therein.
  • the required storage capacity may be indicated as number of bits, as number bytes or as another suitable measure descriptive of storage capacity. In particular, in case of data elements and/or data items of fixed size the required storage capacity may be indicated as number of data items.
  • obtaining information indicative of the required storage capacity may comprise obtaining information indicative of actual sizes of the data items selected for retrieval and/or obtaining information indicative of actual sizes of one or more data elements of the data items selected for retrieval. Such information may be obtained, for example, from the server 130 in response to a request, as described hereinbefore.
  • the memory management portion 1 12 is further configured to determine available storage capacity for the local database 210. Like the required storage capacity, also the available storage capacity may be indicated as number of bits, as number bytes or as another suitable measure descriptive of storage capacity, e.g. as number of data items in case of the data selected for retrieval comprises data elements and/or data items of fixed size.
  • Each local database of the one or more local databases 210, 210' may have a dedicated portion of the overall storage capacity reserved for the one or more local data- bases 210, 210' at its disposal.
  • the overall storage capacity may be partitioned evenly between the one or more local databases 210, 210'. This may be considered as a safe approach in terms of ensuring that the local database 210 cannot reserve too large a portion of the overall storage capacity hence leaving insufficient storage capacity for the other local databases, while on the other hand such an approach may result in inefficient usage of the overall storage capacity e.g. in case some of the other local databases make use only a (small) portion of their dedicated portions of the overall storage capacity due to inflexibility to partition the overall storage capacity according to expected storage requirements of the one or more local databases 210, 210'.
  • the overall storage capacity may be partitioned between one or more local databases 210, 210' for example in view of the expected size of each local database 210, 210' or on basis of a user preference.
  • the available storage capacity for the local database 210 may comprise available, i.e. unused, storage capacity in a portion of the overall storage capacity dedicated to the local database 210. While this approach enables taking into account expected different storage requirements of dif- ferent local databases, there is still some inflexibility to re-use the unused portions of the dedicated portions of the overall storage capacity allocated for the other local databases in case dedicated portion allocated to the local database 210 is becoming fully occupied.
  • the local database 210 may share a portion of the overall storage capacity reserved for the one or more local databases 210, 210' with one or more other local databases. Such a portion may be the overall storage capacity reserved for the one or more local databases 210, 210' as a whole or a sub-portion thereof. Consequently, the storage capacity currently available for the local database 210 may comprise available, i.e. unused, storage capacity in the portion of the overall storage capacity shared by the local database 210 and at least one other local database 210' of the one or more local databases 210, 210'. Such an approach enables full flexibility for the local database 210 - and for the other local databases - to make use the available storage capacity in the portion of the overall storage capacity according to the current need.
  • the database management portion 1 14 is configured to remove, in response to the required storage capacity exceeding the available storage capacity for the local database 210, one or more data elements of one or more data items from the one or more local databases 210, 220 in accordance with a predetermined rule to increase storage capacity available for the local database 210.
  • the predetermined rule may define the one or more pending changes introduced to the one or more local databases 210, 210' to be exported to the respective remote databases 230, 230' and/or the one or more data items and the one or more elements thereof to be discarded in order to increase storage capacity available for the local database 210, as described in more detail in the following.
  • removing one or more data elements of one or more data items in accordance with the predetermined rule may comprise exporting one or more pending modifications introduced to the local database 210 to the remote database 230.
  • Exporting may comprise transferring information indicative of the pending modification, e.g. an indication of deletion of a data item or one or more data elements thereof, modified data elements of a modified data item or the modified data item as a whole or a new data item introduced to the local database 210, to the server 130 for storage in the remote database 230.
  • removing one or more data elements of one or more data items in accordance with the predetermined rule may comprise exporting one or more pending changes introduced to the local database 210' to the remote database 230', or - to be more generic - ex- porting one or more pending changes introduced to one or more of the one or more local databases 210, 210' to the respective remote database 230, 230'.
  • removing one or more data elements of one or more data items in accord- ance with the predetermined rule may comprise discarding, e.g. deleting, one or more data elements of one or more data items of the one or more local databases 210, 210'. This may involve discarding only a subset of data elements of one or more items or discarding all data elements of one or more data items from a selected set of local databases.
  • one or more of the one or more local databases 210, 210' comprise pending modifications or changes that cannot be exported to the respective database 230, 230' e.g.
  • Discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items of the local database 210 to make room for the data selected for retrieval from the remote database 230 while not discarding data from the other local databases.
  • the selected set of local databases may comprise only the local database 210.
  • discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items of the local database 210' while not discarding data elements or data items of the local database 210 or - to be more ge- neric - discarding one or more data elements of the one or more local databases excluding the local database 210.
  • the selected set of local databases may comprise one or more the one or more local database 210 excluding the local database 210.
  • discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items from all local databases 210, 210' or from a number of local databases including the local database 210.
  • the selected set of local databases may comprise one or more the one or more local database 210 including the local database 210.
  • Discarding one or more data elements of one or more data items from the selected set of local databases may comprise discarding data elements of data items that have not been introduced to the database or modified within a third predetermined period of time and/or that have not been accessed within a fourth predetermined period of time.
  • this involves keeping the data items that have been intro- swiped/modified or accessed within the third/fourth period of time and discarding the other data items, and this may be viewed as keeping or discarding the data items that fulfill a predetermined criterion with respect to date and time of the their most introduction to the database, the most recent modification thereof and/or the most recent access thereto.
  • such an approach may be employed to discard one or more data elements of data items for which the introduction to the database, the most recent modification and/or the most recent access has occurred before a predetermined date and time.
  • discarding one or more data elements of one or more data items from the selected set of local databases may comprise discarding one or more data elements of a predetermined number of data items.
  • this may comprise discarding one or more data elements of a predetermined number of data items exhibiting the earliest date(s) and time(s) of the most recent modification/access or a predetermined number of data items exhibiting the earliest date(s) and time(s) of their introduction to the database, in other words discarding one or more data elements of the predetermined number of the oldest data items from the selected set of local databases.
  • Selection of data items to be discarded in such a manner may comprise - conceptually or concretely - arranging the data items of the selected set of local databases into an ordered list exhibiting ascending (descending) order of the most recent modification/access to the respective data item or the time and date of introduction of the respective data item to the database and discarding one or more data elements of a predetermined number of data items in the beginning (in the end) of the ordered list of data items.
  • the selection of data items to be discarded may comprise selecting a sufficient number of the oldest data items from the selected set of local databases in order to result in the storage capacity available to the local database 210 to be at least the storage capaci- ty required for storing the data selected for retrieval from the remote database 230.
  • the oldest data items may comprise, for example, the data items exhibiting the earliest date(s) and time(s) of the most recent modification thereof or the most recent access thereto or, as another example, the data items items exhibiting the earliest date(s) and time(s) of their introduction to the database.
  • Discarding one or more data elements of one or more data items may comprise discarding a predetermined subset of data elements.
  • discarding one or more data elements of one or more data items may comprise discarding data elements according to a predefined rule, e.g. discarding data elements having a size exceeding a predefined threshold size. Such a threshold size may be de- fined for a specific data element or for data elements in general.
  • Removing one or more data elements of one or more data items from the one or more local databases 210, 210' may result in the available storage capacity to increase such that the available storage capacity for local database 210 is at least the required storage capacity for storing the data selected for retrieval from the remote database 230. Consequently, the database management portion 1 14 may be configured to retrieve the data selected for retrieval from the remote database 230 and store the retrieved data in the local database 210.
  • the memory management portion 1 12 may be configured to redefine the data selected for retrieval from the remote database 230.
  • the redefinition may comprise selecting a smaller number of data items for retrieval in view of the capacity limitation set by the increased storage capacity available for the local database 210, for example a prede- termined number of data items most recently introduced to the remote database 230 or as many of the data items most recently introduced to the remote database 230 as the increased storage capacity available for the local database 210 allows.
  • the redefinition may comprise selecting a smaller subset of data elements of the selected data items in view of the capacity limitation set by the increased storage capacity available for the local database 210, e.g. by excluding cer- tain data elements of all selected data items or by excluding data elements having a size exceeding a threshold of all selected data items.
  • the memory management portion 1 12 may be configured to terminate the synchronization process.
  • the memory management portion 1 12 may be further configured to provide an indication thereof e.g. to enable the client 1 10 to provide a respective indication to a user of the client 1 10.
  • an exemplifying scenario of synchronizing a local database of the one or more local databases with the respective remote database is provided by using two email accounts to represent the databases.
  • the local database 210 and the respective remote database 230 may be configured to store emails of an email account.
  • one or more folders of an email account may be provided as data items of (a single table of) respective local and remote databases 210, 230, each data item being descriptive of an email message in one of the one or more folders and each data item comprising a data element indica- tive of the respective folder.
  • each folder of an email account may be provided as a table of the respective local and remote databases 210, 230, the table comprising one or more data items, each data item descriptive of an email message of the respective folder.
  • a folder may be provided as separate local databases.
  • a folder may also be referred to as a mailbox and there may be one or more folders, e.g. "inbox", "sent mail”, “drafts”, “deleted items”, etc.
  • a data item descriptive of an email message comprises one or more data elements that are descriptive of elements and/or attributes of the respective email message.
  • the one or more data elements may comprise, as a non-limiting set of examples, data elements descriptive of title of an email message, body of the email message, sender of the email message, recipient(s) of the email message, time of sending/receiving the email mes- sage, level of importance/urgency of the email message, time of most recent modification of the email message, one or more attachments to the email message, sizes of one or more data elements of the data item representing the email message an indication of a folder the email message belongs to, a header of the email message comprising e.g. threading information, etc.
  • the data selected for retrieval from the remote database 230 may comprise, as an example, (at most) a predetermined number of most recently modified data items of the selected tables in order to retrieve the predetermined number of most recently received email messages in the "inbox" and in "sent mail" fold- ers/mailboxes.
  • the data selected for retrieval may comprise all data items that have been modified after a predetermined moment of time.
  • storage capacity allocated to the local database 210 e.g. only a predetermined set of data elements of selected data items may be retrieved from the remote database 230 and stored in the respective local da- tabase 210.
  • the predetermined set of data elements may comprise a header of the email message comprising e.g. threading information.
  • the predetermined set of data elements may comprise e.g. one or more of data elements indicative of the title, message body, sender, recipient(s), time of most recent modification of the email message. Any further data elements of the da- ta items stored in the remote database 230, such as attachment(s) to the email message or even bodies of email messages exceeding a predetermined threshold size, may be retrieved in response to a specific request thereto.
  • the local database 210' and the respective remote database 230' may be configured to store emails of a second email account along the lines described here- inbefore for the databases 210, 230 storing the components of the (first) email account.
  • the data elements and/or data items selected for retrieval from the remote database 230' for synchronizing the local database 210' may apply criteria similar to or different from that applied for synchronization between the local database 210 and the remote database 230.
  • removing one or more data elements of one or more data items from the one or more local databases 210, 210' may comprise first exporting any pending modifi- cations applied locally to the one or more local databases 210, 210' to the respective remote databases 230, 230'. Subsequently, removing one or more data elements of one or more data items may comprise discarding the oldest messages in all email accounts, e.g. the data items of the one or more local databases 210, 210' that have been received/sent earlier than a predetermined moment of time, or all messages stored in the one or more local databases 210, 210'.
  • the data items to be discarded from the one or more local databases 210, 210' may be selected in dependence of the amount of data selected for retrieval from the remote database 230 and/or in dependence of the amount of data available for retrieval in the remote database 230.
  • discarding may comprise discarding one or more data items of the one or more local databases 210, 210' e.g. one by one, starting from the one(s) representing email messages having the earliest date and time of reception/sending, until sufficient storage capacity is available.
  • discarding may comprise discarding all data items of the one or more local databases 210, 210' in response to the storage capacity required for storing the data selected for retrieval from the remote database 230 exceeding a predetermined threshold. Consequently, in case the storage capacity required for storing the data selected for retrieval does not exceed the available storage capacity, the data selected for retrieval may be retrieved from the remote database 230. In contrast, in case the storage capacity required for storing the data selected for retrieval exceeds the available storage capacity despite all data items of the one or more local databases 210, 210' having been discarded, the data selected for retrieval from the remote database 230 may be modified by excluding one or more oldest data items from the data selected for retrieval.
  • the discarding may comprise a step-wise process, comprising first discarding the oldest email messages of the (first) email account, e.g. the data items of the local database 210 that have been received/sent earlier than a predetermined moment of time.
  • the step-wise process may continue with discarding any data elements comprising attachment(s) to respective email messages from all data items of the both email accounts, e.g. by discarding the respective data elements in all data items of the one or more local databases 210, 210'.
  • data items of the local database 210' may be discarded, e.g. one by one, starting from the one(s) having the earliest date and time of reception/sending, until sufficient storage capacity is available, and if needed, the same process may be repeated for the local database 210.
  • the data selected for retrieval from the remote database 230 may be modified such that the data item descriptive of the oldest message, e.g. the one having the earliest date and time of the most recent modification, is dropped from the data items selected for retrieval and required storage capacity for storing the data items selected for retrieval is updated accordingly until the required storage capacity falls below the available storage capacity.
  • a second exemplifying scenario of synchronizing a local database of the one or more local databases with the respective remote database is provided by using an email account and a music library to represent the databases.
  • the local database 210 and the respective remote database 230 may be configured to store emails of an email account.
  • the description provided in this regard for the first exemplifying scenario applies also to the second exemplifying scenario.
  • the local database 210' and the respective remote database 230' may be configured to store a music library.
  • a data item of the databases 210', 230' may be descriptive of an audio item, e.g. a single song, and a data item descriptive of an audio item comprises a data element providing the audio signal representing the audible content of the audio item and one or more data elements that are descriptive of elements and/or attributes of the respective audio item.
  • the one or more data elements that are descriptive of elements and/or attributes of the respective audio item may comprise e.g. data elements descriptive of title of the audio item, title of an album the audio item belongs to, an artist presenting the audio item, duration of the audio item, date and time of most recent access to the audio item, date and time of introducing the audio item in the database 210', 230', etc.
  • the data items descriptive of audio items may be arranged into a single table of the respective database 210', 230'.
  • the databases 210', 230' may further comprise e.g. a table storing data items descriptive of albums and/or a table storing data items descriptive of artists, while the respective data elements of the data items descriptive of audio items may refer to these tables.
  • the data selected for retrieval from the remote database 230' may comprise, as an example, (at most) a predetermined number of most recently introduced data items across all tables of the remote database 230'.
  • the data selected for retrieval may comprise all data items that have been introduced to the database after a predetermined moment of time, e.g. all audio items that have been introduced to the database 230' after the predetermined moment of time.
  • a predetermined moment of time may be the date and time of the most recent synchronization between the local database 210' and the remote database 230'.
  • removing one or more data elements of one or more data items from the one or more local databases 210, 210' may comprise first exporting to any pending modifications to the local database 210 storing the data items descriptive of email messages to the respective remote database 230.
  • any pending modifications to the local database 210' storing audio items may also be exported to the respective remote database 230'.
  • removing one or more data elements of one or more data items comprises discarding the audio items of the local database 210' having an indication of the most recent access thereto earlier than a predetermined moment of time and discarding the oldest email messages of the email account, e.g. the data items of the local database that have been received/sent earlier than the predetermined moment of time. Consequently, in case sufficient storage capacity for the local database 210 is not yet available, removing one or more data elements of one or more data items from the one or more local databases 210, 210' may further comprise discarding any data elements comprising attachment(s) to respective email messages from all data items descriptive of email messages, e.g. by discarding the respective data elements in all data items of the local database 210.
  • data items of the local database 210' descriptive of audio items may be discarded one by one, starting from the one having the earliest date and time of the most recent access thereto, until sufficient storage capacity is availa- ble, and if needed, the same process may be repeated for the data items descriptive of email messages of the local database 210.
  • the data selected for retrieval from the remote database 230 may be modified such that the data item descriptive of the oldest message, e.g. the one having the earliest date and time of the most recent modification, is dropped from the data items selected for retrieval and required storage capacity for storing the data items selected for retrieval is updated accordingly until the required storage capacity falls below the available storage capacity.
  • databases of different structure and comprising data elements and/or data items of different type or nature, as well as different strategies in selection of data items for retrieval from the remote database and in removal of one or more data elements of one or more data items from the one or more local databases equally fall within the scope of the present invention.
  • databases comprising data of different type include databases for storing photographs, video items, calendar entries, address books of messaging or email systems, map data, etc.
  • the operations, procedures and/or functions assigned to the structural units of the client 1 10, i.e. to the memory management portion 1 12 and the database management portion 1 14, may be divided between these portions in a different manner.
  • the client 1 10 may comprise further portions or units that may be configured to perform some of the operations, procedures and/or functions assigned to the above-mentioned portions.
  • the operations, procedures and/or functions assigned to the memory management portion 1 12 and the database management portion 1 14 may be assigned to a single portion or to a single processing unit within the client 1 10.
  • the client 1 10 may be an apparatus for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database comprising means for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, means for determining required storage capacity for storing the data selected for retrieval, means for determining available storage capacity for the given local database and means for removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local data- base.
  • the means may comprise software means, hardware means and/or a combination of software and hardware means.
  • Figure 5 illustrates a method 500 for managing overall storage capacity for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230'.
  • the method 500 comprises obtaining information indicative of data selected for retrieval from the remote database 230 for storage in the local database 210, as illustrated in block 510.
  • the data selected for retrieval may comprise one or more data elements of one or more data items stored in the remote database 230, for example predetermined data elements of data items of the remote database 230 that fulfill predetermined criteria.
  • Such predetermined criteria may be employed to select e.g. one or more data items that have been most recently modified or accessed or one or more data items that have been modified or accessed within a predetermined period of time, as described in detail hereinbefore in context of the memory management portion 1 12.
  • the method 500 further comprises determining required storage capacity for storing the data selected for retrieval, as indicated in block 520.
  • the required storage capacity may be determined, for example, on basis of the number of data items selected for retrieval and sizes thereof.
  • a size of a data item may be a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type, or a size of a data time may be based on actual size(s) of data element(s) and/or data item(s) obtained from the remote database 230, as described in detail hereinbefore in context of the memory management portion 1 12.
  • the method 500 further comprises determining available storage capacity for the local database 210, as indicated in block 530 and as described in detail hereinbefore in context of the memory management portion 1 12.
  • the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
  • the method 500 proceeds to removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule, as indicated in block 550.
  • the removing may involve exporting one or more pending changes or modifications applied to the one or more local databases 210, 210' to the respective remote databases 230, 230' and/or discarding one or more data elements of one or more data items from the one or more local databases, as described in de- tail hereinbefore in context of the database management portion 1 14.
  • removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule may comprising exporting and/or discarding data items such that the available storage capacity is made larger than or equal to the required storage capacity.
  • the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
  • the method 500 may further comprise redetermining the storage capacity available for the local database 210 in response to the increased storage capacity failing to exceed the storage capacity required for storing the data selected for retrieval, as indicated in block 570. Moreover, the method 500 may optionally further comprise, in response to the increased storage capacity falling short of the required storage capacity, reselection of the data selected for retrieval, as indicated in block 580, for example by selecting a smaller number of data items for retrieval in view of the increased storage capacity and/or by selecting a smaller number of data elements of the selected data items in view of the increased storage capacity.
  • the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 in view of the reselection and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
  • the method may comprise, as an option, a comparison of the storage capacity required for storing the data selected for retrieval and the increased storage capacity available for the local database 210.
  • the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
  • the synchronization is terminated and a respective error message may be generated.
  • Figure 6 illustrates a second exemplifying method 800 for managing overall storage capacity for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230'.
  • the method 800 comprises obtaining infor- mation indicative of data selected for retrieval from the remote database 230 for storage in the local database 210, as illustrated in block 810.
  • the data selected for retrieval may comprise one or more data elements of one or more data items stored in the remote database 230, for example predetermined data elements of data items of the remote database 230 that fulfill predetermined criteria.
  • Such predetermined crite- ria may be employed to select e.g.
  • the predetermined criteria may be employed to select a subset of the data items available in the remote database 230 or all data items available in the remote database 230.
  • the method 800 further comprises determining required storage capacity for storing the data selected for retrieval, as indicated in block 820.
  • the required storage capacity may be determined, for example, on basis of the number of data items selected for retrieval and sizes thereof.
  • a size of a data item may be a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type, or a size of a data time may be based on actual size(s) of data element(s) and/or data item(s) obtained from the remote database 230, as described in detail hereinbefore in context of the memory management portion 1 12.
  • the method 800 further comprises determining available storage capacity for the local database 210, as indicated in block 830 and as described in detail hereinbefore in context of the memory management portion 1 12.
  • the storage capacity required for storing the data selected for retrieval is compared to a predetermined threshold serving to indicate an excessive amount of data to be selected for retrieval, as indicated in block 840.
  • the predetermined threshold may be chosen in accordance of the overall storage capacity in disposal of the local database 210.
  • the method 800 may con- tinue from block 540, is indicated in block 850.
  • the method 800 proceeds to removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule, as indicated in block 860.
  • the removing may involve exporting one or more pending changes or modifications applied to the local database 210 to the respective remote database 230 and/or discarding one or more data elements of one or more data items from the local database 210, as described in detail hereinbefore in context of the database management portion 1 14. In particular, this may involve discarding all data items currently stored in the local database 210.
  • the processing proceeds to reselecting the data for retrieval in accordance with a predetermined rule, as indicated in block 870.
  • the predetermined rule may involve reselecting the data items most recently introduced to the remote database 230 and/or the data items most recently accessed in the remote database 230 to be re- trieved e.g. such that the storage capacity required to store the reselected data does not exceed the available storage capacity.
  • the predetermined rule may involve selecting a predetermined number of data items most recently introduced to the remote database 230 and/or the data items most recently accessed in the remote database 230. Consequently, the method 800 may continue from block 540, is indicated in block 850.
  • FIG. 7 schematically illustrates an exemplifying apparatus 600 comprising the client apparatus 610.
  • the client apparatus 610 may be employed as the client 1 10, 1 10' or the client apparatus 610 may comprise the client 1 10, 1 10'.
  • the client apparatus 610 may be an end-product or a module, the term module referring to a unit or an appa- ratus that excludes certain parts or components that may be introduced by an end- manufacturer or by a user to result in an apparatus forming an end-product.
  • the ap- paratus 610 may be implemented as hardware alone, e.g. as a circuit, as a programmable or non-programmable processor, etc., the apparatus 610 may have certain aspects implemented as software (e.g.
  • the apparatus 600 further comprises, a memory 620 for storing the one or more local databases 210, 210' and a communication interface 630, such as a network card or a network adapter enabling wireless or wireline communication with another apparatus.
  • the client apparatus 610 is configured to read from and write to the memory 620 to enable access to the one or more local databases 210, 210' stored therein.
  • the ap- paratus 600 may further comprise a user interface 640 for providing data, commands and/or other input to the client apparatus 610 and/or for receiving data or other output from the client apparatus 610, the user interface 640 comprising for example one or more of a display, a keyboard or keys, a mouse or a respective pointing device, a touchscreen, etc.
  • the apparatus 600 may comprise further components not illustrat- ed in the example of Figure 7.
  • Figure 8 schematically illustrates a second exemplifying apparatus comprising a processor 710, a memory 720 and a communication interface 730, such as a network card or a network adapter enabling wireless or wireline communication with another apparatus.
  • the processor 710 is configured to read from and write to the memory 720.
  • the apparatus 700 may further comprise a user interface 740 for providing data, commands and/or other input to the processor 710 and/or for receiving data or other output from the processor 710, the user interface 740 comprising for example one or more of a display, a keyboard or keys, a mouse or a respective pointing device, a touchscreen, etc.
  • the apparatus 700 may comprise further components not illustrat- ed in the example of Figure 8.
  • processor 710 is presented in the example of Figure 8 as a single component, the processor 710 may be implemented as one or more separate components.
  • memories 620, 720 in the examples of Figures 7 and 8, respectively, are illustrated as single components, each of the memory 620, 720 may be implemented as one or more separate components, some or all of which may be integrated/removable and/or may provide permanent/semi-permanent/ dynamic/cached storage.
  • the apparatus 600, 700 may be embodied for example as a mobile phone, a camera, a video camera, a music player, a gaming device, a laptop computer, a desktop computer, a personal digital assistant (PDA), an internet tablet, a television set, etc.
  • the memory 720 may store the one or more local databases 210, 210', and the memory 720 may store a computer program 750 comprising computer-executable instructions that control the operation of the apparatus 700 when loaded into the processor 710.
  • the computer program 750 may include one or more se- quences of one or more instructions.
  • the computer program 750 may be provided as a computer program code.
  • the processor 710 is able to load and execute the computer program 750 by reading the one or more sequences of one or more instructions included therein from the memory 720.
  • the one or more sequences of one or more instructions may be configured to, when executed by one or more processors, cause an apparatus, for example the apparatus 700, to implement the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'.
  • the apparatus 700 may comprise at least one processor 710 and at least one memory 720 including computer program code for one or more programs, the at least one memory 720 and the computer program code configured to, with the at least one processor 710, cause the apparatus 700 to perform the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'.
  • the computer program 750 may be provided at the apparatus 700 via any suitable delivery mechanism.
  • the delivery mechanism may comprise at least one computer readable non-transitory medium having program code stored thereon, the program code which when executed by an apparatus cause the apparatus at least implement processing to carry out the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'.
  • the delivery mechanism may be for example a computer readable storage medium, a computer program product, a memory device a record medium such as a CD-ROM or DVD, an article of manufacture that tangibly embodies the computer program 750.
  • the delivery mechanism may be a signal configured to reliably transfer the computer program 750.
  • the computer program 750 may implement any of the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10', e.g. those de- scribed in context of the memory management portion 1 12 and/or those described in context of the database management portion 1 14 e.g. as service object that may run as part of a database synchronization software system or as an operating system enabled with a database synchronization functionality.
  • references to a processor should not be understood to encompass only programma- ble processors, but also dedicated circuits such as field-programmable gate arrays (FPGA), application specific circuits (ASIC), signal processors, etc.
  • FPGA field-programmable gate arrays
  • ASIC application specific circuits
  • Signal processors etc.

Abstract

An arrangement, e.g. an apparatus, a method and a computer program for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database is provided. The arrangement comprises obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determining required storage capacity for storing the data selected for retrieval, determining available storage capacity for the given local database; and removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.

Description

A method, an apparatus and a computer program for accessing a database TECHNICAL FIELD
The invention relates to a method, to an apparatus and to a computer program for accessing a database. In particular, the invention relates to a method, an apparatus and a computer program for a capacity-limited client to access a database hosted by a server to which the client may connect over a network.
BACKGROUND
Using a client device with limited storage capacity to access a database stored on a server device may pose challenges with respect to making the information of the da- tabase that is most relevant to the user of the client device available also when the client device is not connected to the server device. This may be especially pronounced in case the client device is used to access a number of databases.
SUMMARY
It is an object of the present invention to provide an approach for efficiently managing storage capacity for locally storing, in a client, information available in one or more databases hosted by one or more servers in such a way that information most relevant to the user is available for the client also when there is no connection to the one or more servers.
According to a first aspect of the present invention, an apparatus is provided, the ap- paratus comprising a memory management portion for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database and a database management portion. The memory management portion is configured to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine re- quired storage capacity for storing the data selected for retrieval, and to, determine available storage capacity for the given local database. The database management portion is configured to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accord- ance with a predetermined rule to increase storage capacity available for the given local database.
According to a second aspect of the present invention, an apparatus is provided, the apparatus comprising at least one processor and at least one memory including computer program code for one or more programs, the at least one memory and the computer program code configured to, with the at least one processor, cause the apparatus at least to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine re- quired storage capacity for storing the data selected for retrieval , to determine available storage capacity for the given local database; and to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
According to a third aspect of the present invention, an apparatus is provided, the apparatus comprising means for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, means for determining required storage capacity for storing the data selected for re- trieval, means for determining available storage capacity for the given local database; and means removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local data- base.
According to a fourth aspect of the present invention, a method is provided, the method comprising obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determining required storage capacity for storing the data selected for retrieval, determining availa- ble storage capacity for the given local database; and removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database. According to a fifth aspect of the present invention, a computer program is provided, the computer program including one or more sequences of one or more instructions which, when executed by one or more processors, cause an apparatus at least to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, to determine required storage capacity for storing the data selected for retrieval, to determine available storage capacity for the given local database; and to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database. The computer program may be embodied on a volatile or a non-volatile computer- readable record medium, for example as a computer program product comprising at least one computer readable non-transitory medium having program code stored thereon, the program which when executed by an apparatus cause the apparatus at least to perform the operations described hereinbefore for the computer program ac- cording to the fifth aspect of the invention.
The exemplifying embodiments of the invention presented in this patent application are not to be interpreted to pose limitations to the applicability of the appended claims. The verb "to comprise" and its derivatives are used in this patent application as an open limitation that does not exclude the existence of also unrecited features. The features described hereinafter are mutually freely combinable unless explicitly stated otherwise.
The novel features which are considered as characteristic of the invention are set forth in particular in the appended claims. The invention itself, however, both as to its construction and its method of operation, together with additional objects and ad- vantages thereof, will be best understood from the following detailed description of specific embodiments when read in connection with the accompanying drawings.
BRIEF DESCRIPTION OF FIGURES
Figure 1 schematically illustrates an exemplifying arrangement in accordance with an embodiment of the invention. Figure 2 schematically illustrates an exemplifying arrangement in accordance with an embodiment of the invention.
Figure 3 schematically illustrates a concept of data arranged into a database in accordance with an embodiment of the invention.
Figure 4 schematically illustrates some details of a client and a server in accordance with an embodiment of the invention.
Figure 5 illustrates a method in accordance with an embodiment of the invention.
Figure 6 illustrates a method in accordance with an embodiment of the invention. Figure 7 schematically illustrates an apparatus in accordance with an embodiment of the invention.
Figure 8 schematically illustrates an apparatus in accordance with an embodiment of the invention. DETAILED DESCRIPTION
Figure 1 schematically illustrates an exemplifying arrangement 100 comprising clients 1 10, 120, a server 130 and a second server 140. The clients 1 10 120 may be connected to the server 130 via a network 150 and may hence communicate with the server 130 over the network 150. The second server 140 may be connected to the server 130 via the network 150 and may hence communicate with the server 130 over the network 150. The server 130 and the second server 140 are both illustrated as a single entity for clarity of illustration and description. However, in general the server 130 and/or the second server 140 may be considered as logical entities, each of which may be embodied as one or more server devices. The network 150 is illustrated as a single network that is able to connect the client 1 10, 120 to the server 130. However, the network 150 may comprise a number of networks of similar type and/or a number of networks of different type. In particular, the client 1 10, 120 may communicate with the server 130 via a wireless network and/or via a wireline network. The second server 140 typically communicates with the server 130 via a wireline network, although wireless communication between the second server 140 and the server 130 is also possible.
The communication between the client 1 10, 120 and the server 130 may comprise transfer of data and/or control information from the client 1 10, 120 to the server 130, from the server 130 to the client 1 10, 120, or in both directions. The communication between the server 130 and the second server 140 may comprise transfer of data and/or control information from the server 130 to the second server 140, from the second server 140 to the server 130, or in both directions. The client 1 10, 120 may be further connected to and communicate with further servers, such as the second server 140 and/or further servers, and the server 130 may be connected to and com- municate with further clients and/or further servers.
As a particular example, the client 1 10 may be embodied as a mobile device or a component thereof, the mobile device being connectable to the server 130 via an access network involving a wireless link, whereas the client 120 may be connectable to the server 130 via an access network involving only wireline links. The wireless link and/or the wireline link may employ any communication technology and/or communication protocol suitable for transferring data known in the art.
Throughout this document the term database will be used to refer to data or information stored in a manner exhibiting a predetermined structure and/or facilitating ac- cess to data in a predetermined manner. Hence, the present invention, although predominantly using the term database to refer to such data storage arrangement, is not limited to a data storage arrangement that is explicitly referred to as a database.
The server 130 may be configured to host a database 230 stored in a memory available to the server 130, whereas the client 1 10 may be configured to host a database 210 stored in a memory of the client 1 10 or in a memory otherwise accessible by the client 1 10, as schematically illustrated in Figure 2. Looking at the client's perspective, the database 210 in the client 1 10 may be referred to as a local database or a local copy of the database 230, whereas the database 230 hosted by the server 130 may be referred to as a remote database. The remote database 230 is typically stored in a single physical device, e.g. a server device acting as the server 130 or comprising the server 130. However, as referred to hereinbefore, the server 130 may be a logical entity embodied using one or more server devices, and hence the remote database 230 may be distributed to two or more devices instead of storing the whole remote database 230 in a single device. Without losing generality, the information stored into a database may be considered to be conceptually arranged as a number of data items, each data item comprising one or more data elements, as schematically illustrated in Figure 3. Although Figure 3 illustrates the data items to be arranged as rows of a table and the data elements to be arranged as columns of the table, this is merely for purposes of illustration of the concepts of the data items and the data elements, and the data items and the data elements within the database 210, 220, 230 may be arranged in any order and/or into any suitable data structure(s) in view of the characteristics, structure and requirements of a given database. Moreover, although Figure 3 illustrates data elements of data items of the database 210, 220, 230 to be of identical size, this is just for the purpose of clarity of illustration and respective data elements of data items of a database 210, 220, 230 may have different sizes - consequently possibly resulting in a database 210, 220, 230, comprising data items of different sizes.
The information stored into a database 210, 220, 230 may exhibit further structural elements. As an example, a database may be arranged into a number of tables, each table of the database 210, 220, 230 comprising a number of data items, each data item comprising one or more data elements. Consequently, Figure 3 may be consid- ered to conceptually illustrate information stored in a table of a database 210, 220, 230.
The remote database 230 may be considered as a main database containing a full set of information, whereas the local database 210 typically comprises a subset of the full set of information of the remote database 230. As an example of a subset of the full set of information the local database 210 may comprise full set of data elements for a subset of data items stored in the remote database 230. As another example, the local database 210 may comprise a subset of data elements for all data items stored in the remote database 230 or the local database 210 may comprise a subset of data elements for a subset of the data items stored in the remote database 230. As a further example, the local database 210 may comprise a full copy of the information stored in the remote database 230, e.g. all data elements of all data items stored in the remote database 230 across all tables of the remote database 230. The amount of data stored in the local database 210 typically depends e.g. on one or more of the storage capacity available to the client 1 10, processing capacity available to the client 1 10, characteristics of the communication link between the client 1 10 and the server 130, preferences defined by a user/administrator operating the client 1 10 or the local database 210 and/or by a user/administrator operating the server 130 or the remote database 230, etc. The local database 210 hence facilitates ac- cess to at least a portion of the information stored in the remote database 230 also when the client 1 10 is not connected to the server 130 hosting the remote database 230.
The client 120 may host a database 220, stored in a memory accessible by the client 120, as further illustrated in Figure 2. The database 220 may be considered as a se- cond local database providing a copy of at least part of the information stored in the remote database 230, as described hereinbefore for the local database 210.
The local database 210, 220 may exhibit internal structure different from that of the remote database 230. Alternatively or additionally, the local database 210, 220 may provide access to the information stored therein in a manner different from that pro- vided by the remote database 230. In case the local database 210, 220 employs internal structure different from that of the remote database 230 and, in particular, the means for accessing the local database 210, 230 provide the data in a format different from that suitable for accessing the remote database 230, the client 1 10, 120 may be configured to provide a function for converting data retrieved from the local database 210, 220 to a format suitable for introducing to the remote database 230 and/or a function for converting data obtained from the remote database 230 to a format suitable for storing into the local database 210, 220.
The client 1 10 may be configured to enable local modification of the content of the local database 210. The local modification of the content of the local database 210 may comprise deletion of a data item stored in the local database 210, modification of a data item stored in the local database 210 or introduction of a new data item in the local database 210. The modification of a data item may comprise e.g. modification of one or more data elements of the data item, deletion of one or more data elements of the data item and/or introduction of one or more data elements to the data item. The local modification may be initiated by a user operating the client 1 10, 120. The client may be configured to apply local modification of the local database 210, 220 only in case the client 210, 220 is not currently in connection with the server 130 hosting the remote database 230, whereas a modification initiated by a user operating the client 1 10, 120 may be directly applied to the remote database 230 when the client 1 10, 120 is in connected with the server 130 and hence has an access to the remote database 230.
Local modification of the local database 210, 220 may hence introduce one or more new data items to the local database 210, 220, delete one or more data items from the local database 210, 220 and/or modify content of one or more data elements of one or more data items of the local database 210, 220. In order to facilitate keeping the local database 210, 220 and the remote database 230, which is the main database that may be accessible by a number of clients 1 10, 120, synchronized e.g. deletion of a data item from the local database 210, 220 and/or modification of one or more data elements of a data item in the local database 210, 220 may be indicated as tentative or pending modifications in the client 1 10, 120 to be exported to the remote database 230 as part of a subsequent synchronization between the local database 210, 220 and the remote database 230.
A pending modification of a data item may be indicated by setting a data element of the data item provided for indicating a pending modification of the data item and/or the type of the modification. In case the respective data item of the local database 210, 220 does not include such a data element, a pending modification in the client 1 10, 120 may be facilitated for example by augmenting a data item of the local database 210, 220 subject to modification with one or more data elements descriptive of the modification. As an example, a data item deleted from the local database 210, 220 may be provided or augmented with a data element indicating pending deletion of the respective data item or one or more data elements thereof from the remote da- tabase 230. As another example, a data item one or more data elements of which are modified may be provided or augmented with one or more data elements indicating pending change(s) to the data item. As a further example, a pending introduction of a new data item to the local database 210, 220 may be implemented by inserting a new data item to the local database 210, 220 and providing or augmenting the new data item with a data element indicating the new data item to be a pending new data item to be introduced to the remote database 230.
Instead of augmenting a data item of the local database 210, 220 with a data element indicating e.g. a pending deletion, a pending modification of a data element of the da- ta item or a pending introduction of a new data item, a data structure separate from the local database 210, 220 may be employed. Such a data structure may be referred to as a (local) modification database. The modification database may exhibit a structure similar to that of the local database 210, 220 with possible further data elements augmented to some or all of the data items of the modification database to in- dicate nature of the respective modification. Alternatively, the modification database may employ a structure different from that of the local database 210, 220. The modification database may, for example, comprise a table or an array comprising tuples providing a reference to a to-be-modified data item of the local database 210, 220 and a data item indicative of the respective pending action, e.g. deletion of a data item, introduction of a new data item or indication of one or more modified data elements of a data item and the modifications thereof.
Similarly, the server 130 may be configured to enable local modification of the content of the remote database 230. For the server 130 the local modification may be initiated e.g. via a client directly connected to the server 130 by the user operating the client for example by applying an operation that results in the client requesting the server 130 to modify the content of the remote database 230. If such local modification of the remote database 230 is carried out e.g. via the client 120, the local modification is reflected to the local database 210 at the client 1 10 only after a subsequent synchronization between the local database 210 and the remote database 230. As another example, the local modification of the remote database 230 in the server 130 may be performed in response to a request received from another server, e.g. from the server 140.
The client 1 10, 120 and the server 130 may be configured to keep the local database 210, 220 and the remote database 230 synchronized. In particular, the remote data- base 230 may be synchronized with one or more local databases 210, 220 hosted by one or more separate clients 1 10, 120. The synchronization between the local data- base 210, 220 and the remote database 230 may be carried out e.g. upon establishing a connection between the client 1 10, 120 and the server 130 and/or upon closing the connection between the client 1 10, 120 and the server 130. Additionally or alternatively, during a period of the client 1 10, 120 being in connection with the server 130 the synchronization may be carried out periodically e.g. at fixed temporal intervals, in response to a request initiated e.g. by a user operating the client 1 10, 120 and/or in response to a request received from the server 130. As particular example, local modification of the remote database 230 during the period of the client 1 10, 120 being in connection with the server 130 may result in synchronization per request by the server 130. As a further example, the client 1 10, 120 may be configured to establish a connection with the server 230 periodically, e.g. at fixed temporal intervals, to synchronize the local database 210, 220 with the remote database 230.
In general, the synchronization may comprise modification of the content of the remote database 230 based on modifications of the local database 210, 220 that have been applied since the most recent synchronization between the local database 210, 220 and the remote database 230 and/or modification of the content of the local database 210, 220 based on the modifications of the remote database 230 applied since the most recent synchronization between the local database 210, 220 and the remote database 230. In the foregoing, concepts related to synchronization of the remote database 230 hosted by the server 130 with one or more local databases 210, 220, each hosted by separate client 1 10, 120 have been described. However, a client may host one or more local databases, each local database to be synchronized with a respective remote database. The remote databases may be hosted by one or more servers. As described hereinbefore, the local database 210, 220 may be able to store either the full set of information provided in the remote database 230 or the local database 210, 220 may be able to store only a portion of the information provided in the remote database 230. Typically, the limiting factor is the storage capacity available for the client 1 10, 120 for storing the local database 210, 220. The capacity-limiting factor may be the physical capacity of the storage space available for the client 1 10, 120, or there may be other factors that limit the overall storage capacity available for the client 1 10, 120 allocated for storing the local database 210, 220.
The latter type of limitation may be especially pronounced if the client 1 10, 120 is embodied as a multi-purpose client device or as a component of such a device. Such a multi-purpose client device may be e.g. a smartphone that is typically capable of, in addition to making phone calls, e.g. accessing email account(s), playing music, cap- turing and viewing photographs, etc., hence possibly storing emails of one or more email accounts, music files of one or more music libraries, photographs arranged into one or more albums etc. - each of these possibly constituting a local database of its own that may be synchronized over a network connection with a respective remote database hosted by a server. Another example of such a multi-purpose client device is a device designed to be used as a music player as a primary function, which is typically also capable of accessing email account(s), capturing and viewing photographs, etc. Hence, the client 1 10, 120 may host one or more separate local databases making use of the limited overall storage capacity available for the client 1 10, 120, thereby limiting the storage capacity available for a given local database.
Consequently, in order to synchronize a given local database of the one or more local databases with the respective one or more remote databases, the client 1 10, 120 may be configured to store only a portion of the information provided in the respective remote database due to a limited storage capacity available for the client 1 10, 120 and/or in order to ensure sufficient storage capacity also for the other local databases, e.g. by storing in the given local database a subset of data items available in the respective remote database and/or by storing in the given local database a subset of data elements available for all or some of the data items in the respective remote database, as described hereinbefore. Alternatively or additionally, the client 1 10, 120 may be configured to remove one or more data elements of one or more data items from one or more of the one or more local databases as part of the synchronization process of the given local database in order to ensure that the most relevant pieces of information in the one or more remote databases are available to the client 1 10, 120 also when the client 1 10, 120 is not connected to the server(s) host- ing the respective remote databases. Removing a data element or a data item from a local database may comprise exporting the data element or the data item to the respective remote database and/or deleting the data element or the data item from the local database.
Figure 4 schematically illustrates the client 1 10 in further detail in order to illustrate aspects related to synchronizing one or more local databases with respective one or more remote databases. In this regard, the client 1 10 comprises a memory management portion 1 12 for managing overall storage capacity allocated for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230' and a database management portion 1 14 for managing data transfer to and from the one or more local databases 210, 210'. The memory management portion 1 12 and the database management portion 1 14 are operatively coupled to each other. The client 1 10 is configured to host the one or more local databases 210, 210' stored in a memory 1 16 accessible by the client 1 10. The memory 1 16 may be also employed to store any further information associated with the one or more local databases 210, 210'.
Figure 4 further schematically illustrates the server 130 hosting the remote database 230 stored in a memory 136 accessible by the server 130 and a second server 130' hosting the remote database 230' stored in a memory 136' accessible by the server 130'. The memories 136, 136' may be also employed to store any further information associated with the respective remote database 230, 230'. The client 1 10 and the server 130 may be configured to keep the local database 210 and the remote data- base 230 synchronized, whereas the client 1 10 and the server 130' may be configured to keep the local database 210' and the remote database 230' synchronized. The server 130 may be further configured to keep the remote database 230 synchronized with another local database hosted by another client and/or another server (not shown) and the server 130' may be further configured to keep the remote database 230' synchronized with another local database hosted by another client and/or another server (not shown).
The remote databases 230, 230' are illustrated to be hosted by separate servers 130, 130', respectively. However, the remote databases 220, 220' may be hosted by a single server, e.g. the server 130 or the second server 130'. Moreover, in Figure 4 the client 1 10 is illustrated with two local databases 210, 210' corresponding to the remote databases 220, 220', respectively. However, the client 1 10 may host only a single local database or the client 1 10 may host more than two local databases with the respective remote databases hosted by one or more servers.
In the following the synchronization between the local database 210 and the respec- tive remote database 230 is described. However, the description is naturally applicable also to the synchronization between the local database 210' and the respective remote database 230' - or to be more generic - to the synchronization of a local database of the one or more local databases with the respective remote database.
The memory management portion 1 12 is configured to obtain information indicative of data selected for retrieval from the remote database 230 for storage in the local database 210. In general, the data selected for retrieval from the remote database 230 comprises one or more data elements of one or more data items in one or more tables of the remote database 230. The selection of data items and/or data elements may be based, for example, on predetermined synchronization settings and/or on a user action resulting in a request for a certain set of data elements of a certain set of data items available in the remote database 230, and the memory management por- tion 1 12 (or the database management portion 1 14) may be configured to select the data for retrieval accordingly.
Alternatively or additionally, the selection of data items and/or data elements may be based at least in part on the amount of storage capacity currently available for storing the local database 210 and/or the amount of data available for retrieval in the remote database 230. As an example in this regard, the memory management portion 1 12 (or the database management portion 1 14) may be configured to select a subset of data items, and possibly a subset of data elements of the selected data items, for retrieval in response to the amount of data available for retrieval in the remote data- base 230 exceeds a predetermined threshold such that the data items and data elements thereof are selected in accordance with the amount of storage capacity available for storing the local database 210.
The data selected for retrieval may comprise one or more data elements of one or more data items of the remote database that fulfill predetermined criteria. The data items that fulfill the predetermine criteria may comprise basically any subset of the data stored in the remote database 230, e.g. all data elements of all data items of a selected table of the remote database 230, all data elements of one or more selected data items in a selected table of the remote database 230 or one or more selected data elements of one or more selected data items of a selected table of the remote database 230. On the other hand, the data selected for retrieval may comprise all data elements of all data items in all tables of the remote database 230, in other words the predetermined criteria may involve selecting all data available for retrieval in the remote database 230.
As a particular example of selecting a subset of data items for retrieval, the data items of the remote database 230 that fulfill predetermined criteria may comprise data items of the remote database 230 that have been modified within a first predetermined period of time. Applying such a period of time as a criterion for selecting the data for retrieval enables, for example, selecting the data items that are most recently introduced to the remote database 230 and/or selecting the data items of the remote database 230 that are most recently modified. This may facilitate selecting the data items of the remote database 230 that are not stored in the local database 210. As another example, application of such a period of time as a criterion for selecting data for retrieval enables selecting the data items introduced and/or modified within an arbitrary time period of interest. As another example of selecting a subset of data items for retrieval, the data items of the remote database 230 that that fulfill predetermined criteria may comprise the data items that have been accessed within a (second) predetermined period of time.
To facilitate selecting a desired subset of data items for retrieval based on a criterion based on date and time of modification/creation or access to a data item, the data items of the remote database 230 may comprise a data element indicating the date and time of introduction of respective data item to the database and/or a data element indicating the date and time of the most recent modification of the respective data item, wherein for a newly introduced data item the most recent modification is the introduction (or creation) of the data item. As a further example, the data items of the remote database 230 may, alternatively or additionally, comprise a data element indicating the most recent access to the data item, thereby facilitating e.g. identification of the most recently accessed data items.
As a further example of selecting a subset of data items for retrieval, the data items of the remote database 230 that that fulfill a predetermined criteria may comprise the data items that have a size not exceeding a predetermined threshold size. To facilitate selecting such a subset of data items, the data items of the remote database 230 may comprise a data element indicating the size of the respective data item.
In addition to or instead of selecting data items that fulfill predetermined criteria the data selected for retrieval may comprise one or more data elements of a predetermined fixed number of data items available in the remote database 230 or a predetermined maximum number of data items available in the remote database 230. As a particular example, such an approach may be applied in order to select a number of most recently introduced data items of the remote database 230, a number of most recently modified data items of the remote database 230 and/or a number of most recently accessed data items of the remote database 230 such that the number of selected data items does not exceed a predefined maximum number of data items.
As referred to hereinbefore, the data selected for retrieval may comprise one or more data elements of one or more data items of the remote database that fulfill predeter- mined criteria. The one or more data elements may comprise all data elements or a predetermined subset of data elements for each data item fulfilling the predetermined criteria. Retrieving a predetermined subset of data elements may facilitate retrieving a fixed predetermined subset of data elements for data items not previously stored in the local database 210 and/or retrieving one or more data elements to complement a data item already stored in the local database 210 by retrieving additional data elements thereof from the remote database 230. Alternatively, the one or more data elements may also be selected in accordance with a criterion, e.g. such that for a given data item one or more data elements may be excluded from retrieval in case the size of the respective data element exceeds a predetermined threshold size. To facilitate application of such a threshold size, the data items of the remote database 230 may comprise one or more data elements indicating the sizes of data elements of the respective data item. The size indication may be provided for all data elements of a data item or for a subset of the data elements of a data item.
The server 130 hosting the remote database 230 may be configured to provide in- formation characterizing the data stored in the remote database 230 in response to a request. In particular, the server 130 may be configured, for example, to provide information indicating the number of all data items stored in the remote database 230, the number of data items stored in a specific table of the remote database 230, the number of data items of the remote database 230 that fulfill predetermined criteria regarding e.g. date and time of introduction of, modification of or access to the respective data item, an identifier of the respective data item indicative e.g. of a sequence number of the respective data item and/or size of the respective data item in response to a request. Consequently, the memory management portion 1 14 may be configured to request information indicative of the respective number of data item from the server 130.
Along similar lines, the server 130 may be configured to provide information indicative of sizes of the data items stored in the remote database 230 and/or sizes of one or more data elements of data items stored in the remote database 230 in response to a request. In particular, the server 130 may be configured to provide information indicating sizes of one or more data elements of one or more data items that fulfill predetermined criterion regarding e.g. date and time of the most recent modification of and/or access to the respective data item. Consequently, the memory management portion 1 14 may be configured to request such information from the server 130.
The memory management portion 1 12 is configured to determine the amount of stor- age capacity required for storing the data selected for retrieval from the remote database 230 in order to facilitate memory management of the overall storage capacity for storing the one or more local databases.
Determination of the required storage capacity may comprise obtaining information indicative of the number of data items selected for retrieval from the remote database 230 and information indicative of sizes of the data items selected for retrieval. Infor- mation indicating the number of data items selected for retrieval may be obtained, for example from the server 130 in response to a request, as described hereinbefore.
The information indicative of sizes may comprise a size of a data item estimated on basis of an estimated size of a data item or on estimated sizes of one or more data elements of the data items selected for retrieval. An estimated size of a data element may be based, for example, on a priori knowledge of a fixed size of the respective data element or on an average size of the respective data element derived on basis of statistical information on sizes of data elements of respective type. Similarly, an estimated size of a data item may be based e.g. on a priori knowledge of a fixed size of the respective data item or on an average size of the respective data item derived on basis of statistical information on sizes of data items of respective type. Alternatively, an estimated size of a data item may be based on estimated sizes of data elements comprised therein. Together with the information indicating the number of data items selected for retrieval such size information may be employed to derive an estimate of the required storage capacity by multiplying the number of data items selected for retrieval by the size of the data item. The required storage capacity may be indicated as number of bits, as number bytes or as another suitable measure descriptive of storage capacity. In particular, in case of data elements and/or data items of fixed size the required storage capacity may be indicated as number of data items. Alternatively, instead of relying on a priori knowledge or an estimate of a size of a data item or a data element of a data item, obtaining information indicative of the required storage capacity may comprise obtaining information indicative of actual sizes of the data items selected for retrieval and/or obtaining information indicative of actual sizes of one or more data elements of the data items selected for retrieval. Such information may be obtained, for example, from the server 130 in response to a request, as described hereinbefore.
The memory management portion 1 12 is further configured to determine available storage capacity for the local database 210. Like the required storage capacity, also the available storage capacity may be indicated as number of bits, as number bytes or as another suitable measure descriptive of storage capacity, e.g. as number of data items in case of the data selected for retrieval comprises data elements and/or data items of fixed size.
Each local database of the one or more local databases 210, 210' may have a dedicated portion of the overall storage capacity reserved for the one or more local data- bases 210, 210' at its disposal. In such an approach the overall storage capacity may be partitioned evenly between the one or more local databases 210, 210'. This may be considered as a safe approach in terms of ensuring that the local database 210 cannot reserve too large a portion of the overall storage capacity hence leaving insufficient storage capacity for the other local databases, while on the other hand such an approach may result in inefficient usage of the overall storage capacity e.g. in case some of the other local databases make use only a (small) portion of their dedicated portions of the overall storage capacity due to inflexibility to partition the overall storage capacity according to expected storage requirements of the one or more local databases 210, 210'.
Alternatively, the overall storage capacity may be partitioned between one or more local databases 210, 210' for example in view of the expected size of each local database 210, 210' or on basis of a user preference. The available storage capacity for the local database 210 may comprise available, i.e. unused, storage capacity in a portion of the overall storage capacity dedicated to the local database 210. While this approach enables taking into account expected different storage requirements of dif- ferent local databases, there is still some inflexibility to re-use the unused portions of the dedicated portions of the overall storage capacity allocated for the other local databases in case dedicated portion allocated to the local database 210 is becoming fully occupied.
As a further alternative, the local database 210 may share a portion of the overall storage capacity reserved for the one or more local databases 210, 210' with one or more other local databases. Such a portion may be the overall storage capacity reserved for the one or more local databases 210, 210' as a whole or a sub-portion thereof. Consequently, the storage capacity currently available for the local database 210 may comprise available, i.e. unused, storage capacity in the portion of the overall storage capacity shared by the local database 210 and at least one other local database 210' of the one or more local databases 210, 210'. Such an approach enables full flexibility for the local database 210 - and for the other local databases - to make use the available storage capacity in the portion of the overall storage capacity according to the current need. The database management portion 1 14 is configured to remove, in response to the required storage capacity exceeding the available storage capacity for the local database 210, one or more data elements of one or more data items from the one or more local databases 210, 220 in accordance with a predetermined rule to increase storage capacity available for the local database 210. The predetermined rule may define the one or more pending changes introduced to the one or more local databases 210, 210' to be exported to the respective remote databases 230, 230' and/or the one or more data items and the one or more elements thereof to be discarded in order to increase storage capacity available for the local database 210, as described in more detail in the following.
As referred to in the foregoing, removing one or more data elements of one or more data items in accordance with the predetermined rule may comprise exporting one or more pending modifications introduced to the local database 210 to the remote database 230. Exporting may comprise transferring information indicative of the pending modification, e.g. an indication of deletion of a data item or one or more data elements thereof, modified data elements of a modified data item or the modified data item as a whole or a new data item introduced to the local database 210, to the server 130 for storage in the remote database 230. Additionally or alternatively, removing one or more data elements of one or more data items in accordance with the predetermined rule may comprise exporting one or more pending changes introduced to the local database 210' to the remote database 230', or - to be more generic - ex- porting one or more pending changes introduced to one or more of the one or more local databases 210, 210' to the respective remote database 230, 230'.
In addition to or instead of exporting one or more pending changes applied to the local database 210 and/or to one or more other local databases, as referred to hereinbefore, removing one or more data elements of one or more data items in accord- ance with the predetermined rule may comprise discarding, e.g. deleting, one or more data elements of one or more data items of the one or more local databases 210, 210'. This may involve discarding only a subset of data elements of one or more items or discarding all data elements of one or more data items from a selected set of local databases. In case one or more of the one or more local databases 210, 210' comprise pending modifications or changes that cannot be exported to the respective database 230, 230' e.g. due to the client 1 10 not currently being connected to the server 230, 230' hosting the respective remote database 230', the data items indicated to comprise pending modifications are preferably not discarded from the respective local database. Discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items of the local database 210 to make room for the data selected for retrieval from the remote database 230 while not discarding data from the other local databases. In other words, the selected set of local databases may comprise only the local database 210. Alternatively or additionally, discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items of the local database 210' while not discarding data elements or data items of the local database 210 or - to be more ge- neric - discarding one or more data elements of the one or more local databases excluding the local database 210. In other words, the selected set of local databases may comprise one or more the one or more local database 210 excluding the local database 210.
As a further example, discarding one or more data elements of one or more data items of the one or more local databases 210, 210' may comprise discarding one or more data elements of one or more data items from all local databases 210, 210' or from a number of local databases including the local database 210. In other words, the selected set of local databases may comprise one or more the one or more local database 210 including the local database 210. Discarding one or more data elements of one or more data items from the selected set of local databases may comprise discarding data elements of data items that have not been introduced to the database or modified within a third predetermined period of time and/or that have not been accessed within a fourth predetermined period of time. Conversely, this involves keeping the data items that have been intro- duced/modified or accessed within the third/fourth period of time and discarding the other data items, and this may be viewed as keeping or discarding the data items that fulfill a predetermined criterion with respect to date and time of the their most introduction to the database, the most recent modification thereof and/or the most recent access thereto. As an example, such an approach may be employed to discard one or more data elements of data items for which the introduction to the database, the most recent modification and/or the most recent access has occurred before a predetermined date and time.
Additionally or alternatively, discarding one or more data elements of one or more data items from the selected set of local databases may comprise discarding one or more data elements of a predetermined number of data items. As an example, this may comprise discarding one or more data elements of a predetermined number of data items exhibiting the earliest date(s) and time(s) of the most recent modification/access or a predetermined number of data items exhibiting the earliest date(s) and time(s) of their introduction to the database, in other words discarding one or more data elements of the predetermined number of the oldest data items from the selected set of local databases. Selection of data items to be discarded in such a manner may comprise - conceptually or concretely - arranging the data items of the selected set of local databases into an ordered list exhibiting ascending (descending) order of the most recent modification/access to the respective data item or the time and date of introduction of the respective data item to the database and discarding one or more data elements of a predetermined number of data items in the beginning (in the end) of the ordered list of data items. As a variation of this approach, the selection of data items to be discarded may comprise selecting a sufficient number of the oldest data items from the selected set of local databases in order to result in the storage capacity available to the local database 210 to be at least the storage capaci- ty required for storing the data selected for retrieval from the remote database 230. The oldest data items may comprise, for example, the data items exhibiting the earliest date(s) and time(s) of the most recent modification thereof or the most recent access thereto or, as another example, the data items items exhibiting the earliest date(s) and time(s) of their introduction to the database. Discarding one or more data elements of one or more data items may comprise discarding a predetermined subset of data elements. Alternatively or additionally, discarding one or more data elements of one or more data items may comprise discarding data elements according to a predefined rule, e.g. discarding data elements having a size exceeding a predefined threshold size. Such a threshold size may be de- fined for a specific data element or for data elements in general.
Removing one or more data elements of one or more data items from the one or more local databases 210, 210' may result in the available storage capacity to increase such that the available storage capacity for local database 210 is at least the required storage capacity for storing the data selected for retrieval from the remote database 230. Consequently, the database management portion 1 14 may be configured to retrieve the data selected for retrieval from the remote database 230 and store the retrieved data in the local database 210.
In contrast, in case removing one or more data elements of one or more data items of the one or more local databases 210, 210' does not result in the storage capacity available for the local database 210 to exceed the required storage capacity, the memory management portion 1 12 may be configured to redefine the data selected for retrieval from the remote database 230. The redefinition may comprise selecting a smaller number of data items for retrieval in view of the capacity limitation set by the increased storage capacity available for the local database 210, for example a prede- termined number of data items most recently introduced to the remote database 230 or as many of the data items most recently introduced to the remote database 230 as the increased storage capacity available for the local database 210 allows. Alternatively or additionally, the redefinition may comprise selecting a smaller subset of data elements of the selected data items in view of the capacity limitation set by the increased storage capacity available for the local database 210, e.g. by excluding cer- tain data elements of all selected data items or by excluding data elements having a size exceeding a threshold of all selected data items.
Alternatively, instead of redefinition of the data selected for retrieval from the remote database 230 in response to removing one or more data elements of one or more data items of the one or more local databases 210, 210' failing to result in the storage capacity available for the local database 210 to exceed the required storage capacity, the memory management portion 1 12 may be configured to terminate the synchronization process. The memory management portion 1 12 may be further configured to provide an indication thereof e.g. to enable the client 1 10 to provide a respective indication to a user of the client 1 10. In the following, an exemplifying scenario of synchronizing a local database of the one or more local databases with the respective remote database is provided by using two email accounts to represent the databases. This exemplifying scenario aims to further illustrate some concepts related to synchronization between the local and the more database(s) The local database 210 and the respective remote database 230 may be configured to store emails of an email account. In particular, one or more folders of an email account may be provided as data items of (a single table of) respective local and remote databases 210, 230, each data item being descriptive of an email message in one of the one or more folders and each data item comprising a data element indica- tive of the respective folder. Alternatively, each folder of an email account may be provided as a table of the respective local and remote databases 210, 230, the table comprising one or more data items, each data item descriptive of an email message of the respective folder. Instead of making use of tables of a single local database, the folder may be provided as separate local databases. A folder may also be referred to as a mailbox and there may be one or more folders, e.g. "inbox", "sent mail", "drafts", "deleted items", etc. Moreover, a data item descriptive of an email message comprises one or more data elements that are descriptive of elements and/or attributes of the respective email message. The one or more data elements may comprise, as a non-limiting set of examples, data elements descriptive of title of an email message, body of the email message, sender of the email message, recipient(s) of the email message, time of sending/receiving the email mes- sage, level of importance/urgency of the email message, time of most recent modification of the email message, one or more attachments to the email message, sizes of one or more data elements of the data item representing the email message an indication of a folder the email message belongs to, a header of the email message comprising e.g. threading information, etc.
Consequently, the data selected for retrieval from the remote database 230 may comprise, as an example, (at most) a predetermined number of most recently modified data items of the selected tables in order to retrieve the predetermined number of most recently received email messages in the "inbox" and in "sent mail" fold- ers/mailboxes. Alternatively, as another example, the data selected for retrieval may comprise all data items that have been modified after a predetermined moment of time. Moreover, in order to efficiently use storage capacity allocated to the local database 210 e.g. only a predetermined set of data elements of selected data items may be retrieved from the remote database 230 and stored in the respective local da- tabase 210. As an example, the predetermined set of data elements may comprise a header of the email message comprising e.g. threading information. Alternatively or additionally, the predetermined set of data elements may comprise e.g. one or more of data elements indicative of the title, message body, sender, recipient(s), time of most recent modification of the email message. Any further data elements of the da- ta items stored in the remote database 230, such as attachment(s) to the email message or even bodies of email messages exceeding a predetermined threshold size, may be retrieved in response to a specific request thereto.
In parallel, the local database 210' and the respective remote database 230' may be configured to store emails of a second email account along the lines described here- inbefore for the databases 210, 230 storing the components of the (first) email account. However, it is not necessary to arrange e.g. the folders of the (first) email account and the second email account into tables of the respective databases in a similar manner and/or to include the same elements and/or attributes of email messages of the two email accounts in the data items of the respective (tables of) databases. Moreover, the data elements and/or data items selected for retrieval from the remote database 230' for synchronizing the local database 210' may apply criteria similar to or different from that applied for synchronization between the local database 210 and the remote database 230.
When synchronizing the local database 210 with the remote database 230, as an ex- ample, removing one or more data elements of one or more data items from the one or more local databases 210, 210' may comprise first exporting any pending modifi- cations applied locally to the one or more local databases 210, 210' to the respective remote databases 230, 230'. Subsequently, removing one or more data elements of one or more data items may comprise discarding the oldest messages in all email accounts, e.g. the data items of the one or more local databases 210, 210' that have been received/sent earlier than a predetermined moment of time, or all messages stored in the one or more local databases 210, 210'.
The data items to be discarded from the one or more local databases 210, 210' may be selected in dependence of the amount of data selected for retrieval from the remote database 230 and/or in dependence of the amount of data available for retrieval in the remote database 230. As an example, discarding may comprise discarding one or more data items of the one or more local databases 210, 210' e.g. one by one, starting from the one(s) representing email messages having the earliest date and time of reception/sending, until sufficient storage capacity is available.
As another example, discarding may comprise discarding all data items of the one or more local databases 210, 210' in response to the storage capacity required for storing the data selected for retrieval from the remote database 230 exceeding a predetermined threshold. Consequently, in case the storage capacity required for storing the data selected for retrieval does not exceed the available storage capacity, the data selected for retrieval may be retrieved from the remote database 230. In contrast, in case the storage capacity required for storing the data selected for retrieval exceeds the available storage capacity despite all data items of the one or more local databases 210, 210' having been discarded, the data selected for retrieval from the remote database 230 may be modified by excluding one or more oldest data items from the data selected for retrieval. This may be realized for example in an iterative manner such that the data item descriptive of the oldest message, e.g. the one having the earliest date and time of reception/sending, is dropped from the data items selected for retrieval and required storage capacity for storing the data items selected for retrieval is updated accordingly until the required storage capacity falls below the available storage capacity. As a further example, the discarding may comprise a step-wise process, comprising first discarding the oldest email messages of the (first) email account, e.g. the data items of the local database 210 that have been received/sent earlier than a predetermined moment of time. In case sufficient storage capacity for the local database 210 is not yet available, the step-wise process may continue with discarding any data elements comprising attachment(s) to respective email messages from all data items of the both email accounts, e.g. by discarding the respective data elements in all data items of the one or more local databases 210, 210'. Next, in case sufficient storage capacity is still not available, data items of the local database 210' may be discarded, e.g. one by one, starting from the one(s) having the earliest date and time of reception/sending, until sufficient storage capacity is available, and if needed, the same process may be repeated for the local database 210. Finally, in case discarding all data items stored in the one or more local databases 210, 210' does not provide sufficient storage capacity, the data selected for retrieval from the remote database 230 may be modified such that the data item descriptive of the oldest message, e.g. the one having the earliest date and time of the most recent modification, is dropped from the data items selected for retrieval and required storage capacity for storing the data items selected for retrieval is updated accordingly until the required storage capacity falls below the available storage capacity.
Note that the previous paragraph describes a few exemplifying strategies for removing one or more data elements of one or more data items from the one or more local databases 210, 210' comprising data items descriptive of email messages. However, a number of variations thereof are possible in view of the general description provided hereinbefore.
In the following, a second exemplifying scenario of synchronizing a local database of the one or more local databases with the respective remote database is provided by using an email account and a music library to represent the databases.
As in the first exemplifying scenario the local database 210 and the respective remote database 230 may be configured to store emails of an email account. Hence, the description provided in this regard for the first exemplifying scenario applies also to the second exemplifying scenario. In parallel, the local database 210' and the respective remote database 230' may be configured to store a music library. A data item of the databases 210', 230' may be descriptive of an audio item, e.g. a single song, and a data item descriptive of an audio item comprises a data element providing the audio signal representing the audible content of the audio item and one or more data elements that are descriptive of elements and/or attributes of the respective audio item. The one or more data elements that are descriptive of elements and/or attributes of the respective audio item may comprise e.g. data elements descriptive of title of the audio item, title of an album the audio item belongs to, an artist presenting the audio item, duration of the audio item, date and time of most recent access to the audio item, date and time of introducing the audio item in the database 210', 230', etc. The data items descriptive of audio items may be arranged into a single table of the respective database 210', 230'. Additionally, the databases 210', 230' may further comprise e.g. a table storing data items descriptive of albums and/or a table storing data items descriptive of artists, while the respective data elements of the data items descriptive of audio items may refer to these tables. Consequently, the data selected for retrieval from the remote database 230' may comprise, as an example, (at most) a predetermined number of most recently introduced data items across all tables of the remote database 230'. Alternatively, the data selected for retrieval may comprise all data items that have been introduced to the database after a predetermined moment of time, e.g. all audio items that have been introduced to the database 230' after the predetermined moment of time. As an example, such a predetermined moment of time may be the date and time of the most recent synchronization between the local database 210' and the remote database 230'.
When synchronizing the local database 210 with the remote database 230, as an ex- ample, removing one or more data elements of one or more data items from the one or more local databases 210, 210' may comprise first exporting to any pending modifications to the local database 210 storing the data items descriptive of email messages to the respective remote database 230. In case there is a connection to the server 130' hosting the remote database 230' any pending modifications to the local database 210' storing audio items may also be exported to the respective remote database 230'. Subsequently, removing one or more data elements of one or more data items comprises discarding the audio items of the local database 210' having an indication of the most recent access thereto earlier than a predetermined moment of time and discarding the oldest email messages of the email account, e.g. the data items of the local database that have been received/sent earlier than the predetermined moment of time. Consequently, in case sufficient storage capacity for the local database 210 is not yet available, removing one or more data elements of one or more data items from the one or more local databases 210, 210' may further comprise discarding any data elements comprising attachment(s) to respective email messages from all data items descriptive of email messages, e.g. by discarding the respective data elements in all data items of the local database 210. Next, in case sufficient storage capacity is still not available, data items of the local database 210' descriptive of audio items may be discarded one by one, starting from the one having the earliest date and time of the most recent access thereto, until sufficient storage capacity is availa- ble, and if needed, the same process may be repeated for the data items descriptive of email messages of the local database 210. Finally, in case discarding all data items stored in the one or more local databases 210, 210' does not provide sufficient storage capacity, the data selected for retrieval from the remote database 230 may be modified such that the data item descriptive of the oldest message, e.g. the one having the earliest date and time of the most recent modification, is dropped from the data items selected for retrieval and required storage capacity for storing the data items selected for retrieval is updated accordingly until the required storage capacity falls below the available storage capacity.
Note that the previous paragraph describes an exemplifying strategy for removing one or more data elements of one or more data items from the one or more local databases 210, 210' comprising data items descriptive of email messages and audio items, respectively, but a number of variations thereof are possible in view of the general description provided hereinbefore.
The two exemplifying scenarios described hereinbefore serve as concrete examples illustrating some of the concepts described in more general terms throughout this document. Hence, databases of different structure and comprising data elements and/or data items of different type or nature, as well as different strategies in selection of data items for retrieval from the remote database and in removal of one or more data elements of one or more data items from the one or more local databases equally fall within the scope of the present invention. As concrete examples of databases comprising data of different type include databases for storing photographs, video items, calendar entries, address books of messaging or email systems, map data, etc.
The operations, procedures and/or functions assigned to the structural units of the client 1 10, i.e. to the memory management portion 1 12 and the database management portion 1 14, may be divided between these portions in a different manner. Moreover, the client 1 10 may comprise further portions or units that may be configured to perform some of the operations, procedures and/or functions assigned to the above-mentioned portions. On the other hand, the operations, procedures and/or functions assigned to the memory management portion 1 12 and the database management portion 1 14 may be assigned to a single portion or to a single processing unit within the client 1 10.
In particular, the client 1 10 may be an apparatus for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database comprising means for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, means for determining required storage capacity for storing the data selected for retrieval, means for determining available storage capacity for the given local database and means for removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local data- base. The means may comprise software means, hardware means and/or a combination of software and hardware means.
The operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10' may also be expressed as steps of a method implementing the corresponding operation, procedure and/or function. As an example in this regard, Figure 5 illustrates a method 500 for managing overall storage capacity for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230'. The method 500 comprises obtaining information indicative of data selected for retrieval from the remote database 230 for storage in the local database 210, as illustrated in block 510. The data selected for retrieval may comprise one or more data elements of one or more data items stored in the remote database 230, for example predetermined data elements of data items of the remote database 230 that fulfill predetermined criteria. Such predetermined criteria may be employed to select e.g. one or more data items that have been most recently modified or accessed or one or more data items that have been modified or accessed within a predetermined period of time, as described in detail hereinbefore in context of the memory management portion 1 12.
The method 500 further comprises determining required storage capacity for storing the data selected for retrieval, as indicated in block 520. The required storage capacity may be determined, for example, on basis of the number of data items selected for retrieval and sizes thereof. A size of a data item may be a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type, or a size of a data time may be based on actual size(s) of data element(s) and/or data item(s) obtained from the remote database 230, as described in detail hereinbefore in context of the memory management portion 1 12.
The method 500 further comprises determining available storage capacity for the local database 210, as indicated in block 530 and as described in detail hereinbefore in context of the memory management portion 1 12.
If the comparison of the storage capacity required for storing the data selected for re- trieval and the storage capacity available for the local database 210, illustrated by block 540, indicates that a sufficient available storage capacity exists, the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
If the comparison of the storage capacity required for storing the data selected for retrieval and the storage capacity available for the local database 210 indicates that a sufficient available storage capacity does not exist, the method 500 proceeds to removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule, as indicated in block 550. The removing may involve exporting one or more pending changes or modifications applied to the one or more local databases 210, 210' to the respective remote databases 230, 230' and/or discarding one or more data elements of one or more data items from the one or more local databases, as described in de- tail hereinbefore in context of the database management portion 1 14. In particular, removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule may comprising exporting and/or discarding data items such that the available storage capacity is made larger than or equal to the required storage capacity. Conse- quently, the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14.
Optionally, the method 500 may further comprise redetermining the storage capacity available for the local database 210 in response to the increased storage capacity failing to exceed the storage capacity required for storing the data selected for retrieval, as indicated in block 570. Moreover, the method 500 may optionally further comprise, in response to the increased storage capacity falling short of the required storage capacity, reselection of the data selected for retrieval, as indicated in block 580, for example by selecting a smaller number of data items for retrieval in view of the increased storage capacity and/or by selecting a smaller number of data elements of the selected data items in view of the increased storage capacity. Consequently, the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 in view of the reselection and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14. Alternatively, instead of reselection of data for retrieval indicated in block 580 the method may comprise, as an option, a comparison of the storage capacity required for storing the data selected for retrieval and the increased storage capacity available for the local database 210. Consequently, if the comparison indicates that a sufficient available storage capacity exists, the method 500 may proceed to retrieving the data selected for retrieval from the remote database 230 and storing the retrieved data in the local database 210, as indicated in block 560 and as described in more detail hereinbefore in context of the database management portion 1 14. In contrast, in response to the increased storage capacity still not being sufficient for storing the data selected for retrieval the synchronization is terminated and a respective error message may be generated.
Figure 6 illustrates a second exemplifying method 800 for managing overall storage capacity for storing one or more local databases 210, 210', each associated with a respective remote database 230, 230'. The method 800 comprises obtaining infor- mation indicative of data selected for retrieval from the remote database 230 for storage in the local database 210, as illustrated in block 810. The data selected for retrieval may comprise one or more data elements of one or more data items stored in the remote database 230, for example predetermined data elements of data items of the remote database 230 that fulfill predetermined criteria. Such predetermined crite- ria may be employed to select e.g. one or more data items that have been most recently modified or accessed or one or more data items that have been modified or accessed within a predetermined period of time, as described in detail hereinbefore in context of the memory management portion 1 12. The predetermined criteria may be employed to select a subset of the data items available in the remote database 230 or all data items available in the remote database 230.
The method 800 further comprises determining required storage capacity for storing the data selected for retrieval, as indicated in block 820. The required storage capacity may be determined, for example, on basis of the number of data items selected for retrieval and sizes thereof. A size of a data item may be a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type, or a size of a data time may be based on actual size(s) of data element(s) and/or data item(s) obtained from the remote database 230, as described in detail hereinbefore in context of the memory management portion 1 12. The method 800 further comprises determining available storage capacity for the local database 210, as indicated in block 830 and as described in detail hereinbefore in context of the memory management portion 1 12.
The storage capacity required for storing the data selected for retrieval is compared to a predetermined threshold serving to indicate an excessive amount of data to be selected for retrieval, as indicated in block 840. The predetermined threshold may be chosen in accordance of the overall storage capacity in disposal of the local database 210. In response to the storage capacity required for storing the data selected for retrieval does not exceed the predetermined threshold, the method 800 may con- tinue from block 540, is indicated in block 850.
In contrast, in response to the storage capacity required for storing the data selected for retrieval exceeding the predetermined threshold the method 800 proceeds to removing one or more data elements of one or more data items from one or more of the one or more local databases 210, 210' in accordance with a predetermined rule, as indicated in block 860. The removing may involve exporting one or more pending changes or modifications applied to the local database 210 to the respective remote database 230 and/or discarding one or more data elements of one or more data items from the local database 210, as described in detail hereinbefore in context of the database management portion 1 14. In particular, this may involve discarding all data items currently stored in the local database 210.
The processing proceeds to reselecting the data for retrieval in accordance with a predetermined rule, as indicated in block 870. The predetermined rule may involve reselecting the data items most recently introduced to the remote database 230 and/or the data items most recently accessed in the remote database 230 to be re- trieved e.g. such that the storage capacity required to store the reselected data does not exceed the available storage capacity. As another example, the predetermined rule may involve selecting a predetermined number of data items most recently introduced to the remote database 230 and/or the data items most recently accessed in the remote database 230. Consequently, the method 800 may continue from block 540, is indicated in block 850.
Figure 7 schematically illustrates an exemplifying apparatus 600 comprising the client apparatus 610. The client apparatus 610 may be employed as the client 1 10, 1 10' or the client apparatus 610 may comprise the client 1 10, 1 10'. The client apparatus 610 may be an end-product or a module, the term module referring to a unit or an appa- ratus that excludes certain parts or components that may be introduced by an end- manufacturer or by a user to result in an apparatus forming an end-product. The ap- paratus 610 may be implemented as hardware alone, e.g. as a circuit, as a programmable or non-programmable processor, etc., the apparatus 610 may have certain aspects implemented as software (e.g. as firmware) alone or can be implemented as a combination of hardware and software. The apparatus 600 further comprises, a memory 620 for storing the one or more local databases 210, 210' and a communication interface 630, such as a network card or a network adapter enabling wireless or wireline communication with another apparatus. The client apparatus 610 is configured to read from and write to the memory 620 to enable access to the one or more local databases 210, 210' stored therein. The ap- paratus 600 may further comprise a user interface 640 for providing data, commands and/or other input to the client apparatus 610 and/or for receiving data or other output from the client apparatus 610, the user interface 640 comprising for example one or more of a display, a keyboard or keys, a mouse or a respective pointing device, a touchscreen, etc. The apparatus 600 may comprise further components not illustrat- ed in the example of Figure 7.
Figure 8 schematically illustrates a second exemplifying apparatus comprising a processor 710, a memory 720 and a communication interface 730, such as a network card or a network adapter enabling wireless or wireline communication with another apparatus. The processor 710 is configured to read from and write to the memory 720. The apparatus 700 may further comprise a user interface 740 for providing data, commands and/or other input to the processor 710 and/or for receiving data or other output from the processor 710, the user interface 740 comprising for example one or more of a display, a keyboard or keys, a mouse or a respective pointing device, a touchscreen, etc. The apparatus 700 may comprise further components not illustrat- ed in the example of Figure 8.
Although the processor 710 is presented in the example of Figure 8 as a single component, the processor 710 may be implemented as one or more separate components. Although the memories 620, 720 in the examples of Figures 7 and 8, respectively, are illustrated as single components, each of the memory 620, 720 may be implemented as one or more separate components, some or all of which may be integrated/removable and/or may provide permanent/semi-permanent/ dynamic/cached storage.
The apparatus 600, 700 may be embodied for example as a mobile phone, a camera, a video camera, a music player, a gaming device, a laptop computer, a desktop computer, a personal digital assistant (PDA), an internet tablet, a television set, etc. The memory 720 may store the one or more local databases 210, 210', and the memory 720 may store a computer program 750 comprising computer-executable instructions that control the operation of the apparatus 700 when loaded into the processor 710. As an example, the computer program 750 may include one or more se- quences of one or more instructions. The computer program 750 may be provided as a computer program code. The processor 710 is able to load and execute the computer program 750 by reading the one or more sequences of one or more instructions included therein from the memory 720. The one or more sequences of one or more instructions may be configured to, when executed by one or more processors, cause an apparatus, for example the apparatus 700, to implement the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'.
Hence, the apparatus 700 may comprise at least one processor 710 and at least one memory 720 including computer program code for one or more programs, the at least one memory 720 and the computer program code configured to, with the at least one processor 710, cause the apparatus 700 to perform the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'.
The computer program 750 may be provided at the apparatus 700 via any suitable delivery mechanism. As an example, the delivery mechanism may comprise at least one computer readable non-transitory medium having program code stored thereon, the program code which when executed by an apparatus cause the apparatus at least implement processing to carry out the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10'. The delivery mechanism may be for example a computer readable storage medium, a computer program product, a memory device a record medium such as a CD-ROM or DVD, an article of manufacture that tangibly embodies the computer program 750. As a further example, the delivery mechanism may be a signal configured to reliably transfer the computer program 750.
The computer program 750 may implement any of the operations, procedures and/or functions described hereinbefore in context of the client 1 10, 1 10', e.g. those de- scribed in context of the memory management portion 1 12 and/or those described in context of the database management portion 1 14 e.g. as service object that may run as part of a database synchronization software system or as an operating system enabled with a database synchronization functionality.
Reference to a processor should not be understood to encompass only programma- ble processors, but also dedicated circuits such as field-programmable gate arrays (FPGA), application specific circuits (ASIC), signal processors, etc. Features de- scribed in the preceding description may be used in combinations other than the combinations explicitly described. Although functions have been described with reference to certain features, those functions may be performable by other features whether described or not. Although features have been described with reference to certain embodiments, those features may also be present in other embodiments whether described or not.

Claims

Claims
1 . An apparatus comprising a memory management portion for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database, the memory management portion configured to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determine required storage capacity for storing the data selected for retrieval, and determine available storage capacity for the given local database a database management portion configured to remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
2. An apparatus according to claim 1 , wherein the data selected for retrieval comprises one or more data elements of one or more data items of the remote database that fulfill predetermined criteria.
3. An apparatus according to claim 2, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been introduced to the database within a predetermined period of time.
4. An apparatus according to claim 2 or 3, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been accessed within a second predetermined period of time.
5. An apparatus according to any of claims 1 to 4, wherein the required storage capacity is determined on basis of the number of data items selected for retrieval and sizes thereof.
6. An apparatus according to claim 5, wherein a size of a data item is a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type.
7. An apparatus according to claim 5, wherein a size of a data item is based on an actual size received from the remote database.
8. An apparatus according to any of claims 1 to 7, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity dedicated to the given local database.
9. An apparatus according to any of claims 1 to 7, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity shared by the given local database and at least one other local database of the one or more local databases.
10. An apparatus according to any of claims 1 to 9, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the one or more local databases to the respective remote databases.
1 1 . An apparatus according to any of claims 1 to 9, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the given local database. 12. An apparatus according to any of claims 1 to 1 1 , wherein removing one or more data elements of one or more data items comprises discarding one or more data elements of one or more data items of the one or more local databases.
13. An apparatus according to any of claims 1 to 1 1 , wherein removing one or more data elements of one or more data items comprises discarding all data items of the given local database.
14. An apparatus according to claim 12 or 13, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been introduced to the database within a third predetermined period of time. 15. An apparatus according to any of claims 12 to 14, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been accessed within a fourth predetermined period of time.
16. An apparatus according to any of claims 1 to 15, wherein the data items of the one or more local databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message.
17. An apparatus according to any of claims 1 to 15, wherein the data items of the given databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message, and wherein the data items of the other local databases are descriptive of data different from email messages.
18. An apparatus for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database, the apparatus comprising means for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, means for determining required storage capacity for storing the data selected for retrieval, means for determining available storage capacity for the given local database; and means removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
19. An apparatus according to claim 18, wherein the data selected for retrieval comprises one or more data elements of one or more data items of the remote database that fulfill predetermined criteria.
20. An apparatus according to claim 19, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been introduced to the database within a predetermined period of time.
21 . An apparatus according to claim 19 or 20, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been accessed within a second predetermined period of time.
22. An apparatus according to any of claims 18 to 21 , wherein the required storage capacity is determined on basis of the number of data items selected for retrieval and sizes thereof.
23. An apparatus according to claim 22, wherein a size of a data item is a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type. 24. An apparatus according to claim 22, wherein a size of a data item is based on an actual size received from the remote database.
25. An apparatus according to any of claims 18 to 24, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity dedicated to the given local database. 26. An apparatus according to any of claims 18 to 24, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity shared by the given local database and at least one other local database of the one or more local databases.
27. An apparatus according to any of claims 18 to 26, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the one or more local databases to the respective remote databases.
28. An apparatus according to any of claims 18 to 26, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the given local database.
29. An apparatus according to any of claims 18 to 28, wherein removing one or more data elements of one or more data items comprises discarding one or more data elements of one or more data items of the one or more local databases. 30. An apparatus according to any of claims 18 to 28, wherein removing one or more data elements of one or more data items comprises discarding all data items of the given local database. An apparatus according to claim 29 or 30, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been introduced to the database within a third predetermined period of time.
An apparatus according to any of claims 29 to 31 , wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been accessed within a fourth predetermined period of time.
An apparatus according to any of claims 18 to 32, wherein the data items of the one or more local databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message.
An apparatus according to any of claims 18 to 32, wherein the data items of the given databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message, and wherein the data items of the other local databases are descriptive of data different from email messages.
A method for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database, the method comprising obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determining required storage capacity for storing the data selected for retrieval, determining available storage capacity for the given local database; and removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
36. A method according to claim 35, wherein the data selected for retrieval comprises one or more data elements of one or more data items of the remote database that fulfill predetermined criteria.
37. A method according to claim 35, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been introduced to the database within a predetermined period of time.
38. A method according to claim 36 or 37, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been accessed within a second predetermined period of time. 39. A method according to any of claims 35 to 38, wherein the required storage capacity is determined on basis of the number of data items selected for retrieval and sizes thereof.
40. A method according to claim 39, wherein a size of a data item is a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type.
41 . A method according to claim 39, wherein a size of a data item is based on an actual size received from the remote database.
42. A method according to any of claims 35 to 41 , wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity dedicated to the given local database.
43. A method according to any of claims 35 to 41 , wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity shared by the given local database and at least one other local database of the one or more local databases. 44. A method according to any of claims 35 to 43, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the one or more local databases to the respective remote databases.
45. A method according to any of claims 35 to 43, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the given local database.
46. A method according to any of claims 35 to 45, wherein removing one or more data elements of one or more data items comprises discarding one or more data elements of one or more data items of the one or more local databases.
47. A method according to any of claims 35 to 45, wherein removing one or more data elements of one or more data items comprises discarding all data items of the given local database.
48. A method according to claim 46 or 47, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been introduced to the database within a third predetermined period of time.
49. A method according to any of claims 46 to 48, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been accessed within a fourth predetermined period of time.
50. A method according to any of claims 35 to 49, wherein the data items of the one or more local databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message.
51 . A method according to any of claims 35 to 49, wherein the data items of the given databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message, and wherein the data items of the other local databases are descriptive of data different from email messages.
52. An apparatus for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database, the apparatus comprising at least one processor and at least one memory including computer program code for one or more programs, the at least one memory and the computer program code configured to, with the at least one processor, cause the apparatus to perform at least the following: obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determine required storage capacity for storing the data selected for retrieval, determine available storage capacity for the given local database; and remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
53. An apparatus according to claim 52, wherein the data selected for retrieval comprises one or more data elements of one or more data items of the remote database that fulfill predetermined criteria. 54. An apparatus according to claim 53, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been introduced to the database within a predetermined period of time.
55. An apparatus according to claim 53 or 54, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been accessed within a second predetermined period of time.
56. An apparatus according to any of claims 52 to 55, wherein the required storage capacity is determined on basis of the number of data items selected for retrieval and sizes thereof.
57. An apparatus according to claim 56, wherein a size of a data item is a size es- timated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type.
58. An apparatus according to claim 56, wherein a size of a data item is based on an actual size received from the remote database.
59. An apparatus according to any of claims 52 to 58, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity dedicated to the given local database.
60. An apparatus according to any of claims 52 to 58, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity shared by the given local database and at least one other local data- base of the one or more local databases.
61 An apparatus according to any of claims 52 to 60, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the one or more local databases to the respective remote databases.
62. An apparatus according to any of claims 52 to 60, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the given local database.
63. An apparatus according to any of claims 52 to 62, wherein removing one or more data elements of one or more data items comprises discarding one or more data elements of one or more data items of the one or more local databases. 64. An apparatus according to any of claims 52 to 62, wherein removing one or more data elements of one or more data items comprises discarding all data items of the given local database.
65. An apparatus according to claim 63 or 64, wherein removing one or more data elements of one or more data items comprises removing one or more data ele- ments of one or more data items that have not been introduced to the database within a third predetermined period of time.
66. An apparatus according to any of claims 63 to 65, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been accessed within a fourth predetermined period of time.
67. An apparatus according to any of claims 52 to 66, wherein the data items of the one or more local databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message. 68. An apparatus according to any of claims 52 to 66, wherein the data items of the given databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message, and wherein the data items of the other local databases are descriptive of data different from email messages. 69. A computer program for managing overall storage capacity for storing one or more local databases, each associated with a respective remote database, the computer program including one or more sequences of one or more instructions which, when executed by one or more processors, cause an apparatus to at least perform the following: obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determine required storage capacity for storing the data selected for retrieval, determine available storage capacity for the given local database; and remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
70. A computer program according to claim 69, wherein the data selected for retrieval comprises one or more data elements of one or more data items of the remote database that fulfill predetermined criteria.
71 . A computer program according to claim 70, wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been introduced to the database within a predetermined period of time.
72. A computer program according to claim 70 or 71 , wherein the data items of the remote database that fulfill the predetermined criteria comprises data items that have been accessed within a second predetermined period of time.
73. A computer program according to any of claims 69 to 72, wherein the required storage capacity is determined on basis of the number of data items selected for retrieval and sizes thereof.
74. A computer program according to claim 73, wherein a size of a data item is a size estimated on basis of an average size of data items of respective type or on basis of average sizes of one or more data elements of data items of respective type.
75. A computer program according to claim 73, wherein a size of a data item is based on an actual size received from the remote database.
76. A computer program according to any of claims 69 to 75, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity dedicated to the given local database.
77. A computer program according to any of claims 69 to 75, wherein the available storage capacity comprises available storage capacity in a portion of the overall storage capacity shared by the given local database and at least one other local database of the one or more local databases.
78. A computer program according to any of claims 69 to 77, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the one or more local databases to the respective remote databases.
79. A computer program according to any of claims 69 to 77, wherein removing one or more data elements of one or more data items comprises exporting one or more pending changes applied to the given local database. 80. A computer program according to any of claims 69 to 79, wherein removing one or more data elements of one or more data items comprises discarding one or more data elements of one or more data items of the one or more local databases.
81 . A computer program according to any of claims 69 to 79, wherein removing one or more data elements of one or more data items comprises discarding all data items of the given local database.
82. A computer program according to claim 80 or 82, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been introduced to the database within a third predetermined period of time.
83. A computer program according to any of claims 80 to 82, wherein removing one or more data elements of one or more data items comprises removing one or more data elements of one or more data items that have not been accessed within a fourth predetermined period of time. 84. A computer program according to any of claims 69 to 83, wherein the data items of the one or more local databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message. A computer program according to any of claims 69 to 83, wherein the data items of the given databases are descriptive of email messages and the data elements of a data item comprise elements and/or attributes of an email message, and wherein the data items of the other local databases are descriptive of data different from email messages.
A computer program product comprising at least one computer readable non- transitory medium having program code stored thereon, the program which when executed by an apparatus cause the apparatus at least to obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determine required storage capacity for storing the data selected for retrieval, determine available storage capacity for the given local database; and remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
A computer program product including one or more sequences of one or more instructions which, when executed by one or more processors, cause an apparatus to at least perform the following: obtain information indicative of data selected for retrieval from a respective remote database for storage in a given local database, determine required storage capacity for storing the data selected for retrieval, determine available storage capacity for the given local database; and remove, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
88. A computer program product comprising a computer readable medium bearing computer program code embodied therein for use with a computer, the computer program code comprising code for obtaining information indicative of data selected for retrieval from a respective remote database for storage in a given local database, code for determining required storage capacity for storing the data selected for retrieval, code for determining available storage capacity for the given local database; and code for removing, in response to the required storage capacity exceeding the available storage capacity for the given local database, one or more data elements of one or more data items from the one or more local databases in accordance with a predetermined rule to increase storage capacity available for the given local database.
PCT/FI2012/050659 2012-06-26 2012-06-26 A method, an apparatus and a computer program for accessing a database WO2014001600A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/FI2012/050659 WO2014001600A1 (en) 2012-06-26 2012-06-26 A method, an apparatus and a computer program for accessing a database

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/FI2012/050659 WO2014001600A1 (en) 2012-06-26 2012-06-26 A method, an apparatus and a computer program for accessing a database

Publications (1)

Publication Number Publication Date
WO2014001600A1 true WO2014001600A1 (en) 2014-01-03

Family

ID=49782316

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/FI2012/050659 WO2014001600A1 (en) 2012-06-26 2012-06-26 A method, an apparatus and a computer program for accessing a database

Country Status (1)

Country Link
WO (1) WO2014001600A1 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040158829A1 (en) * 2001-03-30 2004-08-12 Evgenij Beresin Downloading application software to a mobile terminal
EP1566747A1 (en) * 2004-02-19 2005-08-24 Research In Motion Limited System and method for searching a remote database
US20050239494A1 (en) * 2002-07-23 2005-10-27 Research In Motion Limited Data store management system and method for wireless devices
EP2098958A1 (en) * 2008-03-03 2009-09-09 British Telecommunications Public Limited Company Data management method for a mobile device
US20090228536A1 (en) * 2008-03-04 2009-09-10 Nokia Corporation Storage Management

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040158829A1 (en) * 2001-03-30 2004-08-12 Evgenij Beresin Downloading application software to a mobile terminal
US20050239494A1 (en) * 2002-07-23 2005-10-27 Research In Motion Limited Data store management system and method for wireless devices
EP1566747A1 (en) * 2004-02-19 2005-08-24 Research In Motion Limited System and method for searching a remote database
EP2098958A1 (en) * 2008-03-03 2009-09-09 British Telecommunications Public Limited Company Data management method for a mobile device
US20090228536A1 (en) * 2008-03-04 2009-09-10 Nokia Corporation Storage Management

Similar Documents

Publication Publication Date Title
US10454864B2 (en) Delivering messages from message sources to subscribing recipients
US9055063B2 (en) Managing shared content with a content management system
US9832152B2 (en) Email mailbox management with sender-specific message lists
CN110347651B (en) Cloud storage-based data synchronization method, device, equipment and storage medium
WO2013030595A1 (en) Identifying data items
JP2017510171A (en) System and method for providing a user with a set of interactivity functions locally on a user device
WO2015117426A1 (en) File management method and device
CN104537076A (en) File reading and writing method and device
US20150113076A1 (en) Message thread identification and management
US9479578B1 (en) Randomized peer-to-peer synchronization of shared content items
EP3136655B1 (en) Multimedia display method, device and equipment
TW201202959A (en) Data synchronization methods for synchronizing data in communication systems and communication systems
CN107911461A (en) Object processing method, storage server and cloud storage system in cloud storage system
CN108076078A (en) A kind of cloud host creation method, device and cloud service system
US10873552B2 (en) Large data management in communication applications through multiple mailboxes
WO2013134571A1 (en) Online backup system
CN109328331A (en) Self-organizing storage system for asynchronous storage service
JP6500166B2 (en) Randomized peer-to-peer synchronization of shared content items
CN104010016A (en) Data management method, cloud server and terminal device
US20180203636A1 (en) Likelihood of access based object storage in a cloud environment
TWI420333B (en) A distributed de-duplication system and the method therefore
WO2014001600A1 (en) A method, an apparatus and a computer program for accessing a database
KR20120073799A (en) Data synchronizing and servicing apparatus and method based on cloud storage
CN106294709B (en) Cloud storage file display method and device
JP6110354B2 (en) Heterogeneous storage server and file storage method thereof

Legal Events

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

Ref document number: 12879968

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 12879968

Country of ref document: EP

Kind code of ref document: A1