Claims
- 1. A method of reorganizing a database and concurrently providing access to the database for updates, the database including an original data-space having a plurality of original data-elements and a shadow data-space having a plurality of shadow data-elements, the method comprising:
copying contents of an original data-element within the original data-space to a shadow data-element within the shadow data-space; reorganizing the shadow data-space; keeping track of a location of an original data-element that is changed after its contents are copied to the shadow data-element; and copying data from the location of the changed original data-element to its corresponding shadow data-element in the reorganized shadow data-space.
- 2. The method of claim 1, wherein said keeping track of a location of an original data-element that is changed, comprises:
intercepting a log request that indicates a change to the original data-element; recording in a data data-element in a data data-space information indicating that the original data-element changed; and recording a location of the data data-element in an index data-element of an index data-space, wherein a location of the index data-element within the index data-space corresponds to the location of the original data-element within the original data-space.
- 3. The method of claim 2, wherein the information recorded in the data data-element in the data data-space includes a type of change that occurred.
- 4. The method of claim 3, wherein the type of change recorded is at least one of an addition, an update, and a deletion.
- 5. The method of claim 2, wherein the information indicating that the original data-element changed is recorded in non-persistent storage.
- 6. The method of claim 2, wherein the information indicating that the original data-element changed is recorded in persistent storage.
- 7. The method of claim 2, wherein said recording information indicating that the original data-element changed includes recording a position of the original data-element within the original data-space.
- 8. The method of claim 7, wherein the recorded position of the original data-element includes an offset of the original data-element from a base-address of the original data-space.
- 9. A method of reorganizing information in a computer system having an original data-space that contains a plurality of sequentially stored original data-elements, a shadow data-space that contains a plurality of shadow data-elements, a data data-space that contains a plurality of data data-elements, and an index data-space that contains a plurality of sequentially stored index data-elements, wherein the original data-space is operated on by an information reorganizing application program, the method comprising:
copying contents of an original data-element within the original data-space to a shadow data-element within the shadow data-space; recording a location of the original data-element and a location of the shadow data-element within a data data-element within the data data-space, thereby associating the original data-element, the shadow data-element and the data data-element; recording a location of the data data-element within an index data-element within the index data-space, wherein the index data-elements in the index data-space are arranged in the same sequence as their associated original data-elements in the original data-space; recording in the data data-element information indicating that a change has occurred in the original data-element associated with the data data-element; and applying the change in the original data-element to the shadow data-element associated with the original data-element, in response to detecting the change associated with the original data-element recorded in the data data-element.
- 10. The method of claim 9, wherein said recording in the data data-element information indicating that a change has occurred in the original data-element, further comprises:
intercepting a log request that indicates the change to the original data-element; determining a location of the changed original data-element; and updating the data data-element associated with the changed original data-element to record the information indicating that a change occurred and to record a type of change that occurred.
- 11. The method of claim 10, wherein if the log request indicates that the change is an addition of a new original data-element to the original data-space, the method further comprises:
adding the data data-element to the data data-space and storing a location of the original data-element within the data data-element; and recording a location of the data data-element within the index data-element in the index data-space, wherein the index data-elements in the index data-space are arranged in the same sequence as their associated original data-elements in the original data-space.
- 12. The method of claim 10, wherein the data data-element is updated to record information indicating that the original data-element has been at least one of added, updated and deleted.
- 13. The method of claim 9, wherein said applying the change in the original data-element to its associated shadow data-element, comprises at least one of:
adding the shadow data-element to said shadow data-space and storing a location of the shadow data-element within the data data-element, if the data data-element indicates that the original data-element was added to the original data-space; copying the contents of the original data-element to the shadow data-element by locating the original data-element and shadow data-element from the location information recorded in the data data-element, if the data data-element indicates that the original data-element was one of updated and added; and deleting the shadow data-element by locating the shadow data-element from the location information recorded in the data data-element, if the data data-element indicates that the original data-element located at the original data-element location stored within the data data-element was deleted.
- 14. The method of claim 9, wherein the index data-space and data data-space are stored in non-persistent storage.
- 15. The method of claim 9, wherein the index data-space and data data-space are stored in persistent storage.
- 16. The method of claim 9, wherein the location of the original data-element recorded in the data data-element includes a sequential position of the original data-element within the original data-space.
- 17. The method of claim 9, wherein the location of the original data-element recorded in the data data-element includes an offset of the original data-element from a base address of the original data-space.
- 18. The method of claim 9, wherein the location of the data data-element recorded in the index data-element is determined by multiplying a sequential position of the data data-element within the data data-space by a bit length of the plurality of data data-elements within the data data-space.
- 19. The method of claim 9, wherein the location of the data data-element within the data data-space is determined by dividing a relative base address of the data data-element by a bit length of the plurality of data data-elements within the data data-space.
- 20. The method of claim 9, wherein the original data-space contains a plurality of original data-elements of a first bit length and the index data-space contains a plurality of index data-elements of a second bit length.
- 21. The method of claim 20, wherein the first bit length and the second bit length are the same length.
- 22. The method of claim 20, wherein a location of the index data-element is determined from the location of its associated original data-element by dividing the location of the original data-element by the first bit length to produce a result and multiplying the result by the second bit length.
- 23. The method of claim 20, wherein the location of the original data-element is determined from a location of the index data-element by dividing a relative base address of the index data-element by the second bit length to produce a result and multiplying the result by the first bit length.
- 24. An apparatus for reorganizing information in a computer system having an original data-space that contains a plurality of sequentially stored original data-elements, a shadow data-space that contains a plurality of sequentially stored shadow data-elements, a data data-space that contains a plurality of sequentially stored data data-elements, and an index data-space that contains a plurality of sequentially stored index data-elements, the apparatus comprising:
a reorganization module configured to copy the contents of an original data-element in the original data-space to a corresponding shadow data-element in the shadow data-space and to associate the original data-element and shadow data-element using a data data-element; a log intercept module configured to intercept a log request concerning a change in an original data-element and to update a data data-element associated with the original data-element to indicate that a change has occurred in the original data-element; and a pending change module configured to apply the change in the original data-element to the shadow data-element corresponding to the original data-element, in response to detecting the change recorded in the data data-element associated with the original data-element.
- 25. The apparatus of claim 24, wherein the log intercept module updates the data data-element to record information indicating that the original data-element has been at least one of added, updated and deleted.
- 26. The apparatus of claim 24, further comprising:
a utility services module coupled to the reorganization module, the log intercept module and the pending change module and configured to manage the plurality of data data-elements in the data data-space and to manage the plurality of index data-elements in the index data-space; wherein the data data-element contains information concerning a location of the original data-element and a location of the shadow data-element, thereby creating an association between the original data-element, the shadow data-element and the data data-element; wherein the index data-element records information concerning a location of the data data-element; and wherein the plurality of index data-elements in the index data-space are arranged in the same sequence as the plurality of original data-elements in the original data-space.
- 27. The apparatus of claim 26, wherein the information concerning the locations of the original data-element and shadow data-element recorded in the data data-element includes information identifying a sequential position of those data-elements within their respective data-spaces.
- 28. The apparatus of claim 26, wherein the information concerning the locations of the original data-element and shadow data-element recorded in the data data-element includes information identifying offsets of those data-elements from base-addresses of their respective data-spaces.
- 29. The apparatus of claim 24, wherein the original data-space contains a plurality of original data-elements of a first bit length and the index data-space contains a plurality of index data-elements of a second bit length.
- 30. The apparatus of claim 29, wherein the first bit length and the second bit length are the same length.
- 31. The apparatus of claim 24, wherein the index data-space and data data-space are stored in non-persistent storage.
- 32. The apparatus of claim 24, wherein the index data-space and data data-space are stored in persistent storage.
- 33. A computer program embodied on a computer readable medium for reorganizing a database and concurrently providing access to the database for updates, the database including an original data-space having a plurality of original data-elements, a shadow data-space having a plurality of shadow data-elements, a data data-space having a plurality of data data-elements and an index data-space having a plurality of index data-elements, the method comprising:
program instructions for copying contents of an original data-element within the original data-space to a shadow data-element within the shadow data-space and associating the original data-element and shadow data-element using a data data-element; program instructions for reorganizing the shadow data-space; program instructions for keeping track of a location of an original data-element that is changed after its contents are copied to the shadow data-element by using the data data-element that is located using an index data-element; and program instructions for copying data from the location of the changed original data-element to its corresponding shadow data-element in the reorganized shadow data-space.
- 34. The computer program of claim 33, wherein said program instructions for keeping track of a location of an original data-element that is changed, comprises:
program instructions for intercepting a log request that indicates a change to the original data-element; program instructions for recording information in the data data-element in the data data-space indicating that the original data-element changed; and program instructions for recording a location of the data data-element in the index data-element of the index data-space, wherein a location of the index data-element within the index data-space corresponds to the location of the original data-element within the original data-space.
- 35. The computer program of claim 34, wherein the information recorded in the data data-element in the data data-space includes a type of change that occurred.
- 36. The computer program of claim 35, wherein the type of change recorded is at least one of an addition, an update, and a deletion.
- 37. The computer program of claim 34, wherein the information indicating that the original data-element changed is recorded in non-persistent storage.
- 38. The computer program of claim 34, wherein the information indicating that the original data-element changed is recorded in persistent storage.
- 39. The computer program of claim 34, wherein said program instructions for recording information indicating that the original data-element changed includes recording a position of the original data-element within the original data-space.
- 40. The computer program of claim 39, wherein the recorded position of the original data-element includes an offset of the original data-element from a base-address of the original data-space.
- 41. A computer program embodied on a computer readable medium for reorganizing information in a computer system having an original data-space that contains a plurality of sequentially stored original data-elements, a shadow data-space that contains a plurality of shadow data-elements, a data data-space that contains a plurality of data data-elements, and an index data-space that contains a plurality of sequentially stored index data-elements, the computer program comprising:
program instructions for copying contents of an original data-element within the original data-space to a shadow data-element within the shadow data-space; program instructions for recording a location of the original data-element and a location of the shadow data-element within a data data-element within the data data-space, thereby associating the original data-element, the shadow data-element and the data data-element; program instructions for recording a location of the data data-element within an index data-element within the index data-space, wherein the index data-elements in the index data-space are arranged in the same sequence as their associated original data-elements in the original data-space; program instructions for recording in the data data-element information indicating that a change has occurred in the original data-element associated with the data data-element; and program instructions for applying the change in the original data-element to the shadow data-element associated with the original data-element, in response to detecting the change associated with the original data-element recorded in the data data-element.
- 42. The computer program of claim 41, wherein said program instructions for recording in the data data-element information indicating that a change has occurred in the original data-element, further comprise:
program instructions for intercepting a log request that indicates the change to the original data-element; program instructions for determining a location of the changed original data-element; and program instructions for updating the data data-element associated with the changed original data-element to record the information indicating that a change occurred and to record a type of change that occurred.
- 43. The computer program of claim 42, wherein if the log request indicates that the change is an addition of a new original data-element to the original data-space, the computer program further comprises:
program instructions for adding the data data-element to the data data-space and storing a location of the original data-element within the data data-element; and program instructions for recording a location of the data data-element within the index data-element in the index data-space, wherein the index data-elements in the index data-space are arranged in the same sequence as their associated original data-elements in the original data-space.
- 44. The computer program of claim 42, wherein the data data-element is updated to record information indicating that the original data-element has been at least one of added, updated and deleted.
- 45. The computer program of claim 41, wherein said program instructions for applying the change in the original data-element to its associated shadow data-element, comprises at least one of:
program instructions for adding the shadow data-element to said shadow data-space and storing a location of the shadow data-element within the data data-element, if the data data-element indicates that the original data-element was added to the original data-space; program instructions for copying the contents of the original data-element to the shadow data-element by locating the original data-element and shadow data-element from the location information recorded in the data data-element, if the data data-element indicates that the original data-element was one of updated and added; and program instructions for deleting the shadow data-element by locating the shadow data-element from the location information recorded in the data data-element, if the data data-element indicates that the original data-element located at the original data-element location stored within the data data-element was deleted.
- 46. The computer program of claim 41, wherein the index data-space and data data-space are stored in non-persistent storage.
- 47. The computer program of claim 41, wherein the index data-space and data data-space are stored in persistent storage.
- 48. The computer program of claim 41, wherein the location of the shadow data-element recorded in the data data-element includes a sequential position of the shadow data-element within the shadow data-space.
- 49. The computer program of claim 41, wherein the location of the shadow data-element recorded in the data data-element includes an offset of the shadow data-element from a base address of the shadow data-space.
- 50. The computer program of claim 41, wherein the location of the data data-element recorded in the index data-element is determined by multiplying a sequential position of the data data-element within the data data-space by a bit length of the plurality of data data-elements within the data data-space.
- 51. The computer program of claim 41, wherein the location of the data data-element within the data data-space is determined by dividing a relative base address of the data data-element by a bit length of the plurality of data data-elements within the data data-space.
- 52. The computer program of claim 41, wherein the original data-space contains a plurality of original data-elements of a first bit length and the index data-space contains a plurality of index data-elements of a second bit length.
- 53. The computer program of claim 52, wherein the first bit length and the second bit length are the same length.
- 54. The computer program of claim 52, wherein a location of the index data-element is determined from the location of its associated original data-element by dividing the location of the original data-element by the first bit length to produce a result and multiplying the result by the second bit length.
- 55. The computer program of claim 52, wherein the location of the original data-element is determined from a location of the index data-element by dividing a relative base address of the index data-element by the second bit length to produce a result and multiplying the result by the first bit length.
CROSS REFERENCE TO RELATED APPLICATIONS
[0001] This application is related to a co-pending and commonly assigned patent application entitled, “Data-Space Tracking with Index Data-Spaces and Data Data-Spaces,” Ser. No. ______ (Docket # SVL920020003US1) filed concurrently herewith and incorporated by reference within this application in its entirety.