List:Commits« Previous MessageNext Message »
From:Rafal Somla Date:November 6 2009 1:50pm
Subject:Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)
Bug#47994
View as plain text  
Hi

Ingo Strüwing wrote:
> 2) This is a valid way to inject an error into the code. It is the right
> way to test the error branch, if there is no better way to do that.
> However, on our last meeting, we agreed that we will always try hard to
> find a way to produce an error without error injection first.
> 
> In this case it means to find a way to let obs::check_user_access()
> return TRUE when called from Backup_info::add_db(). I can imagine that
> might not be possible since we have privilege elevation in backup.
> Please ask Chuck, if he knows of a way to let obs::check_user_access()
> fail in BACKUP. If yes, it would be preferable to do that and not
> pollute the code with error injection. If it is not possible, then error
> injection is ok to use in the way you did.
>

I think that currently the only situation where obs::check_user_access() 
reports error is when internally get_num_dbs() or get_num_objects() hits 
error which can happen only when there is error while executing SELECTS on 
I_S tables. I don't see an easy way to trigger errors in such selects.

Rafal
Thread
bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888) Bug#47994Thava Alagu6 Nov
  • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Ingo Strüwing6 Nov
    • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Rafal Somla6 Nov
    • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Thava Alagu8 Nov
      • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Ingo Strüwing9 Nov
  • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Rafal Somla6 Nov
    • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Thava Alagu8 Nov
      • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Rafal Somla9 Nov
        • Re: bzr commit into mysql-6.0-backup branch (thavamuni.alagu:2888)Bug#47994Ingo Strüwing9 Nov