-
Notifications
You must be signed in to change notification settings - Fork 326
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No way to delete api users or web backends from the web ui #134
Comments
This seems to be a two part question. What do you mean by 'web backends' in your issue title? Do you mean 'API Backends', as the admin menu indicates (Configuration > API Backends)? If so, you may delete an API Backend by clicking the 'Delete API' link below the 'Save' button. |
Thanks for responding. This was actually more of a feature requests/bug report than a question. I decided to group two missing delete links into one issue. In addition to API Backends, version 0.8.0 added Web Backends (api.data.gov#146). There are available from the same menu as the latter. However, unlike API Backends, they don't have a corresponding Delete link. I suspect this was an omission. The other part was the inability to delete users. This may possibly be by design to preserve the integrity of the analytics. However, it's kind of annoying to not be able to delete a user before they have made any significant contribution to the analytics (i.e. if they were created in error in the first place). |
Oops, the inability to delete Website Backends was definitely an oversight. That should be fixed in master with NREL/api-umbrella-web#13 The inability to delete users was indeed by design for analytics purposes (as you had guessed). That being said, if you feel like deleting users would be useful, that shouldn't be too difficult to implement. Although, it might be worth noting that we don't actually delete any records in the admin currently. Instead, we perform soft deletes everywhere else in the admin, so when you "delete" an API Backend or Website Backend, the data is still there, it just sets a If we took a similar approach for API users, then a "deleted" API user would be extremely similar to the concept of a disabled user which we already implement, with the difference simply being whether or not we show the API user in the admin. Of course, we could actually delete records, but I personally tend to be delete-averse in production systems, but that might just be me. If we were to take the soft delete approach for users, would this distinction between deleted and disabled accounts still be valuable to you? I can see how a delete (even if it's a soft delete) might be useful if you're wanting to tidy up some test accounts. But let me know if you have any thoughts or preferences. |
ProblemWell, I see several scenarios for wanting to "delete" a user:
It was the first scenario that spawned this issue in the first place. As we gear up to go-live with our external demo/evaluation environment, I'm accumulating a lot of test accounts. Given that you can change the email in the admin interface, the second scenario likely wouldn't actually require deleting anything. And then we come to scenario three, where we could accumulate a lot of inactive users to deal with in the admin interface. AlternativesI'd agree with your stance on deleting production data. However, I'd say soft deleting api users is a bad idea. I can see this resulting in confusion for others adopting API Umbrella. How do you reactivate/recreate a user who once existed and you now want back? I'm sure we could come up with solutions to all these problems, but likely not worth the complexity. In the case of test accounts, I'm fine with deleting them in Mongo when the need arises. The need is more frequent now but will decrease once we reach production. ProposalSo, now we come to what I think is the bedrock of the issue. I have a long list of current and former users, which makes it more difficult to manage the current users -- the ones that are currently relevant. So, why not support filtering users by their state (defaulting to active only) and provide some visual indication in the table if the user is active or not. This allows us to maintain referential integrity, while managing information overload. (I will open a separate issue for the case of Admin Users) |
I'm going to go ahead and close this issue. The ability to delete other resources was addressed, although we still only allow api keys to be disabled for analytics purposes. But please feel free to speak up if anyone still feels the need to delete api keys from the database directly in the web admin, and we can revisit this. |
@darylrobbins @brylie We can delete the users from mongodb database by giving the folowing query: |
As far as I can tell, there is currently no way to remove an API user (you can disable them though) or a web backend.
The text was updated successfully, but these errors were encountered: