Test 8 results for admin user

5 posts / 0 new
Last post
Test 8 results for admin user

The following is feedback from Derek on Test 8:

xdusage -u, -up only shows projects that the current user is also a member of.

This is expected if the user is a regular user but shouldn't it return all results if the user is an admin user?

Delivery Effort Stage: 

xdusage has different roles that can be confusing.

In the configuration file there is an "admin_name" field. If you run xdusage and you are specified in this field, you are allowed to run xdusage with USER set to something other than yourself and run as that user and see their results. This is the only difference from running without the setting.

The database contains an "is_su" field. If this is set for you, then you can see results for projects that you are not a member of.

Additionally (confusingly) if you run the script as a superuser (as root) you will see more information when errors are encountered.

The "admin_name" and "is_su" behavior is unchanged from the previous version of the code. I added the behavior for running as root.

Hi Peter,

I believe that Derek's username was listed in the admin_name field when he executed.  Derek, can you confirm?


Right - my username was listed in the config file among admin_user entries.

Having your name listed in the config file as "admin_user" allows you to set the USER environment variable to so other user's name and get data for that one user.

In the central accounting database there is a separate data field "is_su" which, if true, lets you see data for all users.

Should I change the "admin_user" to behave the same way as "is_su"? I would need to test and make sure the API will return data for more than one person if the "is_su" field in the database isn't set.

Log in to post comments