CN106470150A - Relation chain storage method and device - Google Patents

Relation chain storage method and device Download PDF

Info

Publication number
CN106470150A
CN106470150A CN201510519913.9A CN201510519913A CN106470150A CN 106470150 A CN106470150 A CN 106470150A CN 201510519913 A CN201510519913 A CN 201510519913A CN 106470150 A CN106470150 A CN 106470150A
Authority
CN
China
Prior art keywords
concern
data entry
target
public identity
index
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510519913.9A
Other languages
Chinese (zh)
Other versions
CN106470150B (en
Inventor
刘刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201510519913.9A priority Critical patent/CN106470150B/en
Publication of CN106470150A publication Critical patent/CN106470150A/en
Application granted granted Critical
Publication of CN106470150B publication Critical patent/CN106470150B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a kind of relation chain storage method and device, belong to networking technology area.Method includes:Receive the ID of concern public identity;According to ID and index Data Entry for grouping information, determine target index and the first object offset address of ID;With target index be index, with first object offset address as offset address, in target data entry determine target storage address;ID and concern state are stored to target storage address.The present invention passes through the storage mode using classification, the booking reader of public identity is carried out packet storage, based on the secondary index set up, ID and concrete grouping information according to booking reader, it is stored in unique positions by corresponding with the concern state of this booking reader for ID, change for follow-up user's concern state etc. provides status indication function, additionally it is possible to ensure data consistency while ensure that the high efficiency of operation.

Description

Relation chain storage method and device
Technical field
The present invention relates to networking technology area, particularly to a kind of relation chain storage method and device.
Background technology
With the development of network technology, the function of information service platform is stronger and stronger.Information service is actually Be to carry out between user and user message transmission provide processing platform, and realize message transmission premise be Information service platform stores to the relation chain between user.The two side user A for message transmission For user B, user A has multiple good friends, and user B equally has multiple good friends, for these use The relation chain at family is required to safeguard.Relation chain storage of the prior art is based primarily upon database mode:As incited somebody to action The corresponding data of good friend of user is all saved in data base, is used as major key by ID such as QQ, To inquire about the record of the good friend in data base, and in management with when safeguarding, to build one in internal memory according to data base The data structure of individual chained list, thus realize elongated data manipulation.
However, with the diversification of information service, occurring in that as the information service form such as public identifier.Businessman (i.e. B side) can send various notification messages by public identity to user (i.e. C side), marketing property disappears Accumulating user, C side user can also actively be exchanged with B side businessman, transmission for breath or alive messages etc. Upstream message or actively paid close attention to, to become the booking reader of B side by operation activity under line.This information clothes The accumulation over time of business form is so that the booking reader's quantity corresponding to public identifier is increasing, public The relation chain of mark is more and more longer, for the relation chain being related to huge booking reader's amount, we term it long Relation chain.
During realizing the present invention, inventor finds that prior art at least has problems with:
For long relation chain, the booking reader's amount due to being related to is huge, if being also adopted by existing depositing Storage mode, once being related to substantial amounts of high concurrent the relation chain operation such as to access or add, delete and change, Not only the efficiency of relation chain operation is very low, and it is difficult to ensure that data consistency.
Content of the invention
In order to solve problem of the prior art, embodiments provide a kind of relation chain storage method and dress Put.Described technical scheme is as follows:
On the one hand, there is provided a kind of relation chain storage method, methods described includes:
Receive the ID of concern public identity;
According to described ID and index Data Entry for grouping information, determine described ID Target index and first object offset address, described index is that the Data Entry of grouping information includes described public affairs The grouping information of multiple types of concern user of many marks, described target indexes and is located for described ID The group character of packet;
Indexed for index, with described first object offset address as offset address, in number of targets with described target According to determination target storage address in entry;
Described ID and concern state are stored to described target storage address.
On the other hand, there is provided a kind of relation chain storage device, described device includes:
Receiver module, for receiving the ID of concern public identity;
Determining module, for according to described ID and index Data Entry for grouping information, determining The target index of described ID and first object offset address, described index is the data strip of grouping information Mesh includes the grouping information of multiple types of concern user of described public identity, and described target indexes as institute State the group character of packet that ID is located;
Storage address determining module, offsets ground for indexing with described target for index, with described first object Location is offset address, determines target storage address in target data entry;
Memory module, for storing described ID and concern state to described target storage address.
The beneficial effect that technical scheme provided in an embodiment of the present invention is brought is:
By the storage mode using classification, the booking reader of public identity is carried out packet storage, based on building Vertical secondary index, according to ID and the concrete grouping information of booking reader, by ID and should The concern state correspondence of booking reader is stored in unique positions, for the change of follow-up user's concern state etc. Change and provide status indication function, additionally it is possible to ensure that data is consistent while ensure that the high efficiency of operation Property, further, this storage mode can effectively save memory space, reduces memory copying operation, has Effect lifting overall performance.
Brief description
For the technical scheme being illustrated more clearly that in the embodiment of the present invention, below will be to institute in embodiment description Need use accompanying drawing be briefly described it should be apparent that, drawings in the following description are only the present invention Some embodiments, for those of ordinary skill in the art, on the premise of not paying creative work, Other accompanying drawings can also be obtained according to these accompanying drawings.
Fig. 1 is a kind of relation chain storage method flow chart provided in an embodiment of the present invention;
Fig. 2 is a kind of relation chain storage method flow chart provided in an embodiment of the present invention;
Fig. 3 A is a kind of storage format schematic diagram provided in an embodiment of the present invention;
Fig. 3 B is another kind storage format schematic diagram provided in an embodiment of the present invention;
Fig. 4 is the configuration diagram of information service system provided in an embodiment of the present invention;
Fig. 5 is a kind of structural representation of relation chain storage device provided in an embodiment of the present invention;
Fig. 6 is a kind of block diagram of relation chain storage device provided in an embodiment of the present invention.
Specific embodiment
For making the object, technical solutions and advantages of the present invention clearer, below in conjunction with accompanying drawing to the present invention Embodiment is described in further detail.
Information service, refer to as instant messaging service, social networking application service and B2P (Business to Person, Trade company is to personal user) etc. some be related to the service of information exchange.
Instant messaging:(Instant messaging, abbreviation IM) is a terminal service it is allowed to two people or many People uses the instant transmission message language in networking, archives, voice and video.Instant messaging is according to use Enterprise instant communication and website instant messaging can be divided into, the object according to carrying can be divided into mobile phone IMU again News and PC (Personal Computer, PC) instant messaging, wherein, mobile telephone instant communication is permissible Represent note, PC instant messaging can represent website, video instant communication.
Social networking application service, be a terminal service, can provide the user personal information show, user it Between the service such as information exchange.
Information:Refer to message, message, communication system transmission and the object processing, refer to human society propagation All contents, such as word, picture, voice, video etc..People passes through to obtain, identifies nature and society Different information to distinguish different things, recognized and reforming world.In all communication and control systems, Information is a kind of form of universal relation.
C2C message (Customer-to-Customer Message), is primarily referred to as instant messaging visitor in the present invention Information between the end of family, is exactly generally mutually mutually to send in the middle of chat and communication process between client Information, generally these message need the transfer through server end.
B2C message (Business-to-Customer Message), is primarily referred to as in the present invention from server business Family this side of server is actively sent to the various information of instant communication terminal, and including text, picture, sound regards The multimedia messages such as frequency.
C2B message (Customer-to-Business Message), be primarily referred to as in the present invention terminal use from The various types of messages that terminal active sends to the businessman of server end, these message belong to the information of data feedback channel, Including text, picture, the multimedia messages such as audio frequency and video.
Social networks chain refers to point-to-point relation between men, and everyone can regard is in social group A node, and the line between 2 points becomes a relation chain.Acquaintance network is constituted Relation chain can be referred to as strong relation chain, and can based on the relation chain that the formation such as hobby, interest is got up for some To be referred to as weak relation chain or micro- relation chain.
Public identifier is the application account that developer or businessman apply on information service platform, by public mark Know, developer or businessman can on information service platform, based on modes such as word, picture, voice, videos, Realize carrying out information pushing in all directions to users or linked up with users or interactive.For with The amount larger social networks chain corresponding to public identifier in family can become long relation chain.
Fig. 1 is a kind of flow chart of relation chain storage method provided in an embodiment of the present invention.Referring to Fig. 1, the party Method includes:
101st, receive the ID of concern public identity.
102nd, according to this ID and index Data Entry for grouping information, determine this ID Target index and first object offset address, this index is that the Data Entry of grouping information includes this public mark The grouping information of the multiple types of concern user known, this target indexes dividing for packet that this ID is located Group mark.
103rd, indexed for index, with this first object offset address as offset address, in number of targets with this target According to determination target storage address in entry.
104th, this ID and concern state are stored to this target storage address.
Alternatively, according to this ID and index Data Entry for grouping information, determine that this user marks The target index known and first object offset address include:
By the first default feature value-based algorithm, obtain the user characteristicses value of this ID, this user characteristicses value Represent this ID for unique;According to this user characteristicses value, this Data Entry is inquired about this target rope Draw and this first object offset address.
Alternatively, this ID and concern state are stored to after this target storage address, the method is also Including:When receiving the relation chain request of this ID transmission, to this ID corresponding concern shape State carries out asking corresponding editor with this relation chain.
Alternatively, this relation chain asks to be used for:This concern status modifier is deletion state;Or, this is closed Note status modifier is masked state;Or, this concern status modifier is to cancel concern state.
Alternatively, the method also includes:
The storage address information of described ID is stored to the corresponding Data Entry of the first assigned indexes, The corresponding Data Entry of described first assigned indexes at least includes having cancelled the ID of concern;Or,
When receiving batch deletion action, by depositing of the described corresponding multiple ID of batch deletion action Storage address information stores to the corresponding Data Entry of the second assigned indexes, and described second assigned indexes are corresponding Data Entry at least includes deleted ID;Or,
When receiving the shielding request that described ID sends, by the storage address letter of described ID Breath stores to the corresponding Data Entry of the 3rd assigned indexes, the corresponding Data Entry of described 3rd assigned indexes At least include having shielded the ID of described public identity.
Alternatively, after receiving the ID of concern public identity, the method also includes:
Determine the user data entry with this ID for index;
By the second default feature value-based algorithm, obtain public's eigenvalue of this public identity, this public's eigenvalue Represent this public identity for unique;
According to this well-known characteristic value, this user data entry determines the second target offset address;
By this public identity and concern behavioural information, it is stored in this second target offset address.
Alternatively, this concern behavioural information includes:Public identity is grouped, public identity pocket transmission news identify, Public identity station location marker, whether receive PUSH message mark, public identity single-shot message identifier, the time letter Breath and the combination listening to one or more in type information.
Above-mentioned all optional technical schemes, can adopt the alternative embodiment arbitrarily combining to form the disclosure, This no longer repeats one by one.
Fig. 2 is a kind of flow chart of relation chain storage method provided in an embodiment of the present invention.Referring to Fig. 2, this is real Apply example to specifically include:
201st, receive the ID of concern public identity.
This reception process can be to receive user the concern of public identity is operated.Grasp when receiving this concern When making, public identity of interest can be operated with this concern according to the ID carrying out paying close attention to operation, enter The storage of row relation chain.
202nd, by the first default feature value-based algorithm, obtain the user characteristicses value of this ID, this user is special Value indicative is used for unique this ID of expression.
This first default feature value-based algorithm can be hash algorithm, can be defeated by random length by this algorithm Enter to be transformed into the output of regular length, thus ID can be carried out storage location according to unified rule Mapping.
203rd, according to this user characteristicses value, in the Data Entry for grouping information for the index, determine that this target indexes With this first object offset address, wherein, this target indexes the group character of the packet that is located for ID.
Storage for grouping information can take key assignments (key-Value) storage mode, that is to say, index For grouping information, the key assignments in Data Entry is the grouping information of multiple types of concern user of public identity, The Data Entry that this bar rope is cited as grouping information can also regard metadata as, in embodiments of the present invention, can By the inquiry to metadata, to determine this ID should be stored in which position of which packet.
Further, the key assignments of this Data Entry is on the basis of the grouping information comprising above-mentioned multiple type, Can also include as each field in table 1 below.
Table 1
By to the analysis of user characteristicses value, it may be determined that its target storage address, this concrete analysis process can With as follows:According to user characteristicses value first specifies the value of digit, determines that targeted packets identify, according to this The second of user characteristicses value specifies the value of digit, determines the first object offset address in this packet.When So, this analysis process can also adopt other forms, such as carries out quadratic eigenvalue to based on user characteristicses value Calculate, to avoid storage location to clash, the embodiment of the present invention is not especially limited.
Using above-mentioned key value structure, grouping information is stored, by multiple key value structure in each packet ID stored, it is possible to achieve to the booking reader in a B2C relation chain, by be grouped into Line pipe is managed.Fig. 3 A is a kind of storage format schematic diagram that the embodiment of the present invention is provided.Referring to Fig. 3 A, rope The Data Entry being cited as grouping information (puin_info) is first order storage, and indexes the data for group character Entry stores for the second level, and the Data Entry that each indexes as group character all includes multiple user data. As puin_gid_N represents nth packet, and each user data of Data Entry can be expressed as one two Binary data { concern state, ID }, i.e. value=[{ state, uin }].In addition, for institute in table 1 The interpolation queue shown, delete queue, reclaim queue and virtual Groups List etc., can using as in Fig. 3 A Form shown in a line afterwards.
It should be noted that each queue described in the embodiment of the present invention, arranged in the case of recovery force, this recovery Queue can also obtain, using feature value-based algorithm, the eigenvalue that is recovered ID, comes further according to this feature value Determine storage location in reclaiming queue for the storage address information being recovered ID, that is to say, key= R_ (uin) _ (groupid), r_ are also hash function.Generally cancelling concern or clearing up booking reader's in batches When, in addition to editor user is in the concern state in the Data Entry of its group character, it is also possible that The storage address information stating ID stores to the corresponding Data Entry of the first assigned indexes, and it determined In the same manner, therefore not to repeat here for the process of journey and above-mentioned determination target storage address.
For each queue described in other embodiment of the present invention, for reclaiming queue, can there are following steps: The storage address information of described ID is stored to the corresponding Data Entry of the first assigned indexes, described The corresponding Data Entry of first assigned indexes at least includes having cancelled the ID of concern.
For deleting queue, can there are following steps:When receiving batch deletion action, by described batch The storage address information of the corresponding multiple ID of deletion action stores data corresponding to the second assigned indexes In entry, the corresponding Data Entry of described second assigned indexes at least includes deleted ID.
For shielding queue, can there are following steps:When the shielding request receiving described ID transmission When, the storage address information of described ID is stored to the corresponding Data Entry of the 3rd assigned indexes, The corresponding Data Entry of described 3rd assigned indexes at least includes having shielded the ID of described public identity.
It should be noted that safeguard the queues such as a recovery queue in storage format, so that follow-up Error in data is avoided the occurrence of it is also possible to send the ID foundation of scene as some during verification concordance, As when determining whether that a certain user sends message, whether can reclaim in queue according to it, thus carrying The concordance of high data, improves the accuracy of relation chain operation, thus lifting the efficiency of relation chain operation.
204th, indexed for index, with this first object offset address as offset address, in number of targets with this target According to determination target storage address in entry.
205th, this ID and concern state are stored to this target storage address.
In above-mentioned steps 204 and 205, address procedures can be regarded as, by ID and concern shape State be stored in determined by target storage address.
Based on above-mentioned storage format, in order to save memory space, the user data generally preserving is one two and enters Data { concern state, ID } processed, i.e. { state, uin }.Wherein, concern state is used for identifying this The state of user, such as deletes state, masked state or cancels concern state etc., is easy to follow-up affairs behaviour Make and consistency desired result.Alternatively, the size of data of this concern state can be 1Byte, i.e. 8 flag bits. ID can be the information for this user of unique mark for the QQ grade of this user, and its size of data can Think 4Bytes.
After performing this storing step, then can carry out information exchange in subsequent transaction operation, such as to certain The user of individual packet sends a notification message.
206th, when receiving the relation chain request of this ID transmission, the corresponding concern to this ID State carries out asking corresponding editor with this relation chain.
Relation chain request can have following effect:This concern status modifier is deletion state;Or, this is closed Note status modifier is masked state;Or, this concern status modifier is to cancel concern state.
Then for the change of above-mentioned concern state, can be to the ID pair storing to target storage position The concern state answered is changed.How it specifically determines to the concern state being stored in which storage location Enter edlin, can be carried out as institute during above-mentioned according to the ID of the request object of this relation chain request The eigenvalue mode referring to is determined, and will not be described here.
Correspondingly, can be according to the concrete request action type of relation chain request, it is right as asking using this to determine The ID corresponding storage location information Store of elephant to which queue, to ensure follow-up data concordance.
Further, when receiving the ID of concern public identity in addition it is also necessary to this ID Relation chain is safeguarded, this detailed process can include:Determine the user data with this ID for index Entry;By the second default feature value-based algorithm, obtain public's eigenvalue of this public identity, this public's feature It is worth and represent this public identity for unique;According to this public's eigenvalue, this user data entry determines the Two target offset addresses;By this public identity and concern behavioural information, it is stored in this second target offset ground Location.
For this ID, can be used for storing which a user paid close attention to based on this storage format Public identity and the concern behavioural information to each public identity.Its storage format can also adopt key assignments side Formula, as shown in table 2 and Fig. 3 B, in table 2, with the Value of the user data entry for index for the ID In, store this public identity and concern behavioural information etc..Further, this concern behavioural information includes: Public identity packet, public identity pocket transmission news mark, public identity station location marker, whether receive push and disappear Cease mark, public identity single-shot message identifier, position, temporal information and listen to one in type information Or multinomial combination.Wherein, public identity station location marker refer to this user of interest with public identity as rope The Data Entry storage location drawn, this position may refer to the storage location of this ID its data entry.
Table 2
It should be noted that above-mentioned for B2C store and C2B storage for, its feature being adopted Value-based algorithm can be different, that is to say, the first default feature value-based algorithm and the second default feature value-based algorithm can not With the embodiment of the present invention is not especially limited to this.
Further, the storage of above-mentioned B2C and the storage of C2B can be that is to say with bidirectional inquiry, passing through When the relation chain of B2C is inquired about, any one ID in relation chain can also be inquired further and correspond to Data Entry, and when being inquired about by the relation chain of C2B, can also inquire in relation chain further Grouping information of the corresponding Data Entry of any one public identity and public identity etc..
Method provided in an embodiment of the present invention, by the storage mode using classification, by the subscription of public identity User carries out packet storage, based on the secondary index set up, according to the ID of booking reader and concrete Grouping information, is stored in unique positions by corresponding with the concern state of this booking reader for ID, is The change of follow-up user's concern state etc. provides status indication function, in the high efficiency that ensure that operation Simultaneously additionally it is possible to ensure data consistency, further, it is empty that this storage mode can effectively save storage Between, reduce memory copying operation, effectively lift overall performance.Further, maintain independent interpolation team Row, deletion queue, shielding queue and recovery queue etc., independent of the Data Entry of storage ID, make Obtain the transactional manner operation that the memory space of distribution can be adopted with substep, simultaneously in order to specifically run demand, Importing and exporting of relation chain data can quickly be carried out in rear end by batch.And, based on this B2C to C2B Intercommunication indexed mode, can quickly search and position and pay close attention to related data structure, realize efficiently Various operations it is also possible to be able to maintain that the concordance of final relation chain data under the operation of high concurrent;Energy Enough effectively saving memory spaces, reduce memory copying operation, effectively lift overall performance.
In order to further describe method provided in an embodiment of the present invention, basic below based on information service system Framework and the concrete function of each service module, in detail to the present embodiments relate to relation chain stored Journey is introduced, and this Fig. 4 is the configuration diagram of information service system provided in an embodiment of the present invention, referring to Fig. 4, this information service system includes:
Information service client end, can be instant communication client or social networking application client, can be used for sending out The displaying sent and receive the message such as word, picture, video and audio frequency and carry out message.Specifically, this letter Breath service client can carry out message by messaging system interface server and pull.When information service client end When receiving the message informing that messaging system server sends, actively cancel breath from message server pull-up.Should Message data feedback channel can also be passed through in information service client end, by various operation behavior information of client and right Answer the statistical report interface server of reporting parameters information service side, form the pass of new B side and C side simultaneously Tethers system or by user actively concern, cancel the operation reporting system such as concern, shielding, and by user to B The click behavior of the message that side pushes reports system.
Relation catenary system, for preserving and recording the incidence relation between account.This incidence relation may refer to Strong association such as friend relation or weak rigidity, such as concern relation, listen to relation.In strong incidence relation Under, can be man-to-man relation between account and account, under weak rigidity administration, usual form is one Account A identifies a sender, and a set B mark can accept account A and can send all of information Account.When account A has message to need to send, messenger service can be by dispatch service from relation catenary system In, obtain the account of transmission message in the related relation chain of this account A and receive message account.Certainly, This relation catenary system is the system that can change, when client user's active is cancelled or pays close attention to some account When, upstream message can be sent by messaging system interface server so that relation catenary system changes phase The concern relation answered.
This relation catenary system takes as the primary interface of information service client end and rear end long relation chain system docking Business device, generally disposes the access server nearby being used for according to different operators ISP.And, this relation chain User can such as be cancelled by system to the various operation behaviors of B side account, the behavior such as pay close attention to and shield and pass through This server is sent to long relation chain logical server.
Long relation chain logical server is patrolled as the foundation maintenance of implementation relation chain and the main business of relevant updates Collect server, the various operation behaviors of the terminal that relation chain interface service passes over can be received.For C2B With B2C data structure as described above and method for organizing, to select different feature value-based algorithms, to two Level storage organization is safeguarded, ID is saved in the middle of relation chain storage system the most at last.This long relation Logical server is additionally operable to read number bag data, batch operation relation chain storage system from vermicelli number server System.
Vermicelli management server is the main entrance server of long relation chain system maintenance, usual public mark Knowing the people just having started not having vermicelli or concern when establishment can be considerably less, and the needs in order to run would generally Import a collection of vermicelli, the such as user of electric business Shopping Behaviors from other corresponding business scenarios, allow user to pay close attention to Corresponding electric business public identity, to import vermicelli now by vermicelli manager, but you, to a B side Public identity is accumulated over time, needs to derive the vermicelli of concern, carries out secondary analysis and excavation, needs Carried out by this server.In order to ensure the concordance of relation chain final data, such as user has paid close attention to a certain Individual public identity, then must store in the middle of the concern vermicelli list of corresponding public identity this vermicelli or The user being deleted in the middle of delete list, cannot correspond in the middle of the vermicelli list of public identity again, Need periodically such as (generally to change according to vermicelli daily or every several hours by vermicelli management server Frequency undetermined, the frequent maintenance conforming cycle is shorter).Read statistical analysis system reporting of user Such as shield the data of behavior, generate shielding number bag vermicelli, thoroughly delete from relation catenary system.
Vermicelli number bag service is used for accepting the management of vermicelli management server, and importing various public identity needs Run and be actively added the vermicelli number bag of concern or interim storage needs the number bag of derivation, and for long pass Tethers logical server reads different number bags.
Relation chain storage system is used for providing the relation chain storage method of foregoing description, for C2B relation chain number According to can be carried out using one-level storage, the long relation chain data for B2C can adopt secondary storage, and logical Frequently be distributed key-value system it is ensured that data is not lost and reliability, final relation chain number According to land preservation.This relation chain storage system can accept the various operation ratios of long relation chain logical server As cancellation and concern and masking operation etc..
Statistical analysis system is used for the shielding of receiving terminal report of user, the behavior of cancellation and concern and user couple The click behavioral data of the Message Opcode that B side pushes, and read vermicelli user operation for vermicelli management server The analysis logged result of behavior.It should be noted that vermicelli described herein is ordering in above-described embodiment Read user, concern user, refer to pay close attention to the user of some public identity.
Fig. 5 is a kind of structural representation of relation chain storage device provided in an embodiment of the present invention.Referring to Fig. 5, Described device includes:
Receiver module 501, for receiving the ID of concern public identity;
Determining module 502, for according to described ID and index Data Entry for grouping information, really The target index of fixed described ID and first object offset address, described index is the data of grouping information Entry includes the grouping information of multiple types of concern user of described public identity, and described target indexes and is The group character of packet that described ID is located;
Storage address determining module 503, for being indexed for index, with the skew of described first object with described target Address is offset address, determines target storage address in target data entry;
Memory module 504, for storing described ID and concern state to described target storage address.
Alternatively, described determining module is used for, by the first default feature value-based algorithm, obtaining described ID User characteristicses value, described user characteristicses value is used for unique representing described ID;Special according to described user Value indicative, determines described target index and described first object offset address in described Data Entry.
Alternatively, described device also includes:
Editor module, for when receiving the relation chain request that described ID sends, to described user Identify corresponding concern state to carry out asking corresponding editor with described relation chain.
Alternatively, described relation chain asks to be used for:
Described concern status modifier is deletion state;Or,
Described concern status modifier is masked state;Or,
Described concern status modifier is to cancel concern state.
Alternatively, described memory module is used for:
The storage address information of described ID is stored to the corresponding Data Entry of the first assigned indexes, The corresponding Data Entry of described first assigned indexes at least includes having cancelled the ID of concern;Or,
When receiving batch deletion action, by depositing of the described corresponding multiple ID of batch deletion action Storage address information stores to the corresponding Data Entry of the second assigned indexes, and described second assigned indexes are corresponding Data Entry at least includes deleted ID;Or,
When receiving the shielding request that described ID sends, by the storage address letter of described ID Breath stores to the corresponding Data Entry of the 3rd assigned indexes, the corresponding Data Entry of described 3rd assigned indexes At least include having shielded the ID of described public identity.
Alternatively, described device also includes:
Data Entry determining module, for determining the user data entry with described ID for index;
Characteristic value acquisition module, for by the second default feature value-based algorithm, obtaining the public affairs of described public identity Many eigenvalues, described public's eigenvalue is used for the described public identity of unique expression;
Offset address determining module, for according to described public's eigenvalue, true in described user data entry Fixed second target offset address;
Concern behavioural information memory module, for by described public identity and concern behavioural information, being stored in Described second target offset address.
Alternatively, described concern behavioural information includes:Public identity is grouped, public identity pocket transmission news identify, Public identity station location marker, whether receive PUSH message mark, public identity single-shot message identifier, the time letter Breath and the combination listening to one or more in type information.
It should be noted that:Above-described embodiment provide relation chain storage device when relation chain stores, only with The division of above-mentioned each functional module is illustrated, in practical application, can be as desired by above-mentioned work( Distribution can be completed by different functional modules, the internal structure of equipment will be divided into different functional modules, To complete all or part of function described above.In addition, the relation chain storage dress that above-described embodiment provides Put and belong to same design with relation chain storage method embodiment, it implements process and refers to embodiment of the method, Here repeat no more.
Fig. 6 is a kind of block diagram of the relation chain storage device 600 according to an exemplary embodiment.For example, Device 600 may be provided in a server.With reference to Fig. 6, device 600 includes process assembly 622, and it enters One step includes one or more processors, and the memory resource representated by memorizer 632, is used for depositing Storage can be by the instruction of the execution of processing component 622, such as application program.The application of storage in memorizer 632 Program can include one or more each correspond to one group instruction module.Additionally, treatment group Part 622 is configured to execute instruction, to execute above-mentioned relation chain storage method.
Device 600 can also include the power management that a power supply module 626 is configured to performs device 600, One wired or wireless network interface 650 is configured to for device 600 to be connected to network, and an input is defeated Go out (I/O) interface 658.Device 600 can operate based on the operating system being stored in memorizer 632, example As Windows ServerTM, Mac OS XTM, UnixTM,LinuxTM, FreeBSDTMOr it is similar.
One of ordinary skill in the art will appreciate that all or part of step realizing above-described embodiment can be passed through Hardware come to complete it is also possible to instructed by program correlation hardware complete, described program can be stored in In a kind of computer-readable recording medium, storage medium mentioned above can be read only memory, disk or CD etc..
The foregoing is only presently preferred embodiments of the present invention, not in order to limit the present invention, all the present invention's Within spirit and principle, any modification, equivalent substitution and improvement made etc., should be included in the present invention's Within protection domain.

Claims (14)

1. a kind of relation chain storage method is it is characterised in that methods described includes:
Receive the ID of concern public identity;
According to described ID and index Data Entry for grouping information, determine described ID Target index and first object offset address, described index is that the Data Entry of grouping information includes described public affairs The grouping information of multiple types of concern user of many marks, described target indexes and is located for described ID The group character of packet;
Indexed for index, with described first object offset address as offset address, in number of targets with described target According to determination target storage address in entry;
Described ID and concern state are stored to described target storage address.
2. method according to claim 1 is it is characterised in that according to described ID and index For the Data Entry of grouping information, determine target index and the first object offset address bag of described ID Include:
By the first default feature value-based algorithm, obtain the user characteristicses value of described ID, described user is special Value indicative is used for the described ID of unique expression;
According to described user characteristicses value, in described Data Entry, determine described target index and described first Target offset address.
3. method according to claim 1 is it is characterised in that by described ID and pay close attention to state Store to after described target storage address, methods described also includes:
When receiving the relation chain request that described ID sends, the corresponding concern to described ID State carries out asking corresponding editor with described relation chain.
4. method according to claim 3 is it is characterised in that described relation chain asks to be used for:
Described concern status modifier is deletion state;Or,
Described concern status modifier is masked state;Or,
Described concern status modifier is to cancel concern state.
5. method according to claim 4 is it is characterised in that methods described also includes:
The storage address information of described ID is stored to the corresponding Data Entry of the first assigned indexes, The corresponding Data Entry of described first assigned indexes at least includes having cancelled the ID of concern;Or,
When receiving batch deletion action, by depositing of the described corresponding multiple ID of batch deletion action Storage address information stores to the corresponding Data Entry of the second assigned indexes, and described second assigned indexes are corresponding Data Entry at least includes deleted ID;Or,
When receiving the shielding request that described ID sends, by the storage address letter of described ID Breath stores to the corresponding Data Entry of the 3rd assigned indexes, the corresponding Data Entry of described 3rd assigned indexes At least include having shielded the ID of described public identity.
6. method according to claim 1 is it is characterised in that receive user's mark of concern public identity After knowledge, methods described also includes:
Determine the user data entry with described ID for index;
By the second default feature value-based algorithm, obtain public's eigenvalue of described public identity, the described public is special Value indicative is used for the described public identity of unique expression;
According to described public's eigenvalue, described user data entry determines the second target offset address;
By described public identity and concern behavioural information, it is stored in described second target offset address.
7. method according to claim 6 is it is characterised in that described concern behavioural information includes:Public Crowd identifies packet, public identity pocket transmission news mark, public identity station location markers, whether receives PUSH message Mark, public identity single-shot message identifier, temporal information and listen to one or more in type information Combination.
8. a kind of relation chain storage device is it is characterised in that described device includes:
Receiver module, for receiving the ID of concern public identity;
Determining module, for according to described ID and index Data Entry for grouping information, determining The target index of described ID and first object offset address, described index is the data strip of grouping information Mesh includes the grouping information of multiple types of concern user of described public identity, and described target indexes as institute State the group character of packet that ID is located;
Storage address determining module, offsets ground for indexing with described target for index, with described first object Location is offset address, determines target storage address in target data entry;
Memory module, for storing described ID and concern state to described target storage address.
9. device according to claim 8 is it is characterised in that described determining module is used for by first Default feature value-based algorithm, obtains the user characteristicses value of described ID, and described user characteristicses value is used for unique Represent described ID;According to described user characteristicses value, described Data Entry determines described target rope Draw and described first object offset address.
10. device according to claim 8 is it is characterised in that described device also includes:
Editor module, for when receiving the relation chain request that described ID sends, to described user Identify corresponding concern state to carry out asking corresponding editor with described relation chain.
11. devices according to claim 10 are it is characterised in that described relation chain asks to be used for:
Described concern status modifier is deletion state;Or,
Described concern status modifier is masked state;Or,
Described concern status modifier is to cancel concern state.
12. devices according to claim 11 are it is characterised in that described memory module is used for:
The storage address information of described ID is stored to the corresponding Data Entry of the first assigned indexes, The corresponding Data Entry of described first assigned indexes at least includes having cancelled the ID of concern;Or,
When receiving batch deletion action, by depositing of the described corresponding multiple ID of batch deletion action Storage address information stores to the corresponding Data Entry of the second assigned indexes, and described second assigned indexes are corresponding Data Entry at least includes deleted ID;Or,
When receiving the shielding request that described ID sends, by the storage address letter of described ID Breath stores to the corresponding Data Entry of the 3rd assigned indexes, the corresponding Data Entry of described 3rd assigned indexes At least include having shielded the ID of described public identity.
13. devices according to claim 8 are it is characterised in that described device also includes:
Data Entry determining module, for determining the user data entry with described ID for index;
Characteristic value acquisition module, for by the second default feature value-based algorithm, obtaining the public affairs of described public identity Many eigenvalues, described public's eigenvalue is used for the described public identity of unique expression;
Offset address determining module, for according to described public's eigenvalue, true in described user data entry Fixed second target offset address;
Concern behavioural information memory module, for by described public identity and concern behavioural information, being stored in Described second target offset address.
14. devices according to claim 13 are it is characterised in that described concern behavioural information includes: Public identity packet, public identity pocket transmission news mark, public identity station location marker, whether receive push and disappear Cease mark, public identity single-shot message identifier, temporal information and listen to one or more in type information Combination.
CN201510519913.9A 2015-08-21 2015-08-21 Relation chain storage method and device Active CN106470150B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510519913.9A CN106470150B (en) 2015-08-21 2015-08-21 Relation chain storage method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510519913.9A CN106470150B (en) 2015-08-21 2015-08-21 Relation chain storage method and device

Publications (2)

Publication Number Publication Date
CN106470150A true CN106470150A (en) 2017-03-01
CN106470150B CN106470150B (en) 2020-04-24

Family

ID=58229105

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510519913.9A Active CN106470150B (en) 2015-08-21 2015-08-21 Relation chain storage method and device

Country Status (1)

Country Link
CN (1) CN106470150B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108830704A (en) * 2018-06-28 2018-11-16 中国建设银行股份有限公司 Supervise identity configuration method and device
CN110781375A (en) * 2018-07-31 2020-02-11 阿里巴巴集团控股有限公司 User state identification determining method and device
CN111064657A (en) * 2019-12-30 2020-04-24 广州酷狗计算机科技有限公司 Method, device and system for grouping concerned accounts
CN111324674A (en) * 2020-01-20 2020-06-23 腾讯科技(深圳)有限公司 Service processing method, device, server and storage medium
CN112153476A (en) * 2020-09-22 2020-12-29 游艺星际(北京)科技有限公司 Interactive data processing method and device, server and storage medium
CN112182027A (en) * 2020-09-11 2021-01-05 北京达佳互联信息技术有限公司 Information query method and device, electronic equipment and storage medium
CN114168068A (en) * 2020-09-10 2022-03-11 美光科技公司 Memory search component

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080147861A1 (en) * 2006-12-13 2008-06-19 Takumi Oishi Data distribution network and an apparatus of index holding
CN103731459A (en) * 2012-10-15 2014-04-16 阿里巴巴集团控股有限公司 Interaction data propagation method and server based on social network service
CN103838757A (en) * 2012-11-26 2014-06-04 腾讯科技(深圳)有限公司 System and method for processing long relation chain data of user
CN104468318A (en) * 2013-09-18 2015-03-25 腾讯科技(北京)有限公司 Method and server for recovering reverse relationship chain in network communication
CN104615595A (en) * 2013-11-04 2015-05-13 腾讯科技(北京)有限公司 Data processing method and social media storage platform

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080147861A1 (en) * 2006-12-13 2008-06-19 Takumi Oishi Data distribution network and an apparatus of index holding
CN103731459A (en) * 2012-10-15 2014-04-16 阿里巴巴集团控股有限公司 Interaction data propagation method and server based on social network service
CN103838757A (en) * 2012-11-26 2014-06-04 腾讯科技(深圳)有限公司 System and method for processing long relation chain data of user
CN104468318A (en) * 2013-09-18 2015-03-25 腾讯科技(北京)有限公司 Method and server for recovering reverse relationship chain in network communication
CN104615595A (en) * 2013-11-04 2015-05-13 腾讯科技(北京)有限公司 Data processing method and social media storage platform

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108830704A (en) * 2018-06-28 2018-11-16 中国建设银行股份有限公司 Supervise identity configuration method and device
CN110781375A (en) * 2018-07-31 2020-02-11 阿里巴巴集团控股有限公司 User state identification determining method and device
CN111064657A (en) * 2019-12-30 2020-04-24 广州酷狗计算机科技有限公司 Method, device and system for grouping concerned accounts
CN111324674A (en) * 2020-01-20 2020-06-23 腾讯科技(深圳)有限公司 Service processing method, device, server and storage medium
CN114168068A (en) * 2020-09-10 2022-03-11 美光科技公司 Memory search component
CN114168068B (en) * 2020-09-10 2024-05-14 美光科技公司 Memory search component
CN112182027A (en) * 2020-09-11 2021-01-05 北京达佳互联信息技术有限公司 Information query method and device, electronic equipment and storage medium
CN112182027B (en) * 2020-09-11 2024-03-01 北京达佳互联信息技术有限公司 Information query method, device, electronic equipment and storage medium
CN112153476A (en) * 2020-09-22 2020-12-29 游艺星际(北京)科技有限公司 Interactive data processing method and device, server and storage medium

Also Published As

Publication number Publication date
CN106470150B (en) 2020-04-24

Similar Documents

Publication Publication Date Title
CN106470150A (en) Relation chain storage method and device
CN104704524B (en) Information discloses system, information open server, communication terminal, information published method and non-transient computer-readable medium
CN104954322B (en) A kind of binding processing method of account, apparatus and system
Chen et al. TruSMS: A trustworthy SMS spam control system based on trust management
CN104113466A (en) Harassing phone call identification method, client, server and system
CN105991408B (en) A kind of message treatment method, device and processing server
CN102185841A (en) Classified data transmission method and system
CN104573109A (en) System, terminal and method for automatic recommendation based on group relation
US8489694B2 (en) Peer-to-peer collaboration of publishers in a publish-subscription environment
CN108933819A (en) A kind of information-pushing method based on block chain
CN108549965A (en) Data processing method and data processing platform (DPP), server
CN106095789A (en) A kind of message subscribing managing device and method
CN101605136B (en) A method and an apparatus for Internet protocol security IPSec processing to packets
CN102368843A (en) Garbage message processing method and system thereof
CN104956393A (en) Third-party communications to social networking system users using user descriptors
Rong‐na et al. Provenance‐based data flow control mechanism for Internet of things
CN105991407A (en) Message processing method, message processing device and processing server
CN106027419B (en) A kind of management method and device of data structure
CN111860655B (en) User processing method, device and equipment
CN102438233A (en) Detection method for mobile phone worms
CN113542250B (en) Block chain-based network threat analysis method, device and system
CN114239963A (en) Method and device for detecting directed graph circulation path
CN109213955A (en) Data processing method and relevant device
CN109391913A (en) A kind of method and system based on the slice management of NB-IoT Internet resources
CN113992453A (en) Blocking method and device for preventing data leakage and storage medium

Legal Events

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