@Override
    public PathAttributes find(final Path file, final ListProgressListener listener) throws BackgroundException {
        if(file.isRoot()) {
            // {"code":400,"message":"Bad Request","debugInfo":"Node ID must be positive.","errorCode":-80001}
            final PathAttributes attributes = new PathAttributes();
            if(session.userAccount().isUserInRole(SDSPermissionsFeature.ROOM_MANAGER_ROLE)) {
                // We need to map user roles to ACLs in order to decide if creating a top-level room is allowed
                final Acl acl = new Acl();
                acl.addAll(new Acl.CanonicalUser(), SDSPermissionsFeature.CREATE_ROLE);
                attributes.setAcl(acl);
            }
            return attributes;
        }
        // Throw failure if looking up file fails
        final String id = nodeid.getVersionId(file);
        try {
            return this.findNode(file, id);
        }
        catch(NotfoundException e) {
            if(log.isWarnEnabled()) {
                log.warn(String.format("Previously cached node id %s no longer found for file %s", id, file));
            }
            // Try with reset cache after failure finding node id
            return this.findNode(file, nodeid.getVersionId(file));
        }
    }
@Test(expected = NotfoundException.class)
    public void testFindNotFound() throws Exception {
        final SDSNodeIdProvider nodeid = new SDSNodeIdProvider(session);
        final Path room = new SDSDirectoryFeature(session, nodeid).mkdir(
            new Path(new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.directory, Path.Type.volume)), new TransferStatus());
        final Path test = new Path(room, new AlphanumericRandomStringService().random(), EnumSet.of(Path.Type.file));
        final SDSAttributesFinderFeature f = new SDSAttributesFinderFeature(session, nodeid);
        try {
            f.find(test);
        }
        finally {
            new SDSDeleteFeature(session, nodeid).delete(Collections.singletonList(room), new DisabledLoginCallback(), new Delete.DisabledCallback());
        }
    }