class_docstr: Pickled EphemeralDB to support permanancy and concurrency
  
  This is a very simple and inefficient implementation of a permanent database on disk for Oríon.
  The data is loaded from disk for every operation, and every operation is protected with a
  filelock.
  
  Parameters
  ----------
  host: str
      File path to save pickled ephemeraldb.  Default is {user data dir}/orion/orion_db.pkl ex:
      $HOME/.local/share/orion/orion_db.pkl
  timeout: int
      Maximum number of seconds to wait for the lock before raising DatabaseTimeout.
      Default is 60.
class_docstr_tok: ["Pickled","EphemeralDB","to","support","permanancy","and","concurrency","This","is","a","very","simple","and","inefficient","implementation","of","a","permanent","database","on","disk","for","Or\u00edon",".","The","data","is","loaded","from","disk","for","every","operation",",","and","every","operation","is","protected","with","a","filelock",".","Parameters","--","--","--","--","--","host",":","str","File","path","to","save","pickled","ephemeraldb",".","Default","is","{","user","data","dir","}","\/orion\/orion_db.pkl","ex",":","$","HOME\/.local\/share\/orion\/orion_db.pkl","timeout",":","int","Maximum","number","of","seconds","to","wait","for","the","lock","before","raising","DatabaseTimeout",".","Default","is","60","."]
code: def __init__(self, host="", timeout=60, *args, **kwargs):
      if host == "":
          host = DEFAULT_HOST
      super().__init__(host)
  
      self.host = os.path.abspath(host)
  
      self.timeout = timeout
  
      if os.path.dirname(host):
          os.makedirs(os.path.dirname(host), exist_ok=True)
  
imports: import logging
  import os
  import pickle
  from contextlib import contextmanager
  from pickle import PicklingError
  import psutil
  from filelock import FileLock, SoftFileLock, Timeout
  import orion.core
  from orion.core.io.database import Database, DatabaseTimeout
  from orion.core.io.database.ephemeraldb import EphemeralDB
label_desc: Use image node_id 1 to create a new PickledDB object from inherited base classes: Database with example: obj = PickledDB(host, timeout)