question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Distinct fail when changing slaves index

See original GitHub issue

Hi,

I have an issue when i use a sortBySelector widget… When i change the indice, the distinct parameter don’t work anymore and i have more hits then i expect to.

I have this configuration : const search = instantsearch({ appId: client.applicationID, apiKey: client.apiKey, indexName: index.indexName, searchParameters: { hitsPerPage: 15, distinct: 1, facetingAfterDistinct: true, }, routing: true });

search.addWidget( instantsearch.widgets.sortBySelector({ container: '#sort-product', indices: [ {name: index.indexName, label: 'Last modified'}, {name: index.indexName+'price_with_vat', label: 'Lower to Higher Price)'}, {name: index.indexName+'-price_with_vat', label: 'Higher to Lower Price)'} ] }) );

You could test the issue on that site (french only) : https://www.maxxess.fr/categorie/huiles-2t-226

Is there something in the configuration that i miss ?

Thanks

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
samousscommented, Nov 19, 2018

If I understand correctly the issue was: the settings were not applied on the replicas right? Yes it’s the expected behaviour. You have to provide an options to apply the setSettings call to the replicas, it’s forwardToReplicas .

0reactions
fvoverscancommented, Nov 19, 2018

Yes i apply the settings on all slaves index too so the problem is resolved. But i would like to know if this behavior is normal ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can you index tables differently on Master and Slave (MySQL)
I believe so. After replication is working, you can drop the indexes on the slave and create the indexes you want and that...
Read more >
Replication When the Primary and Replica Have Different ...
Slave and the primary table definitions can differ while replicating. ... but is too long for the replica field, and so replication will...
Read more >
pt-online-schema-change — Percona Toolkit Documentation
In most cases the tool will refuse to operate unless a PRIMARY KEY or UNIQUE INDEX is present in the table. See --alter...
Read more >
MySQL Master-Slave Replication on the Same Machine - Toptal
The approach presented in this tutorial uses the same MySQL binaries as the first, with separate data files necessary for the second installation....
Read more >
Global Findings | Global Slavery Index
An analysis of the national estimates in this Global Slavery Index confirms ... Forced labour was found to occur in different sectors, to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found