Skip to content

Conversation

@dlin2028
Copy link

@dlin2028 dlin2028 commented May 3, 2024

Description

Currently, our system only allows for the invalidation of the entire user authentication cache, which can lead to numerous cache misses and inefficiencies. This change is required to allow for more precise cache management, specifically targeting stale cache entries at the individual user level without disrupting the cache state of other users

  • Category: New feature
  • Why these changes are required?
    Currently, our system only allows for the invalidation of the entire user authentication cache. This change is required to allow for more precise cache management, specifically targeting stale cache entries at the individual user level without disrupting the cache state of other users.
  • What is the old behavior before changes and new behavior after changes?
    Previously, invalidating a user's cache required clearing the entire cache, affecting all users. The new behavior introduces an endpoint that allows for the invalidation of cache entries on a per-user basis, thereby maintaining cache integrity for other users and reducing unnecessary cache misses.

Issues Resolved

#2829

Testing

Unit testing was written in FlushCacheApiTest.java

Check List

  • [X ] New functionality includes testing
  • New functionality has been documented
  • [ X] Commits are signed per the DCO using --signoff

Signed-off-by: David Lin <dlin2028@gmail.com>
cwperks added 3 commits May 5, 2024 14:20
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
@dlin2028 dlin2028 force-pushed the flush-user-cache branch from 2c8e63a to cc6c4ac Compare May 5, 2024 19:25

import static org.opensearch.security.OpenSearchSecurityPlugin.PLUGINS_PREFIX;

public class FlushCacheApiTest extends AbstractRestApiUnitTest {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move the test into integration-tests

@DarshitChanpura
Copy link
Member

@dlin2028 Is this being worked on actively?

@dlin2028
Copy link
Author

@DarshitChanpura No. I think someone else took this one.
#4571

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants