Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork4.1k
RemoveStaticAssetsMetadata
#13094
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:main
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
val path = base + "/" + value.name | ||
StaticAssetsMetadata.finder.findAssetPath(base, path) | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
This removal could cause problems I guess...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
You are absolutely right. This is binder for Assets for generated routes are like
GET /public/*file controllers.Assets.versioned(path = "/public", file: controllers.Assets.Asset)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Updated the description of the pull request. I could make the PR green by switching everything to assetsfinder.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
If we will merge this, we also should remove the methodcontrollers.Assets.versioned(String, Asset)
and for that we will should mark it as@Deprecated
in2.9.x
and3.0.x
Uh oh!
There was an error while loading.Please reload this page.
3ba91a6
to24d539c
Compare24d539c
to7de4f1b
Compare7de4f1b
to138a51f
Compare138a51f
toda7ebb8
Compare
Uh oh!
There was an error while loading.Please reload this page.
Currently, we have two approaches for reverse routing public assets, both are describedhere:
This pull requests removes the first one by removing
StaticAssetsMetadata
. Reason for removal is to remove all static/"global" state.However I am not sure if we really should merge this pull request.
Reason is, the first approach is a bit easier for people how do not care about a static state in their applications, like when you are working on a single Play instance and not plan to run multiple Play apps within one jvm.
I think if we just keep both approaches documented it should be ok.
Not sure yet.