WordPress.org

Ready to get started?Download WordPress

Forums

HyperDB
Settings / widgets lost when connection error occurs (1 post)

  1. Arkadiusz Rzadkowolski
    Member
    Posted 1 year ago #

    I would like to inform you that setting db_connection_error should be mandatory, as it may cause lots of problems for many people.

    We have noticed on our huge multisite network that if we don't set this callback (to kill wp) and some "get_option" queries appear (while no database is available), plugin/widget settings might get "deleted".

    It happens like that because most plugins have this workflow:

    if(!get_option("xxx"))
    update_option("xxx", "default");

    Since no database is available get_option returns null and it's value might get updated if database becomes responsive by the time plugin wants to set default settings.

    http://wordpress.org/extend/plugins/hyperdb/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

  • RSS feed for this topic
  • Started 1 year ago by Arkadiusz Rzadkowolski
  • This topic is not resolved
  • WordPress version: 3.4.2

Tags

No tags yet.