Dev:Seed
Aus YaCyWiki
A peer seed is the description of the anatomy of a peer. This is represented with a map of properties, which is called the DNA of a seed. The peer DNA contains the following nucleotides:
- "Name" - the name of the peer
- "Hash" - the peer hash, the unique identification and the DHT position of the peer. This is a 12-character ASCII which is generated from a Enhanced Base64 encoding of a 72-bit cardinal number.
- "IP" - the current IP of the peer, which may change frequently. The IP is assigned by the contacted peer, not by the contacting peer.
- "Port" - the port where YaCy is running. This is assigned by the contacting peer.
- "BDate" - Birthday = first startup time
- "Version" - a version string
- "UTC" - the UTC-Offset of the peer in context of the clock setting of the hosting computer (this does not show acually a hint of the longitude because every user can assign any UTC offset independently of the location)
- "LastSeen" - a timestamp given by any peer which had contact with the peer
- "PeerType" - the type of the peer, which can be "virgin", "junior", "mentee", "senior", "mentor", "principal";
- "ISpeed" - the speed of indexing (pages/minute) of the peer
- "RSpeed" - the speed of retrieval (queries/minute) of the peer
- "Uptime" - the number of minutes that the peer is up in minutes/day (moving average MA30)
- "LCount" - the number of links that the peer has stored (LURL's)
- "NCount" - the number of links that the peer has noticed, but not loaded (NURL's)
- "RCount" - the number of links that the peer provides for remote crawls (ZURL's)
- "ICount" - the number of different words the peer has indexed
- "SCount" - the number of seeds that the peer has stored
- "CCount" - the number of clients that the peer connects (connects/hour as double)
- "sI" - the number of send index/words
- "rI" - the number of received index/words
- "sU" - the number of send URLs
- "rU" - the number of received URLs
- "Flags" - a Bitfield-encoded set of binary flags, where the bits are assigns as follows: (DIRECT_CONNECT = 0, ACCEPT_REMOTE_CRAWL = 1, ACCEPT_REMOTE_INDEX = 2, ROOT_NODE = 3, SSL_AVAILABLE = 4). A DIRECT_CONNECT is set to all peers which the own peer had contact with directly. ACCEPT_REMOTE_CRAWL and ACCEPT_REMOTE_INDEX is set by the peer owner to show the corresponding grants. ROOT_NODE is set by contacting peer if the reporting IP of the peer is identical with the remote HTTP request IP and the connection speed is less that a given throughput. SSL_AVAILABLE is set by the owning peer if the same IP as given in the IP field (not 443!) accepts https request.
- "Tags" - peer tags. This is a '|'-separated list of words which is used for robinson peer selection. It can be set to '*' to show that the peer is willing to respond to every search request in the network.
- "seedURL" - if the peer runs in principal mode, then it publishes a seedlist publication address which is given here
- "news" - a 'news' attachment which is used to propagate broadcasts of different kinds to all peers.
- "dct" - the disconnect time, a time-stamp for an unsuccessful attempt to connect the peer.
These attributes are stored in a Map to represent the Peer. The most important parts are the peer hash, the IP and the port. The peer must set only the hash and the port; the IP is assigned by the first peer which is contacted.
There is no single interface to get the attributes of a peer seed in raw, but it is possible to retrieve a list of all seeds using the seedlist api.