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

ioLib.getResource cannot get resource from another app #10419

Closed
rymsha opened this issue Feb 13, 2024 · 3 comments
Closed

ioLib.getResource cannot get resource from another app #10419

rymsha opened this issue Feb 13, 2024 · 3 comments
Assignees

Comments

@rymsha
Copy link
Contributor

rymsha commented Feb 13, 2024

ioLib.getResource is unusable in case developer needs resources from the app different from a "current application" app.
Java API can - this is why this issue was not noticed before.
This is quite inconvenient when applications need to share resources - one application uses resources of another.

@sigdestad
Copy link
Member

We should not promote / enable such approaches. Relying on assets in others apps is an antipattern.

@rymsha
Copy link
Contributor Author

rymsha commented Feb 14, 2024

Absolutely it is.
Ideally this should be solved differently - by injecting resources into an app.
In OSGi this is solved by Fragments. It would be App Extensions in XP terms. But we don't have such thing.

@enonic enonic deleted a comment from ComLock Feb 14, 2024
@rymsha
Copy link
Contributor Author

rymsha commented Feb 14, 2024

Conclusion is - application developers should not have (easy) access to resources from other apps. We won't fix this issue.

  • there is no guarantee in application startup order
  • there is no guarantee applications are compatible (requested resources might be missing)

@rymsha rymsha closed this as not planned Won't fix, can't repro, duplicate, stale Feb 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants