class_docstr: Lock class for synchronizing processes for NFSv2 or later.
  
  On acquiring the lock, link system call is called to create an exclusive file. The file is
  deleted when the lock is released. In NFS environments prior to NFSv3, use this instead of
  :class:`~optuna.storages.JournalFileOpenLock`
  
  Args:
      filepath:
          The path of the file whose race condition must be protected.
class_docstr_tok: ["Lock","class","for","synchronizing","processes","for","NFSv2","or","later",".","On","acquiring","the","lock",",","link","system","call","is","called","to","create","an","exclusive","file",".","The","file","is","deleted","when","the","lock","is","released",".","In","NFS","environments","prior","to","NFSv3",",","use","this","instead","of",":","class",":","`","~optuna.storages.JournalFileOpenLock","`","Args",":","filepath",":","The","path","of","the","file","whose","race","condition","must","be","protected","."]
code: def __init__(self, filepath: str) -> None:
      self._lock_target_file = filepath
      self._lock_file = filepath + LOCK_FILE_SUFFIX
      self._lock_rename_file = (
          self._lock_file + str(uuid.uuid4()) + RENAME_FILE_SUFFIX
      )
  
imports: import abc
  from contextlib import contextmanager
  import errno
  import json
  import os
  import time
  from typing import Any
  from typing import Dict
  from typing import Iterator
  from typing import List
  from typing import Optional
  import uuid
  from optuna.storages._journal.base import BaseJournalLogStorage
label_desc: Use image node_id 1 to create a new JournalFileSymlinkLock object from inherited base classes: JournalFileBaseLock with example: obj = JournalFileSymlinkLock(filepath)