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

Re add Manufacturer and Supplier Pages #126

Closed

Conversation

sanctusmob
Copy link

Re add Manufacturer and Supplier Pages to Sitemap XML.
For some unknown reason they removed in "Fix all reported bugs #53"
Also increase the number of links and memory usage (my eshop have 40k products)

Re add Manufacturer and Supplier Pages to Sitemap XML.
For some unknown reason they removed in "Fix all reported bugs #53"
Also increase the number of links and memory usage (my eshop have 40k products)
gsitemap.php Outdated
@@ -260,7 +266,7 @@ public function emptySitemap($id_shop = 0)
*/
public function addLinkToSitemap(&$link_sitemap, $new_link, $lang, &$index, &$i, $id_obj)
{
if ($i <= 25000 && memory_get_usage() < 100000000) {
if ($i <= 49000 && memory_get_usage() < 1000000000) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you explain the reason to increase these values?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my eshop have 40k+ products, if $i is 25000 i get ~half of products.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure it's the right way to do it.
Maybe people doesn't have the amount of products you have, and the server quality you have 🤔
We maybe need to understand why the memory_get_usage has been added.
Also, I think if you have a lot of products, you should use cron task to do it :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have dedicated server for this eshop only. memory usage for that amount of product and two languages is more than 100mb(and fails to generate XML).

I have test with 200mb and its ok.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

keep original value

gsitemap.php Outdated Show resolved Hide resolved
Reduce memory check from 1G to 200Mb (100Mb failed to generate XML)
Fix spaces?
gsitemap.php Outdated
{
$link = new Link();
if (method_exists('ShopUrl', 'resetMainDomainCache')) {
ShopUrl::resetMainDomainCache();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please you use spaces everywhere, indentation is broken.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@colinegin
Copy link

Hello @sanctusmob , you received some feedbacks about your pull request, are you able to make the required changes ?

Thanks !

@sanctusmob sanctusmob closed this May 27, 2021
@sanctusmob sanctusmob reopened this May 27, 2021
@sanctusmob
Copy link
Author

Check again

@PierreRambaud PierreRambaud changed the base branch from master to dev December 28, 2021 13:21
@PierreRambaud
Copy link
Contributor

Check again

Seems people ignored this PR for a long time, and we are sorry about this :(
Are you able to rebase your PR based on the dev branch?
We fully understand if you don't want to do it.

@sanctusmob
Copy link
Author

I will

@sanctusmob sanctusmob closed this Dec 28, 2021
@Uhor Uhor mentioned this pull request Dec 30, 2023
@sanctusmob sanctusmob deleted the re-add-manufacturer-and-supplier branch March 6, 2024 08:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants