sunspot_solr 2.5.0 → 2.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a9c1914c2c766805f204440436b477639f441c59157f8ea8cf3d3ff2b3247c0e
4
- data.tar.gz: c7a5a0862b69755a76d39bbcaa6b739bdf519c94398c80097da009b8aa322a8c
3
+ metadata.gz: 0d6ce101ef6541d31f08f0228f8df88c19b24b896f4310bdce70eb07f0b9ac6c
4
+ data.tar.gz: 6c394cecc80e47f07419ec6eb724ad96c75d2efe4f05ec41f100a1fa0e7b91ce
5
5
  SHA512:
6
- metadata.gz: 324bd411649634ab9b317773c82069cfb91f40f1fe27ffe908122e975903a9243bb214daf5e9814c873cadcc0ed638297e54dbe05593000c2631d20ae326f7c1
7
- data.tar.gz: d54998daedd15e13503a8854bdd64fc39136e81481187256682752139bc9bd92fa053bfc3498bd82e440083f81b7f614a2a407f8324be78158f72c5c27f4c75c
6
+ metadata.gz: 8580de15e12597bea8417ce5eaa82c0c441cd9559fdf95b6244b7e3d2de3739919740f18a25173345f4518edf4c5d8bdbe6462ed5acbacf8d0356d7627074b70
7
+ data.tar.gz: f708ea58898e16712a189d159f248414e813d39c84dcbda935ad465e9d254c041c29abc003b8172b2e1a291a0cfb3b2d66eef5f52b64ca4d3ae53e6214ff855a
@@ -95,6 +95,7 @@ module Sunspot
95
95
  command << "-p" << "#{port}" if port
96
96
  command << "-h" << "#{bind_address}" if bind_address
97
97
  command << "-s" << "#{solr_home}" if solr_home
98
+ command << "-Dlog4j.configuration=file:#{logging_config.path}" if logging_config
98
99
 
99
100
  exec_in_solr_executable_directory(command)
100
101
  end
@@ -170,7 +171,7 @@ module Sunspot
170
171
  # Boolean:: success
171
172
  #
172
173
  def install_solr_home
173
- unless File.exists?(solr_home)
174
+ unless File.exist?(solr_home)
174
175
  Sunspot::Solr::Installer.execute(
175
176
  solr_home,
176
177
  :force => true,
@@ -188,24 +189,32 @@ module Sunspot
188
189
  #
189
190
  def create_solr_directories
190
191
  [pid_dir].each do |path|
191
- FileUtils.mkdir_p(path) unless File.exists?(path)
192
+ FileUtils.mkdir_p(path) unless File.exist?(path)
192
193
  end
193
194
  end
194
195
 
195
196
  private
196
197
 
197
- def logging_config_path
198
- return @logging_config_path if defined?(@logging_config_path)
199
- @logging_config_path =
198
+ def logging_config
199
+ return @logging_config if defined?(@logging_config)
200
+ @logging_config =
200
201
  if log_file
201
- logging_config = Tempfile.new('logging.properties')
202
- logging_config.puts("handlers = java.util.logging.FileHandler")
203
- logging_config.puts("java.util.logging.FileHandler.level = #{log_level.to_s.upcase}")
204
- logging_config.puts("java.util.logging.FileHandler.pattern = #{log_file}")
205
- logging_config.puts("java.util.logging.FileHandler.formatter = java.util.logging.SimpleFormatter")
202
+ logging_config = Tempfile.new('log4j.properties')
203
+ logging_config.puts("log4j.rootLogger=#{log_level.to_s.upcase}, file, CONSOLE")
204
+ logging_config.puts("log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender")
205
+ logging_config.puts("log4j.appender.CONSOLE.layout=org.apache.log4j.EnhancedPatternLayout")
206
+ logging_config.puts("log4j.appender.CONSOLE.layout.ConversionPattern=%-4r %-5p (%t) [%X{collection} %X{shard} %X{replica} %X{core}] %c{1.} %m%n")
207
+ logging_config.puts("log4j.appender.file=org.apache.log4j.RollingFileAppender")
208
+ logging_config.puts("log4j.appender.file.MaxFileSize=4MB")
209
+ logging_config.puts("log4j.appender.file.MaxBackupIndex=9")
210
+ logging_config.puts("log4j.appender.file.File=#{log_file}")
211
+ logging_config.puts("log4j.appender.file.layout=org.apache.log4j.EnhancedPatternLayout")
212
+ logging_config.puts("log4j.appender.file.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss.SSS} %-5p (%t) [%X{collection} %X{shard} %X{replica} %X{core}] %c{1.} %m%n")
213
+ logging_config.puts("log4j.logger.org.apache.solr.update.LoggingInfoStream=OFF")
214
+
206
215
  logging_config.flush
207
216
  logging_config.close
208
- logging_config.path
217
+ logging_config
209
218
  end
210
219
  end
211
220
  end
data/sunspot_solr.gemspec CHANGED
@@ -22,13 +22,11 @@ Gem::Specification.new do |s|
22
22
  distribution is well suited to development and testing.
23
23
  TEXT
24
24
 
25
- s.rubyforge_project = "sunspot"
26
-
27
25
  s.files = `git ls-files`.split("\n")
28
26
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
29
27
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
30
28
  s.require_paths = ["lib"]
31
29
 
32
- s.add_development_dependency 'rake', '< 12.3'
30
+ s.add_development_dependency 'rake', '~> 13.2'
33
31
  s.add_development_dependency 'rspec', '~> 3.7'
34
32
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sunspot_solr
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.0
4
+ version: 2.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mat Brown
@@ -23,25 +23,25 @@ authors:
23
23
  - Sam Granieri
24
24
  - Nick Zadrozny
25
25
  - Jason Ronallo
26
- autorequire:
26
+ autorequire:
27
27
  bindir: bin
28
28
  cert_chain: []
29
- date: 2019-07-12 00:00:00.000000000 Z
29
+ date: 2024-06-07 00:00:00.000000000 Z
30
30
  dependencies:
31
31
  - !ruby/object:Gem::Dependency
32
32
  name: rake
33
33
  requirement: !ruby/object:Gem::Requirement
34
34
  requirements:
35
- - - "<"
35
+ - - "~>"
36
36
  - !ruby/object:Gem::Version
37
- version: '12.3'
37
+ version: '13.2'
38
38
  type: :development
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
41
41
  requirements:
42
- - - "<"
42
+ - - "~>"
43
43
  - !ruby/object:Gem::Version
44
- version: '12.3'
44
+ version: '13.2'
45
45
  - !ruby/object:Gem::Dependency
46
46
  name: rspec
47
47
  requirement: !ruby/object:Gem::Requirement
@@ -565,7 +565,7 @@ homepage: https://github.com/sunspot/sunspot/tree/master/sunspot_solr
565
565
  licenses:
566
566
  - MIT
567
567
  metadata: {}
568
- post_install_message:
568
+ post_install_message:
569
569
  rdoc_options: []
570
570
  require_paths:
571
571
  - lib
@@ -580,8 +580,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
580
580
  - !ruby/object:Gem::Version
581
581
  version: '0'
582
582
  requirements: []
583
- rubygems_version: 3.0.2
584
- signing_key:
583
+ rubygems_version: 3.4.19
584
+ signing_key:
585
585
  specification_version: 4
586
586
  summary: Bundled Solr distribution for Sunspot
587
587
  test_files: