Skip to content

Containers should not list .acl and .meta files #385

Closed

Description

@RubenVerborgh
No description provided.

Activity

  1. jvherweg commented on Dec 4, 2020

    @jvherweg
    Member

    .meta files should be hidden by the DataAccessors. If any of them still expose them that's a bug because they should already be doing that.

    Since a DataAccessor is acl unware, hiding the acl files should be covered elsewhere, potentially in a separate store such as mentioned in #381 and #53 .

  2. jvherweg commented on Dec 7, 2020

    @jvherweg
    Member

    This is also related to #384 (comment) : since the DataAccessorBasedStore is acl-unaware (and should be), we need to delete the acl containment triples before the result gets to the response writer. This would be easier if they are only in the metadata at that point where they can easily be removed. If they are also already in the data stream we would also have to check that one.

  3. RubenVerborgh commented on Jan 11, 2021

    @RubenVerborgh
    MemberAuthor

    Since a DataAccessor is acl unware, hiding the acl files should be covered elsewhere, potentially in a separate store

    We could just have an extension ban list.

    That said, while working on #494, I was a bit worried about ResourceUtil and generateContainmentQuads.
    I wonder if we don't want to leave this to the DataAccessorBasedStore, such that it can also take care of the filtering. Otherwise, we'd have to re-implement that in every class, it seems.

  4. jvherweg commented on Jan 13, 2021

    @jvherweg
    Member

    That said, while working on #494, I was a bit worried about ResourceUtil and generateContainmentQuads.
    I wonder if we don't want to leave this to the DataAccessorBasedStore, such that it can also take care of the filtering. Otherwise, we'd have to re-implement that in every class, it seems.

    If we do move generateContainmentQuads to the DataAccessorBasedStore the DataAccessors still would have to return a list of members so that would not change that much I think.

    We can have a banlist in the DataAccessorBasedStore while still handling the containment triples in the DataAccessors. It would just require filtering the metadata we get when requesting the metadata of a container.

  5. RubenVerborgh commented on Jan 13, 2021

    @RubenVerborgh
    MemberAuthor

    If we do move generateContainmentQuads to the DataAccessorBasedStore the DataAccessors still would have to return a list of members so that would not change that much I think.

    Yeah, but then DataAccessorBasedStore would be be responsible for filtering + creating containment triples.

    We can have a banlist in the DataAccessorBasedStore while still handling the containment triples in the DataAccessors. It would just require filtering the metadata we get when requesting the metadata of a container.

    I guess we could indeed also just filter the metadata triples. But perhaps we don't even need to generate the invalid ones.

  6. jvherweg commented on Jan 13, 2021

    @jvherweg
    Member

    Seeing as the containment triples are a triple per entry I don't see it as such an issue that they're being made in the DataAccessor. It also makes the interface easier since we're returning a metadata object anyway. Otherwise we would have the interface return 2 objects or have a separate function for returning members (the last would make everything a bit less efficient as another call would be needed for some backends).

  7. RubenVerborgh commented on Jan 13, 2021

    @RubenVerborgh
    MemberAuthor

    Got it, agreed.

  8. RubenVerborgh commented on Jan 14, 2021

    @RubenVerborgh
    MemberAuthor

    Also configurable perhaps to hide other kinds of files (like .DS_Store, .git) or any dotfile altogether (.*).

  9. RubenVerborgh commented on Mar 28, 2021

    @RubenVerborgh
    MemberAuthor

    Running v0.8.0, I still see .acl: https://css.verborgh.org/tmp/webdev/

    Do we need an integration test for this?

  10. jvherweg commented on Mar 28, 2021

    @jvherweg
    Member

    Note that you don't see ldp:contains <.acl>. though. So these triples have been removed. The other ones you see are a consequence of the extra metadata that gets added by the FileDataAccessor so the solution will have to be updated to take that into account.

  11. jvherweg commented on Apr 8, 2021

    @jvherweg
    Member

    Some possible solutions based on the discussion above and the current state:

    1. Have getMetadata return both metadata and a list of metadata objects for each child (undefined for document resources)
    2. Change the DataAccessor interface to have a function getChildren, which returns the list of 1.
    3. Provide an AuxiliaryStrategy to every DataAccessor to filter out children when calling getMetadata

    The main difference between 1. and 2. is that 1. might be more efficient since everything happens in a single call but the interface of 2. is cleaner. On the other hand, 3. would prevent metadata being generated that would be filtered out anyway.

    All this is under the assumption that we still want all the extra metadata that the FileDataAccessor provides.

    So far I mostly prefer 2 because it looks the cleanest, but it is the least efficient one of them all. If we make the result of 2. streaming though it would be a first step in resolving #332 (although it would also require RepresentationMetadata to be streaming).

  12. RubenVerborgh commented on Apr 20, 2021

    @RubenVerborgh
    MemberAuthor

    I'm fine with 2 here if cleanest indeed.

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

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions