Automated conversion of versioned data collections
First Claim
1. A method of versioning an instance of a data collection, comprising:
- receiving a request from a recipient for an instance of a data collection stored by a sender according to a sender version indicator, the instance represented during a communication session with the recipient and the data collection comprising a database record;
identifying, from the request, a recipient version indicator representing a recipient preferred version of the data collection, the identifying comprising;
receiving the recipient version indicator from the recipient while establishing the communication session with the recipient;
storing the recipient version indicator; and
retrieving the stored recipient version indicator when the request is subsequently received from the recipient;
comparing the sender version indicator with the recipient version indicator;
responsive to the sender version indicator preceding the recipient version indicator based upon the comparing, sending the instance to the recipient for upconverting, by the recipient, the instance to the recipient preferred version; and
responsive to the recipient version indicator preceding the sender version indicator based upon the comparing and the sender not having stored a second instance of the data collection according to the recipient version indicator, generating, by the sender, a downconverted instance of the data collection formatted according to the recipient preferred version and sending the downconverted instance to the recipient,the generating a downconverted instance comprising;
changing an order of serialization of members of the instance of the data collection; and
for respective members within at least one of the instance of the data collection or the recipient preferred version of the data collection;
responsive to a first member of the instance being formatted according to a representation format of the recipient preferred version,providing the first member for sending as at least part of the downconverted instance;
responsive to a second member of the instance being formatted differently than the representation format of the recipient preferred version;
translating the second member to the representation format to generate a translated member, the translating comprising at least one of;
reordering elements associated with the second member;
or
resizing blocks of memory associated with the second member if an array size of an array associated with the second member differs from a preferred version array size of the recipient preferred version to resize the array to the preferred version array size;
serializing the translated member; and
providing the translated member for sending as at least part of the downconverted instance;
responsive to a third member of the recipient preferred version not being included in the instance;
generating a default member corresponding to the third member, the default member having a default value, andproviding the default member for sending as at least part of the downconverted instance; and
responsive to a fourth member of the instance not being included in the recipient preferred version, discarding the fourth member.
1 Assignment
0 Petitions
Accused Products
Abstract
Various computing components (such as devices, operating environments, and processes) may communicate by exchanging instances of a data collection, such as a class or data structure. However, the definition of the data collection may evolve to specify different numbers, types, properties, and orderings of the items in the data collection, and it may be difficult to verify the structure and contents of an instance received from another component and possibly of a different version. This difficulty may be mitigated by exchanging versioning information about the instance (e.g., as part of the communications wire protocol) and by allocating the converting such that the sender may downconvert to earlier versions requested by a recipient, while the recipient may upconvert to later versions than a version provided by a sender. These techniques may promote the accuracy and consistency of information exchange among many components that operate on different versions of the data collection.
-
Citations
20 Claims
-
1. A method of versioning an instance of a data collection, comprising:
-
receiving a request from a recipient for an instance of a data collection stored by a sender according to a sender version indicator, the instance represented during a communication session with the recipient and the data collection comprising a database record; identifying, from the request, a recipient version indicator representing a recipient preferred version of the data collection, the identifying comprising; receiving the recipient version indicator from the recipient while establishing the communication session with the recipient; storing the recipient version indicator; and retrieving the stored recipient version indicator when the request is subsequently received from the recipient; comparing the sender version indicator with the recipient version indicator; responsive to the sender version indicator preceding the recipient version indicator based upon the comparing, sending the instance to the recipient for upconverting, by the recipient, the instance to the recipient preferred version; and responsive to the recipient version indicator preceding the sender version indicator based upon the comparing and the sender not having stored a second instance of the data collection according to the recipient version indicator, generating, by the sender, a downconverted instance of the data collection formatted according to the recipient preferred version and sending the downconverted instance to the recipient, the generating a downconverted instance comprising; changing an order of serialization of members of the instance of the data collection; and for respective members within at least one of the instance of the data collection or the recipient preferred version of the data collection; responsive to a first member of the instance being formatted according to a representation format of the recipient preferred version, providing the first member for sending as at least part of the downconverted instance; responsive to a second member of the instance being formatted differently than the representation format of the recipient preferred version; translating the second member to the representation format to generate a translated member, the translating comprising at least one of;
reordering elements associated with the second member;
or
resizing blocks of memory associated with the second member if an array size of an array associated with the second member differs from a preferred version array size of the recipient preferred version to resize the array to the preferred version array size;serializing the translated member; and providing the translated member for sending as at least part of the downconverted instance; responsive to a third member of the recipient preferred version not being included in the instance; generating a default member corresponding to the third member, the default member having a default value, and providing the default member for sending as at least part of the downconverted instance; and responsive to a fourth member of the instance not being included in the recipient preferred version, discarding the fourth member. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A method of versioning an instance of a data collection, comprising:
-
receiving a sender version indicator from a sender while establishing a communication session with the sender; storing the sender version indicator; receiving, at a recipient, an instance of a data collection from the sender, the instance represented during the communication session and formatted according to a sender version represented by the sender version indicator, the data collection comprising a database record; retrieving the stored sender version indicator responsive to the receiving an instance; comparing the sender version indicator with a recipient version indicator representing a recipient preferred version of the data collection; responsive to the sender version indicator preceding the recipient version indicator, generating, by the recipient, an upconverted instance of the data collection from the instance, the generating an upconverted instance comprising; changing an order of serialization of members of the instance of the data collection; and for respective members within at least one of the instance of the data collection received from the sender or the recipient preferred version of the data collection; responsive to a first member of the instance being formatted according to a representation format of the recipient preferred version, including the first member in the upconverted instance; responsive to a second member of the instance being formatted differently than the representation format of the recipient preferred version; translating the second member to the representation format to generate a translated member, the translating comprising at least one of;
reordering elements associated with the second member;
or
resizing blocks of memory associated with the second member if an array size of an array associated with the second member differs from a preferred version array size of the recipient preferred version to resize the array to the preferred version array size; andincluding the translated member in the upconverted instance; responsive to a third member of the recipient preferred version not being included in the instance; generating a default member corresponding to the third member, the default member having a default value, and including the default member in the upconverted instance; and responsive to a fourth member of the instance not being included in the recipient preferred version, discarding the fourth member. - View Dependent Claims (10, 11, 12, 13, 14)
-
-
15. A system, comprising:
-
one or more processing units; and memory comprising instructions that when executed by at least one of the one or more processing units perform a method of versioning an instance of a data collection, the method comprising; receiving a sender version indicator from a sender while establishing a communication session with the sender; storing the sender version indicator; receiving, at a recipient, the instance of the data collection from the sender, the instance represented during the communication session and formatted according to a sender version represented by the sender version indicator, the data collection comprising a database record; retrieving the stored sender version indicator responsive to the receiving an instance; comparing the sender version indicator with a recipient version indicator representing a recipient preferred version of the data collection; responsive to the sender version indicator preceding the recipient version indicator, generating an upconverted instance of the data collection from the instance, the generating an upconverted instance comprising; changing an order of serialization of members of the instance of the data collection; and for respective members within at least one of the instance of the data collection received from the sender or the recipient preferred version of the data collection; responsive to a first member of the instance being formatted according to a representation format of the recipient preferred version, including the first member in the upconverted instance; responsive to a second member of the instance being formatted differently than the representation format of the recipient preferred version;
translating the second member to the representation format to generate a translated member, the translating comprising at least one of;
reordering elements associated with the second member;
or
resizing blocks of memory associated with the second member if an array size of an array associated with the second member differs from a preferred version array size of the recipient preferred version to resize the array to the preferred version array size; and
including the translated member in the upconverted instance;responsive to a third member of the recipient preferred version not being included in the instance;
generating a default member corresponding to the third member, the default member having a default value, and
including the default member in the upconverted instance; andresponsive to a fourth member of the instance not being included in the recipient preferred version, discarding the fourth member. - View Dependent Claims (16, 17, 18, 19, 20)
-
Specification