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

Potential for Multiple Application IDs? #294

Open
rgbjay opened this issue Apr 2, 2024 · 7 comments
Open

Potential for Multiple Application IDs? #294

rgbjay opened this issue Apr 2, 2024 · 7 comments

Comments

@rgbjay
Copy link

rgbjay commented Apr 2, 2024

We have a use case where we ideally need to be able to send data to two Applications within our Algolia account.

They are both part of a multisite but are managed by different teams and operationally it would be much cleaner to setup two applications rather than two indices inside one application.

Is there a) a way to do this already (I suspect the answer is no) or b) plans to add this functionality in, i.e. changing the application_id config setting (and associated API key fields) to accept an array rather than a string perhaps?

Any info would be helpful.

@janhenckens
Copy link
Member

@rgbjay Would the applications split per site? Application A for site A, application B for site B?

I think we could add support for multi-site style config where you can group settings per siteHandle - if that's how things are structured on your end.

@JamesNock
Copy link

@janhenckens I was about to ask the same question as the OP. I have a use-case where we could definitely use a different application id on a per-site basis. If we could get that functionality then it would be absolutely magical!

@janhenckens
Copy link
Member

janhenckens commented Apr 3, 2024

Yeah, that should be quite easy to do. Which version of Craft & Scout are you running at the moment @JamesNock? (just to be sure I merge it for the right version)

@JamesNock
Copy link

Amazing! CraftCMS 4.7.4 Pro with Scout 3.2.2 at present. Thank you @janhenckens

@janhenckens
Copy link
Member

Ok, will try to have a look over the weekend.

Might not be as easy as expected, since the function Craft uses to localise config (ConfigHelper::localizedValue()) relies an the currentSite (in web requests), but Scout usually needs these in the CP or in the Queue.

Will keep you posted on my progress!

@jamiewade
Copy link

Thanks @janhenckens! I too would be interested in this feature. Please keep us updated on the progress!

@rgbjay
Copy link
Author

rgbjay commented Jun 14, 2024

Apologies for going AWOL on this - still very much a feature we would like!

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

No branches or pull requests

4 participants