def add_item(self, item_url, item_metadata):
        """ Add the given item to the cache database, updating
        the existing metadata if the item is already present

        :type item_url: String or Item
        :param item_url: the URL of the item, or an Item object
        :type item_metadata: String
        :param item_metadata: the item's metadata, as a JSON string


        """
        c = self.conn.cursor()
        c.execute("DELETE FROM items WHERE url=?", (str(item_url),))
        self.conn.commit()
        c.execute("INSERT INTO items VALUES (?, ?, ?)",
                  (str(item_url), item_metadata, self.__now_iso_8601()))
        self.conn.commit()
        c.close()
Add the given item to the cache database, updating
        the existing metadata if the item is already present

        :type item_url: String or Item
        :param item_url: the URL of the item, or an Item object
        :type item_metadata: String
        :param item_metadata: the item's metadata, as a JSON string