Giter Site home page Giter Site logo

Comments (6)

aegoose avatar aegoose commented on August 24, 2024

I have the same issue.
the code in sunspot_solr/lib/sunspot/solr/java.rb only for linux. I change it as below, then it work well.

module Sunspot
  module Solr
    module Java
      def self.installed?
        # `java -version &> /dev/null`
        # $?.success?
        !ENV["JAVA_HOME"].blank?
      end
    end
  end
end

But I think it is a temporarily solution.

from sunspot.

Justinwceo avatar Justinwceo commented on August 24, 2024

Tried the same thing but no luck for me. What version of sunspot_solr are you using?

from sunspot.

aegoose avatar aegoose commented on August 24, 2024

hi, @Justinwceo,
I used the same version of "sunspot_solr", version "2.0.0.pre.111215".
I have test in Windows 7 32bit and 64bit, all work ok.
I was run with my rails project, my Gemfile is (for all environments):

  gem 'sunspot_rails", "~> 2.0.0.pre.111215"
  gem "sunspot_solr", "~> 2.0.0.pre.111215"

I think if you can try without "JAVA_HOME", modify the file as below:

module Sunspot
  module Solr
    module Java
      def self.installed?
        true
      end
    end
  end
end

Also, it is a temporarily solution.

from sunspot.

alindeman avatar alindeman commented on August 24, 2024

I've made some comments in #150. Hopefully we can get this resolved, but I have no way to test on Windows. If you can test the code suggestions there, I'd appreciate it.

from sunspot.

Justinwceo avatar Justinwceo commented on August 24, 2024

Ok, going by what you said in Issue #150. I was able to use this code and get it to run:

module Sunspot
  module Solr
    module Java
      def self.installed?
        `java -version`
        $?.success?
      end
    end
  end
end

from sunspot.

alindeman avatar alindeman commented on August 24, 2024

Thanks all. Should be fixed, including in 1-3-stable. I think this--along with a possible bug in Sunspot + Rails 2.3.x--may lead to a 1.3.1 release.

from sunspot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.