METHOD, SERVER, AND SYSTEM FOR SHARING RESOURCE DATA
First Claim
1. A method for sharing resource data, applicable to a resource loading server that comprises one or more program instructions, a memory and one or more processors, the one or more program instructions being stored in the memory and executed by the one or more processors, the method comprising:
- reading a preset key value and an index name of resource data from a resource configuration file, the resource configuration file being a resource configuration file preconfigured, and the resource data is same logical data needed for a process of each scene server on a same physical machine;
requesting a memory space from an operating system of the resource loading server according to the preset key value to create a shared memory;
loading the resource data corresponding to the index name from a magnetic disk to the shared memory; and
sharing the resource data with the process of each scene server on the same physical machine.
1 Assignment
0 Petitions
Accused Products
Abstract
A method, a server, and a system for sharing resource data are provided. The method includes: preconfiguring a resource configuration file, reading a preset key value and an index name in the resource configuration file; requesting a memory space from an operating system according to the preset key value to create a shared memory; and loading resource data corresponding to the index name from a magnetic disk to the shared memory, and sharing the resource data with a process of each scene server on a same physical machine.
4 Citations
10 Claims
-
1. A method for sharing resource data, applicable to a resource loading server that comprises one or more program instructions, a memory and one or more processors, the one or more program instructions being stored in the memory and executed by the one or more processors, the method comprising:
-
reading a preset key value and an index name of resource data from a resource configuration file, the resource configuration file being a resource configuration file preconfigured, and the resource data is same logical data needed for a process of each scene server on a same physical machine; requesting a memory space from an operating system of the resource loading server according to the preset key value to create a shared memory; loading the resource data corresponding to the index name from a magnetic disk to the shared memory; and sharing the resource data with the process of each scene server on the same physical machine. - View Dependent Claims (2, 3, 4)
-
-
5. A method for sharing resource data, applicable to scene servers, comprising:
-
starting a process of each scene server on a same physical machine; reading a preset key value in a resource configuration file preconfigured by a resource loading server, the resource configuration file comprising the preset key value and an index name of resource data, and the resource data being same logical data needed for a process of each scene server on a same physical machine; accessing a shared memory according to the preset key value, the shared memory being created by the resource loading server requesting, according to the preset key value, a memory space from an operating system, and the shared memory storing the resource data loaded, according to the index name, by the resource loading server from a magnetic disk; and mapping the resource data in the shared memory to a memory space. - View Dependent Claims (6, 7)
-
-
8. A resource loading server comprising:
-
a configuration unit, configured to preconfigure a resource configuration file, the resource configuration file comprising a preset key value and an index name of resource data, and the resource data being same logical data needed for a process of each scene server on a same physical machine; a first reading unit, configured to read the preset key value and the index name of the resource data in the resource configuration file; a creation unit, configured to request a memory space from an operating system of the resource loading server according to the preset key value to create a shared memory and a sharing unit, configured to load the resource data corresponding to the index name from a magnetic disk to the shared memory, and share the resource data with the process of each scene server on the same physical machine. - View Dependent Claims (9, 10)
-
Specification