add storage and log functions