Skip to content
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

Stored Requests by account id for filesystem #1179

Closed
muuki88 opened this issue Mar 3, 2021 · 2 comments
Closed

Stored Requests by account id for filesystem #1179

muuki88 opened this issue Mar 3, 2021 · 2 comments

Comments

@muuki88
Copy link
Contributor

muuki88 commented Mar 3, 2021

In #488 stored request by account id where introduced, but as far as I understand this doesn't cover the filesystem stored requests implementation. Currently the configuration looks like this

settings:
  filesystem:
    stored-requests-dir: configs/stored-requests

A simple solution would be something like this

settings:
  filesystem:
    stored-requests-dir: configs/stored-requests
    appendAccountId: true

this wouldeffectively appending the accountId to the path. If a request has the accountId example.com
it would turn configs/stored-requests into configs/stored-requests/example.com.

FileApplicationSettings

private final Map<String, String> storedIdToRequest;
private final Map<String, String> storedIdToImp;
private final Map<String, String> storedIdToSeatBid;

Related

Relates to prebid/prebid-server#1024

@SerhiiNahornyi
Copy link
Collaborator

@muuki88 This feature with accountId was introduced, because it was a high chance of collision(mentioned in prebid/prebid-server#1024), but filesystem can not create this problem, because it can not be files with same name in same folder. We can add prefix to files with accountId, but could you please explain, is there a reason why we need this?

@muuki88
Copy link
Contributor Author

muuki88 commented Mar 10, 2021

@snahornyi you are right. This would just be for an "easier" to read structure in the filesystem.

Maybe if the ID contains slashes I can even workaround this 😂

@muuki88 muuki88 closed this as completed Mar 10, 2021
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

No branches or pull requests

2 participants