From GridPP Wiki
Jump to: navigation, search

Pinning - Overview

Pinning a file means that a file is available in "fast" storage, such as disk -- as opposed to on "slow" storage such as tape.
Implicit pins
Some actions create implicit pins. When a file is made available for reading, an implicit pin is often created. This means that if another client tries to read the same file, the file can be made available quickly (for example, the two clients may read the same copy, if they only need read-only access).
Explicit pins
An explicit pin is one created with the SRM's pin function (part of the SRM API). A client calls the SRM saying "pin this file for the next 12 hours". The client is then expected to unpin the file when the client no longer needs the pin.
A pin has a lifetime associated with it. Some clients may fail and never call unpin. In that case, the pin is removed when it times out. When the client asks for an explicit pin, the client can specify the desired lifetime, but the SRM may give the client a pin with a shorter lifetime. The actual lifetime is returned to the client.
Renewing a pin
If the client already has a pin on a file, it can ask to have it renewed, usually before the current pin expires. This is just done by calling the pin function again.