fsresource is using the contentparser-api as well (although in a slightly older 
version which was not split up in api+impl at that time).
in fact i started the contentparser implementation to have a common codebase 
for parsing JSON and XML-style content data in both fsresource and sling mocks.

fsresource is the thing you need if you want to "mount" JSON/xml data at run 
time in a sling instance, the contentparser helps you just parse 
sling/xml(vault) content from your code.

however, fsresource is currently not designed as "pluggable" to support 
additional (custom) xml formats.


>-----Original Message-----
>From: Bertrand Delacretaz <bdelacre...@apache.org>
>Sent: Tuesday, June 30, 2020 11:19 AM
>To: dev <dev@sling.apache.org>
>Subject: Re: Exposing generic XML as Sling resource
>Hi Julian,
>On Mon, Jun 29, 2020 at 6:37 PM Julian Reschke <resc...@apache.org> wrote:
>> ...I was pointed
>> to <https://github.com/apache/sling-org-apache-sling-fsresource>...
>I don't know these modules very well but I think
>https://github.com/apache/sling-org-apache-sling-contentparser-api is
>a more generic XML (or anything) to Sling Resource converter API,
>which that fsresource module (which is older) does not use.
>The existing XML converter [1] is a good example of implementing that
>content parser API.
>So maybe that model is more reusable than fsresource, but both are
>probably good for your use case.
>[1] https://github.com/apache/sling-org-apache-sling-contentparser-

Reply via email to