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

Public URL not correct while solr indexing #136

Open
thomashempel opened this issue Feb 20, 2020 · 3 comments
Open

Public URL not correct while solr indexing #136

thomashempel opened this issue Feb 20, 2020 · 3 comments

Comments

@thomashempel
Copy link

I try to make the extension work with solrfal. I adopted my file index queue arcoding to the documentation but all url's in the index are something like "http:///index.php..." is there anything else I have to configure in order to make this work?

Sorry, if this is the wrong place to ask, but I don't know what would be the appropriate place.

@thomashempel
Copy link
Author

thomashempel commented Feb 21, 2020

I did a little more digging and found that the public URL is correctly set when you set the $referencePath in the PublicUrlAspect to ABSOLUTE_PATH or just not set it as that is the default.

So from

Line 103 in fal_securedownload/Classes/Aspects/PublicUrlAspect.php

$urlData['publicUrl'] = (string) $uriBuilder->buildUriFromRoute(
    'ajax_dump_file',
    $queryParameterArray,
    UriBuilder::ABSOLUTE_URL
);
$urlData['publicUrl'] = (string) $uriBuilder->buildUriFromRoute(
    'ajax_dump_file',
    $queryParameterArray,
    UriBuilder::ABSOLUTE_PATH
);

or

$urlData['publicUrl'] = (string) $uriBuilder->buildUriFromRoute(
    'ajax_dump_file',
    $queryParameterArray
);

I'm not providing patch since it's a rather simple change and I have no clue, if this has any implications anywhere else. Looks fine to me, though.

@thomashempel thomashempel changed the title Question: Solr integration not working Public URL not correct while solr indexing Feb 21, 2020
@thomashempel
Copy link
Author

Okay, it seems like that is not the absolute solution to this problem. This fix works for my local ddev environment, but not on the real server. :-/

@baschny
Copy link

baschny commented Apr 28, 2021

This seems to be buggy indeed, the problem starts as soon as you index files via the CLI context (indexing via backend modules generate a correct URL)...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants