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

Issue 83: Support for multi core using ServiceLocator #5

Closed
wants to merge 3 commits into
from

Conversation

Projects
None yet
2 participants
@paulbouwer

Hi Mauricio

I've implemented this feature to support a multi-tenancy requirement. I have added new tests and updated some existing tests. All pass. The following is an example of how to use it.

Startup.InitCore<TestDocument>("core1", "http://localhost");
Startup.InitCore<TestDocument>("core2", "http://localhost");
var solrOperations1 = ServiceLocator.Current.GetInstance<ISolrOperations<TestDocument>>("core1");
var solrOperations2 = ServiceLocator.Current.GetInstance<ISolrOperations<TestDocument>>("core2");

You can still use the existing Init method without cores:

Startup.Init<TestDocument>("http://localhost");
var solrOperations = ServiceLocator.Current.GetInstance<ISolrOperations<TestDocument>>();

Hope it helps.

Paul

@mausch

This comment has been minimized.

Show comment
Hide comment
@mausch

mausch Dec 9, 2010

Collaborator

Nice! But the commit shows up as a complete modification of all involved files, so it makes reviewing it nearly impossible. It seems to be an issue with autocrlf settings in git. Can you try setting core.autocrlf to true and re-committing? Thanks

Collaborator

mausch commented Dec 9, 2010

Nice! But the commit shows up as a complete modification of all involved files, so it makes reviewing it nearly impossible. It seems to be an issue with autocrlf settings in git. Can you try setting core.autocrlf to true and re-committing? Thanks

@paulbouwer

This comment has been minimized.

Show comment
Hide comment
@paulbouwer

paulbouwer Dec 9, 2010

I've only just started using Git and still getting up to speed on it - how would I go about doing this. I ran the following commands:

  • git config core.autocrlf true
  • git commit --amend -m "Issue 83: Support for multi core using ServiceLocator"
  • git push -f origin master

The commit still shows complete modification of all involved files.

I obtained a raw copy of your version of one of the files I committed and it seems to only have LF line endings (https://github.com/mausch/SolrNet/raw/master/SolrNet/Utils/Container.cs). My files have CRLF. Should I change my files to LF only and recommit ?

Thanks

I've only just started using Git and still getting up to speed on it - how would I go about doing this. I ran the following commands:

  • git config core.autocrlf true
  • git commit --amend -m "Issue 83: Support for multi core using ServiceLocator"
  • git push -f origin master

The commit still shows complete modification of all involved files.

I obtained a raw copy of your version of one of the files I committed and it seems to only have LF line endings (https://github.com/mausch/SolrNet/raw/master/SolrNet/Utils/Container.cs). My files have CRLF. Should I change my files to LF only and recommit ?

Thanks

@mausch

This comment has been minimized.

Show comment
Hide comment
@mausch

mausch Dec 12, 2010

Collaborator

Applied in 94505a6, thanks!

Collaborator

mausch commented Dec 12, 2010

Applied in 94505a6, thanks!

This issue was closed.

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