active-fedora 10.1.0 → 11.1.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 +4 -4
- data/.gitignore +1 -0
- data/.rubocop.yml +6 -7
- data/.rubocop_todo.yml +55 -0
- data/.solr_wrapper +6 -0
- data/.travis.yml +6 -9
- data/Gemfile +1 -0
- data/History.txt +34 -0
- data/README.md +1 -3
- data/active-fedora.gemspec +7 -13
- data/lib/active_fedora/aggregation/list_source.rb +2 -0
- data/lib/active_fedora/associations/association_scope.rb +1 -1
- data/lib/active_fedora/associations/builder/aggregation.rb +1 -1
- data/lib/active_fedora/associations/builder/association.rb +1 -1
- data/lib/active_fedora/associations/builder/orders.rb +11 -3
- data/lib/active_fedora/associations/collection_association.rb +5 -5
- data/lib/active_fedora/associations/collection_proxy.rb +10 -10
- data/lib/active_fedora/associations/contained_finder.rb +2 -2
- data/lib/active_fedora/associations/has_and_belongs_to_many_association.rb +1 -1
- data/lib/active_fedora/associations/has_many_association.rb +2 -2
- data/lib/active_fedora/associations/has_subresource_association.rb +2 -2
- data/lib/active_fedora/associations/orders_association.rb +4 -0
- data/lib/active_fedora/associations/rdf.rb +2 -0
- data/lib/active_fedora/attribute_assignment.rb +0 -1
- data/lib/active_fedora/attribute_methods/dirty.rb +1 -1
- data/lib/active_fedora/attribute_methods.rb +1 -1
- data/lib/active_fedora/attributes.rb +1 -1
- data/lib/active_fedora/base.rb +4 -8
- data/lib/active_fedora/change_set.rb +6 -2
- data/lib/active_fedora/cleaner.rb +1 -1
- data/lib/active_fedora/containers/container.rb +1 -1
- data/lib/active_fedora/core.rb +33 -30
- data/lib/active_fedora/fedora.rb +6 -2
- data/lib/active_fedora/fedora_attributes.rb +1 -1
- data/lib/active_fedora/file/streaming.rb +1 -1
- data/lib/active_fedora/file.rb +2 -1
- data/lib/active_fedora/file_configurator.rb +3 -3
- data/lib/active_fedora/indexing.rb +1 -18
- data/lib/active_fedora/indexing_service.rb +0 -9
- data/lib/active_fedora/initializing_connection.rb +1 -1
- data/lib/active_fedora/loadable_from_json.rb +12 -1
- data/lib/active_fedora/model_classifier.rb +1 -1
- data/lib/active_fedora/nested_attributes.rb +2 -2
- data/lib/active_fedora/null_logger.rb +10 -0
- data/lib/active_fedora/orders/list_node.rb +2 -2
- data/lib/active_fedora/orders/ordered_list.rb +8 -4
- data/lib/active_fedora/orders/target_proxy.rb +4 -0
- data/lib/active_fedora/querying.rb +1 -1
- data/lib/active_fedora/railtie.rb +2 -2
- data/lib/active_fedora/rake_support.rb +1 -1
- data/lib/active_fedora/rdf/field_map_entry.rb +6 -0
- data/lib/active_fedora/rdf/persistence.rb +1 -0
- data/lib/active_fedora/rdf/value_caster.rb +15 -0
- data/lib/active_fedora/rdf.rb +1 -1
- data/lib/active_fedora/relation/delegation.rb +4 -0
- data/lib/active_fedora/relation/finder_methods.rb +3 -1
- data/lib/active_fedora/solr_hit.rb +1 -14
- data/lib/active_fedora/solr_query_builder.rb +17 -13
- data/lib/active_fedora/version.rb +1 -1
- data/lib/active_fedora/with_metadata/metadata_node.rb +2 -1
- data/lib/active_fedora.rb +1 -12
- data/lib/generators/active_fedora/config/solr/templates/solr/config/solrconfig.xml +11 -0
- data/lib/generators/active_fedora/config/solr/templates/solr_wrapper_test.yml +1 -1
- data/lib/generators/active_fedora/model/model_generator.rb +1 -1
- data/lib/generators/active_fedora/model/templates/model.rb.erb +4 -4
- data/lib/tasks/active_fedora_dev.rake +1 -1
- data/spec/config_helper.rb +1 -1
- data/spec/integration/associations_spec.rb +23 -24
- data/spec/integration/attached_files_spec.rb +19 -9
- data/spec/integration/attributes_spec.rb +12 -16
- data/spec/integration/autosave_association_spec.rb +6 -6
- data/spec/integration/base_spec.rb +8 -8
- data/spec/integration/basic_contains_association_spec.rb +1 -1
- data/spec/integration/clean_connection_spec.rb +1 -1
- data/spec/integration/collection_association_spec.rb +2 -5
- data/spec/integration/date_time_properties_spec.rb +1 -17
- data/spec/integration/direct_container_spec.rb +12 -12
- data/spec/integration/directly_contains_one_association_spec.rb +11 -13
- data/spec/integration/eradicate_spec.rb +1 -1
- data/spec/integration/fedora_solr_sync_spec.rb +2 -2
- data/spec/integration/file_fixity_spec.rb +6 -8
- data/spec/integration/file_spec.rb +37 -39
- data/spec/integration/generators/solr_generator_spec.rb +7 -10
- data/spec/integration/has_and_belongs_to_many_associations_spec.rb +7 -7
- data/spec/integration/has_many_associations_spec.rb +9 -11
- data/spec/integration/indexing_spec.rb +2 -2
- data/spec/integration/indirect_container_spec.rb +11 -12
- data/spec/integration/json_serialization_spec.rb +4 -4
- data/spec/integration/query_result_builder_spec.rb +9 -21
- data/spec/integration/rdf_nested_attributes_spec.rb +7 -7
- data/spec/integration/relation_delegation_spec.rb +8 -10
- data/spec/integration/relation_spec.rb +13 -16
- data/spec/integration/scoped_query_spec.rb +3 -3
- data/spec/integration/scoping_spec.rb +3 -3
- data/spec/integration/solr_hit_spec.rb +4 -15
- data/spec/integration/versionable_spec.rb +73 -327
- data/spec/integration/with_metadata_spec.rb +1 -1
- data/spec/spec_helper.rb +52 -10
- data/spec/unit/active_fedora_spec.rb +1 -1
- data/spec/unit/aggregation/list_source_spec.rb +37 -37
- data/spec/unit/aggregation/ordered_reader_spec.rb +4 -4
- data/spec/unit/association_hash_spec.rb +17 -31
- data/spec/unit/attached_files_spec.rb +35 -32
- data/spec/unit/attributes_spec.rb +25 -25
- data/spec/unit/base_active_model_spec.rb +8 -8
- data/spec/unit/base_cma_spec.rb +1 -1
- data/spec/unit/base_extra_spec.rb +7 -22
- data/spec/unit/base_spec.rb +21 -27
- data/spec/unit/builder/has_and_belongs_to_many_spec.rb +1 -1
- data/spec/unit/callback_spec.rb +2 -2
- data/spec/unit/change_set_spec.rb +5 -5
- data/spec/unit/checksum_spec.rb +2 -2
- data/spec/unit/code_configurator_spec.rb +1 -1
- data/spec/unit/core/fedora_id_translator_spec.rb +2 -2
- data/spec/unit/core/fedora_uri_translator_spec.rb +2 -2
- data/spec/unit/core/logger_spec.rb +18 -0
- data/spec/unit/core_spec.rb +68 -32
- data/spec/unit/default_model_mapper_spec.rb +6 -6
- data/spec/unit/fedora_spec.rb +3 -4
- data/spec/unit/file_configurator_spec.rb +96 -96
- data/spec/unit/file_path_builder_spec.rb +3 -3
- data/spec/unit/file_spec.rb +93 -61
- data/spec/unit/files_hash_spec.rb +9 -9
- data/spec/unit/filter_spec.rb +3 -3
- data/spec/unit/finder_methods_spec.rb +3 -3
- data/spec/unit/forbidden_attributes_protection_spec.rb +2 -2
- data/spec/unit/has_and_belongs_to_many_association_spec.rb +14 -15
- data/spec/unit/has_many_association_spec.rb +28 -13
- data/spec/unit/indexers/global_indexer_spec.rb +6 -6
- data/spec/unit/indexing_service_spec.rb +5 -5
- data/spec/unit/indexing_spec.rb +8 -8
- data/spec/unit/inheritance_spec.rb +11 -7
- data/spec/unit/loadable_from_json_spec.rb +4 -4
- data/spec/unit/logger_spec.rb +1 -1
- data/spec/unit/model_classifier_spec.rb +5 -5
- data/spec/unit/ordered_spec.rb +144 -147
- data/spec/unit/orders/list_node_spec.rb +22 -22
- data/spec/unit/orders/ordered_list_spec.rb +96 -96
- data/spec/unit/orders/reflection_spec.rb +4 -4
- data/spec/unit/pathing_spec.rb +4 -4
- data/spec/unit/persistence_spec.rb +28 -28
- data/spec/unit/property_spec.rb +2 -2
- data/spec/unit/query_spec.rb +12 -12
- data/spec/unit/rdf/indexing_service_spec.rb +29 -29
- data/spec/unit/readonly_spec.rb +5 -4
- data/spec/unit/reflection_spec.rb +3 -3
- data/spec/unit/rspec_matchers/belong_to_associated_active_fedora_object_matcher_spec.rb +9 -9
- data/spec/unit/rspec_matchers/have_many_associated_active_fedora_objects_matcher_spec.rb +9 -9
- data/spec/unit/rspec_matchers/have_predicate_matcher_spec.rb +9 -9
- data/spec/unit/schema_indexing_strategy_spec.rb +5 -5
- data/spec/unit/serializers_spec.rb +3 -4
- data/spec/unit/solr_config_options_spec.rb +13 -16
- data/spec/unit/solr_hit_spec.rb +9 -9
- data/spec/unit/solr_service_spec.rb +4 -10
- data/spec/unit/sparql_insert_spec.rb +2 -2
- data/spec/unit/validations_spec.rb +12 -12
- data/spec/unit/with_metadata/default_metadata_class_factory_spec.rb +3 -2
- data/spec/unit/with_metadata/metadata_node_spec.rb +3 -2
- metadata +30 -130
- data/lib/active_fedora/datastreams/nokogiri_datastreams.rb +0 -119
- data/lib/active_fedora/datastreams.rb +0 -6
- data/lib/active_fedora/nom_datastream.rb +0 -73
- data/lib/active_fedora/om_datastream.rb +0 -118
- data/lib/active_fedora/profile_indexing_service.rb +0 -11
- data/lib/active_fedora/qualified_dublin_core_datastream.rb +0 -158
- data/lib/active_fedora/rdf/datastream_indexing.rb +0 -49
- data/lib/active_fedora/rdf/ntriples_rdf_datastream.rb +0 -13
- data/lib/active_fedora/rdf/rdf_datastream.rb +0 -167
- data/lib/active_fedora/rdf/rdfxml_datastream.rb +0 -13
- data/lib/active_fedora/solr_instance_loader.rb +0 -47
- data/solr/config/_rest_managed.json +0 -3
- data/solr/config/admin-extra.html +0 -31
- data/solr/config/elevate.xml +0 -36
- data/solr/config/mapping-ISOLatin1Accent.txt +0 -246
- data/solr/config/protwords.txt +0 -21
- data/solr/config/schema.xml +0 -372
- data/solr/config/scripts.conf +0 -24
- data/solr/config/solrconfig.xml +0 -311
- data/solr/config/spellings.txt +0 -2
- data/solr/config/stopwords.txt +0 -58
- data/solr/config/stopwords_en.txt +0 -58
- data/solr/config/synonyms.txt +0 -31
- data/solr/config/xslt/example.xsl +0 -132
- data/solr/config/xslt/example_atom.xsl +0 -67
- data/solr/config/xslt/example_rss.xsl +0 -66
- data/solr/config/xslt/luke.xsl +0 -337
- data/spec/fixtures/damsObjectModel.xml +0 -38
- data/spec/fixtures/dublin_core_rdf_descMetadata.nt +0 -13
- data/spec/fixtures/mixed_rdf_descMetadata.nt +0 -7
- data/spec/fixtures/mods_articles/mods_article1.xml +0 -98
- data/spec/fixtures/solr_rdf_descMetadata.nt +0 -7
- data/spec/integration/complex_rdf_datastream_spec.rb +0 -228
- data/spec/integration/datastream_rdf_nested_attributes_spec.rb +0 -179
- data/spec/integration/ntriples_datastream_spec.rb +0 -203
- data/spec/integration/om_datastream_spec.rb +0 -78
- data/spec/integration/solr_instance_loader_spec.rb +0 -156
- data/spec/samples/hydra-mods_article_datastream.rb +0 -517
- data/spec/samples/models/mods_article.rb +0 -9
- data/spec/samples/oral_history_sample.xml +0 -38
- data/spec/samples/oral_history_xml.xml +0 -35
- data/spec/samples/samples.rb +0 -2
- data/spec/unit/nom_datastream_spec.rb +0 -60
- data/spec/unit/ntriples_datastream_spec.rb +0 -170
- data/spec/unit/om_datastream_spec.rb +0 -294
- data/spec/unit/qualified_dublin_core_datastream_spec.rb +0 -119
- data/spec/unit/rdf_datastream_spec.rb +0 -84
- data/spec/unit/rdf_resource_datastream_spec.rb +0 -204
- data/spec/unit/rdfxml_datastream_spec.rb +0 -106
|
@@ -1,167 +0,0 @@
|
|
|
1
|
-
module ActiveFedora
|
|
2
|
-
class RDFDatastream < File
|
|
3
|
-
include ActiveTriples::NestedAttributes
|
|
4
|
-
include RDF::DatastreamIndexing
|
|
5
|
-
include ActiveTriples::Properties
|
|
6
|
-
include ActiveTriples::Reflection
|
|
7
|
-
extend Deprecation
|
|
8
|
-
|
|
9
|
-
delegate :rdf_subject, :set_value, :get_values, :attributes=, to: :resource
|
|
10
|
-
def initialize(*args)
|
|
11
|
-
super
|
|
12
|
-
deprecation_warning
|
|
13
|
-
end
|
|
14
|
-
|
|
15
|
-
def deprecation_warning
|
|
16
|
-
Deprecation.warn(RDFDatastream, "RDFDatastream is deprecated and will be removed in ActiveFedora 11", caller(2))
|
|
17
|
-
end
|
|
18
|
-
|
|
19
|
-
class << self
|
|
20
|
-
def rdf_subject(&block)
|
|
21
|
-
return @subject_block = block if block_given?
|
|
22
|
-
|
|
23
|
-
@subject_block ||= ->(ds) { parent_uri(ds) }
|
|
24
|
-
end
|
|
25
|
-
|
|
26
|
-
# Trim the last segment off the URI to get the parents uri
|
|
27
|
-
def parent_uri(ds)
|
|
28
|
-
m = /^(.*)\/[^\/]*$/.match(ds.uri)
|
|
29
|
-
if m
|
|
30
|
-
m[1]
|
|
31
|
-
else
|
|
32
|
-
::RDF::URI.new(nil)
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
|
|
36
|
-
##
|
|
37
|
-
# @param [Class] klass an object to set as the resource class, Must be a descendant of
|
|
38
|
-
# ActiveTriples::Resource and include ActiveFedora::RDF::Persistence.
|
|
39
|
-
#
|
|
40
|
-
# @return [Class] the object resource class
|
|
41
|
-
def resource_class(klass = nil)
|
|
42
|
-
if klass
|
|
43
|
-
raise ArgumentError, "#{self} already has a resource_class #{@resource_class}, cannot redefine it to #{klass}" if @resource_class && klass != @resource_class
|
|
44
|
-
raise ArgumentError, "#{klass} must be a subclass of ActiveTriples::Resource" unless klass < ActiveTriples::Resource
|
|
45
|
-
end
|
|
46
|
-
|
|
47
|
-
@resource_class ||= begin
|
|
48
|
-
klass = Class.new(klass || ActiveTriples::Resource)
|
|
49
|
-
klass.send(:include, RDF::Persistence)
|
|
50
|
-
klass
|
|
51
|
-
end
|
|
52
|
-
end
|
|
53
|
-
end
|
|
54
|
-
|
|
55
|
-
before_save do
|
|
56
|
-
if content.blank?
|
|
57
|
-
ActiveFedora::Base.logger.warn "Cowardly refusing to save a datastream with empty content: #{inspect}" if ActiveFedora::Base.logger
|
|
58
|
-
false
|
|
59
|
-
end
|
|
60
|
-
end
|
|
61
|
-
|
|
62
|
-
def parent_uri
|
|
63
|
-
self.class.parent_uri(self)
|
|
64
|
-
end
|
|
65
|
-
|
|
66
|
-
def metadata?
|
|
67
|
-
true
|
|
68
|
-
end
|
|
69
|
-
|
|
70
|
-
def content
|
|
71
|
-
serialize
|
|
72
|
-
end
|
|
73
|
-
|
|
74
|
-
def content=(new_content)
|
|
75
|
-
resource.clear!
|
|
76
|
-
resource << deserialize(new_content)
|
|
77
|
-
content
|
|
78
|
-
end
|
|
79
|
-
|
|
80
|
-
def uri=(uri)
|
|
81
|
-
super
|
|
82
|
-
resource.set_subject!(parent_uri) if empty_or_blank_subject?
|
|
83
|
-
end
|
|
84
|
-
|
|
85
|
-
def content_changed?
|
|
86
|
-
return false unless instance_variable_defined? :@resource
|
|
87
|
-
return true if empty_or_blank_subject? # can't be serialized because a subject hasn't been assigned yet.
|
|
88
|
-
@content = serialize
|
|
89
|
-
super
|
|
90
|
-
end
|
|
91
|
-
|
|
92
|
-
def empty_or_blank_subject?
|
|
93
|
-
resource.rdf_subject.node? || resource.rdf_subject.value.blank?
|
|
94
|
-
end
|
|
95
|
-
|
|
96
|
-
def freeze
|
|
97
|
-
@resource.freeze
|
|
98
|
-
end
|
|
99
|
-
|
|
100
|
-
##
|
|
101
|
-
# The resource is the RdfResource object that stores the graph for
|
|
102
|
-
# the datastream and is the central point for its relationship to
|
|
103
|
-
# other nodes.
|
|
104
|
-
#
|
|
105
|
-
# set_value, get_value, and property accessors are delegated to this object.
|
|
106
|
-
def resource
|
|
107
|
-
@resource ||= begin
|
|
108
|
-
klass = self.class.resource_class
|
|
109
|
-
klass.properties.merge(self.class.properties).each do |_prop, config|
|
|
110
|
-
klass.property(config.term,
|
|
111
|
-
predicate: config.predicate,
|
|
112
|
-
class_name: config.class_name)
|
|
113
|
-
end
|
|
114
|
-
klass.accepts_nested_attributes_for(*nested_attributes_options.keys) unless nested_attributes_options.blank?
|
|
115
|
-
uri_stub = self.class.rdf_subject.call(self)
|
|
116
|
-
|
|
117
|
-
r = klass.new(uri_stub)
|
|
118
|
-
r.datastream = self
|
|
119
|
-
r << deserialize
|
|
120
|
-
r
|
|
121
|
-
end
|
|
122
|
-
end
|
|
123
|
-
|
|
124
|
-
alias graph resource
|
|
125
|
-
|
|
126
|
-
def refresh_attributes
|
|
127
|
-
@resource = nil
|
|
128
|
-
end
|
|
129
|
-
|
|
130
|
-
##
|
|
131
|
-
# This method allows for delegation.
|
|
132
|
-
# This patches the fact that there's no consistent API for allowing delegation - we're matching the
|
|
133
|
-
# OmDatastream implementation as our "consistency" point.
|
|
134
|
-
# @TODO: We may need to enable deep RDF delegation at one point.
|
|
135
|
-
def term_values(*values)
|
|
136
|
-
send(values.first)
|
|
137
|
-
end
|
|
138
|
-
|
|
139
|
-
def update_indexed_attributes(hash)
|
|
140
|
-
hash.each do |fields, value|
|
|
141
|
-
fields.each do |field|
|
|
142
|
-
send("#{field}=", value)
|
|
143
|
-
end
|
|
144
|
-
end
|
|
145
|
-
end
|
|
146
|
-
|
|
147
|
-
def serialize
|
|
148
|
-
resource.set_subject!(parent_uri) if parent_uri && rdf_subject.node?
|
|
149
|
-
resource.dump serialization_format
|
|
150
|
-
end
|
|
151
|
-
|
|
152
|
-
def deserialize(data = nil)
|
|
153
|
-
return ::RDF::Graph.new if new_record? && data.nil?
|
|
154
|
-
data ||= remote_content
|
|
155
|
-
|
|
156
|
-
# Because datastream_content can return nil, we should check that here.
|
|
157
|
-
return ::RDF::Graph.new if data.nil?
|
|
158
|
-
|
|
159
|
-
data.force_encoding('utf-8')
|
|
160
|
-
::RDF::Graph.new << ::RDF::Reader.for(serialization_format).new(data)
|
|
161
|
-
end
|
|
162
|
-
|
|
163
|
-
def serialization_format
|
|
164
|
-
raise "you must override the `serialization_format' method in a subclass"
|
|
165
|
-
end
|
|
166
|
-
end
|
|
167
|
-
end
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
module ActiveFedora
|
|
2
|
-
class FedoraSolrMismatchError < ActiveFedora::ObjectNotFoundError
|
|
3
|
-
def initialize(fedora_id, solr_document_id)
|
|
4
|
-
super("Solr ID and Fedora ID do not match; Solr ID=#{solr_document_id}, Fedora ID=#{fedora_id}")
|
|
5
|
-
end
|
|
6
|
-
end
|
|
7
|
-
|
|
8
|
-
# Responsible for loading an ActiveFedora::Base proxy from a Solr document.
|
|
9
|
-
class SolrInstanceLoader
|
|
10
|
-
attr_reader :context, :id
|
|
11
|
-
private :context, :id
|
|
12
|
-
def initialize(context, id, solr_doc = nil)
|
|
13
|
-
@context = context
|
|
14
|
-
@id = id
|
|
15
|
-
self.solr_doc = solr_doc
|
|
16
|
-
end
|
|
17
|
-
|
|
18
|
-
def object
|
|
19
|
-
return @object if @object
|
|
20
|
-
@object = solr_doc.instantiate_with_json
|
|
21
|
-
@object.readonly!
|
|
22
|
-
@object.freeze
|
|
23
|
-
@object
|
|
24
|
-
end
|
|
25
|
-
|
|
26
|
-
private
|
|
27
|
-
|
|
28
|
-
def solr_doc
|
|
29
|
-
@solr_doc ||= begin
|
|
30
|
-
self.solr_doc = context.search_by_id(id)
|
|
31
|
-
end
|
|
32
|
-
end
|
|
33
|
-
|
|
34
|
-
def solr_doc=(solr_doc)
|
|
35
|
-
unless solr_doc.nil?
|
|
36
|
-
solr_doc = ActiveFedora::SolrHit.for(solr_doc)
|
|
37
|
-
validate_solr_doc_and_id!(solr_doc)
|
|
38
|
-
@solr_doc = solr_doc
|
|
39
|
-
end
|
|
40
|
-
end
|
|
41
|
-
|
|
42
|
-
def validate_solr_doc_and_id!(document)
|
|
43
|
-
return if id == document.id
|
|
44
|
-
raise ActiveFedora::FedoraSolrMismatchError, id, document.id
|
|
45
|
-
end
|
|
46
|
-
end
|
|
47
|
-
end
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
<!--
|
|
2
|
-
Licensed to the Apache Software Foundation (ASF) under one or more
|
|
3
|
-
contributor license agreements. See the NOTICE file distributed with
|
|
4
|
-
this work for additional information regarding copyright ownership.
|
|
5
|
-
The ASF licenses this file to You under the Apache License, Version 2.0
|
|
6
|
-
(the "License"); you may not use this file except in compliance with
|
|
7
|
-
the License. You may obtain a copy of the License at
|
|
8
|
-
|
|
9
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
|
|
11
|
-
Unless required by applicable law or agreed to in writing, software
|
|
12
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
-
See the License for the specific language governing permissions and
|
|
15
|
-
limitations under the License.
|
|
16
|
-
-->
|
|
17
|
-
|
|
18
|
-
<!-- The content of this page will be statically included into the top
|
|
19
|
-
of the admin page. Uncomment this as an example to see there the content
|
|
20
|
-
will show up.
|
|
21
|
-
|
|
22
|
-
<hr>
|
|
23
|
-
<i>This line will appear before the first table</i>
|
|
24
|
-
<tr>
|
|
25
|
-
<td colspan="2">
|
|
26
|
-
This row will be appended to the end of the first table
|
|
27
|
-
</td>
|
|
28
|
-
</tr>
|
|
29
|
-
<hr>
|
|
30
|
-
|
|
31
|
-
-->
|
data/solr/config/elevate.xml
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8" ?>
|
|
2
|
-
<!--
|
|
3
|
-
Licensed to the Apache Software Foundation (ASF) under one or more
|
|
4
|
-
contributor license agreements. See the NOTICE file distributed with
|
|
5
|
-
this work for additional information regarding copyright ownership.
|
|
6
|
-
The ASF licenses this file to You under the Apache License, Version 2.0
|
|
7
|
-
(the "License"); you may not use this file except in compliance with
|
|
8
|
-
the License. You may obtain a copy of the License at
|
|
9
|
-
|
|
10
|
-
http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
-
|
|
12
|
-
Unless required by applicable law or agreed to in writing, software
|
|
13
|
-
distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
-
See the License for the specific language governing permissions and
|
|
16
|
-
limitations under the License.
|
|
17
|
-
-->
|
|
18
|
-
|
|
19
|
-
<!-- If this file is found in the config directory, it will only be
|
|
20
|
-
loaded once at startup. If it is found in Solr's data
|
|
21
|
-
directory, it will be re-loaded every commit.
|
|
22
|
-
-->
|
|
23
|
-
|
|
24
|
-
<elevate>
|
|
25
|
-
<query text="foo bar">
|
|
26
|
-
<doc id="1" />
|
|
27
|
-
<doc id="2" />
|
|
28
|
-
<doc id="3" />
|
|
29
|
-
</query>
|
|
30
|
-
|
|
31
|
-
<query text="ipod">
|
|
32
|
-
<doc id="MA147LL/A" /> <!-- put the actual ipod at the top -->
|
|
33
|
-
<doc id="IW-02" exclude="true" /> <!-- exclude this cable -->
|
|
34
|
-
</query>
|
|
35
|
-
|
|
36
|
-
</elevate>
|
|
@@ -1,246 +0,0 @@
|
|
|
1
|
-
# The ASF licenses this file to You under the Apache License, Version 2.0
|
|
2
|
-
# (the "License"); you may not use this file except in compliance with
|
|
3
|
-
# the License. You may obtain a copy of the License at
|
|
4
|
-
#
|
|
5
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
#
|
|
7
|
-
# Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
# See the License for the specific language governing permissions and
|
|
11
|
-
# limitations under the License.
|
|
12
|
-
|
|
13
|
-
# Syntax:
|
|
14
|
-
# "source" => "target"
|
|
15
|
-
# "source".length() > 0 (source cannot be empty.)
|
|
16
|
-
# "target".length() >= 0 (target can be empty.)
|
|
17
|
-
|
|
18
|
-
# example:
|
|
19
|
-
# "??" => "A"
|
|
20
|
-
# "\u00C0" => "A"
|
|
21
|
-
# "\u00C0" => "\u0041"
|
|
22
|
-
# "??" => "ss"
|
|
23
|
-
# "\t" => " "
|
|
24
|
-
# "\n" => ""
|
|
25
|
-
|
|
26
|
-
# ?? => A
|
|
27
|
-
"\u00C0" => "A"
|
|
28
|
-
|
|
29
|
-
# ?? => A
|
|
30
|
-
"\u00C1" => "A"
|
|
31
|
-
|
|
32
|
-
# ?? => A
|
|
33
|
-
"\u00C2" => "A"
|
|
34
|
-
|
|
35
|
-
# ?? => A
|
|
36
|
-
"\u00C3" => "A"
|
|
37
|
-
|
|
38
|
-
# ?? => A
|
|
39
|
-
"\u00C4" => "A"
|
|
40
|
-
|
|
41
|
-
# ?? => A
|
|
42
|
-
"\u00C5" => "A"
|
|
43
|
-
|
|
44
|
-
# ?? => AE
|
|
45
|
-
"\u00C6" => "AE"
|
|
46
|
-
|
|
47
|
-
# ?? => C
|
|
48
|
-
"\u00C7" => "C"
|
|
49
|
-
|
|
50
|
-
# ?? => E
|
|
51
|
-
"\u00C8" => "E"
|
|
52
|
-
|
|
53
|
-
# ?? => E
|
|
54
|
-
"\u00C9" => "E"
|
|
55
|
-
|
|
56
|
-
# ?? => E
|
|
57
|
-
"\u00CA" => "E"
|
|
58
|
-
|
|
59
|
-
# ?? => E
|
|
60
|
-
"\u00CB" => "E"
|
|
61
|
-
|
|
62
|
-
# ?? => I
|
|
63
|
-
"\u00CC" => "I"
|
|
64
|
-
|
|
65
|
-
# ?? => I
|
|
66
|
-
"\u00CD" => "I"
|
|
67
|
-
|
|
68
|
-
# ?? => I
|
|
69
|
-
"\u00CE" => "I"
|
|
70
|
-
|
|
71
|
-
# ?? => I
|
|
72
|
-
"\u00CF" => "I"
|
|
73
|
-
|
|
74
|
-
# ?? => IJ
|
|
75
|
-
"\u0132" => "IJ"
|
|
76
|
-
|
|
77
|
-
# ?? => D
|
|
78
|
-
"\u00D0" => "D"
|
|
79
|
-
|
|
80
|
-
# ?? => N
|
|
81
|
-
"\u00D1" => "N"
|
|
82
|
-
|
|
83
|
-
# ?? => O
|
|
84
|
-
"\u00D2" => "O"
|
|
85
|
-
|
|
86
|
-
# ?? => O
|
|
87
|
-
"\u00D3" => "O"
|
|
88
|
-
|
|
89
|
-
# ?? => O
|
|
90
|
-
"\u00D4" => "O"
|
|
91
|
-
|
|
92
|
-
# ?? => O
|
|
93
|
-
"\u00D5" => "O"
|
|
94
|
-
|
|
95
|
-
# ?? => O
|
|
96
|
-
"\u00D6" => "O"
|
|
97
|
-
|
|
98
|
-
# ?? => O
|
|
99
|
-
"\u00D8" => "O"
|
|
100
|
-
|
|
101
|
-
# ?? => OE
|
|
102
|
-
"\u0152" => "OE"
|
|
103
|
-
|
|
104
|
-
# ??
|
|
105
|
-
"\u00DE" => "TH"
|
|
106
|
-
|
|
107
|
-
# ?? => U
|
|
108
|
-
"\u00D9" => "U"
|
|
109
|
-
|
|
110
|
-
# ?? => U
|
|
111
|
-
"\u00DA" => "U"
|
|
112
|
-
|
|
113
|
-
# ?? => U
|
|
114
|
-
"\u00DB" => "U"
|
|
115
|
-
|
|
116
|
-
# ?? => U
|
|
117
|
-
"\u00DC" => "U"
|
|
118
|
-
|
|
119
|
-
# ?? => Y
|
|
120
|
-
"\u00DD" => "Y"
|
|
121
|
-
|
|
122
|
-
# ?? => Y
|
|
123
|
-
"\u0178" => "Y"
|
|
124
|
-
|
|
125
|
-
# ?? => a
|
|
126
|
-
"\u00E0" => "a"
|
|
127
|
-
|
|
128
|
-
# ?? => a
|
|
129
|
-
"\u00E1" => "a"
|
|
130
|
-
|
|
131
|
-
# ?? => a
|
|
132
|
-
"\u00E2" => "a"
|
|
133
|
-
|
|
134
|
-
# ?? => a
|
|
135
|
-
"\u00E3" => "a"
|
|
136
|
-
|
|
137
|
-
# ?? => a
|
|
138
|
-
"\u00E4" => "a"
|
|
139
|
-
|
|
140
|
-
# ?? => a
|
|
141
|
-
"\u00E5" => "a"
|
|
142
|
-
|
|
143
|
-
# ?? => ae
|
|
144
|
-
"\u00E6" => "ae"
|
|
145
|
-
|
|
146
|
-
# ?? => c
|
|
147
|
-
"\u00E7" => "c"
|
|
148
|
-
|
|
149
|
-
# ?? => e
|
|
150
|
-
"\u00E8" => "e"
|
|
151
|
-
|
|
152
|
-
# ?? => e
|
|
153
|
-
"\u00E9" => "e"
|
|
154
|
-
|
|
155
|
-
# ?? => e
|
|
156
|
-
"\u00EA" => "e"
|
|
157
|
-
|
|
158
|
-
# ?? => e
|
|
159
|
-
"\u00EB" => "e"
|
|
160
|
-
|
|
161
|
-
# ?? => i
|
|
162
|
-
"\u00EC" => "i"
|
|
163
|
-
|
|
164
|
-
# ?? => i
|
|
165
|
-
"\u00ED" => "i"
|
|
166
|
-
|
|
167
|
-
# ?? => i
|
|
168
|
-
"\u00EE" => "i"
|
|
169
|
-
|
|
170
|
-
# ?? => i
|
|
171
|
-
"\u00EF" => "i"
|
|
172
|
-
|
|
173
|
-
# ?? => ij
|
|
174
|
-
"\u0133" => "ij"
|
|
175
|
-
|
|
176
|
-
# ?? => d
|
|
177
|
-
"\u00F0" => "d"
|
|
178
|
-
|
|
179
|
-
# ?? => n
|
|
180
|
-
"\u00F1" => "n"
|
|
181
|
-
|
|
182
|
-
# ?? => o
|
|
183
|
-
"\u00F2" => "o"
|
|
184
|
-
|
|
185
|
-
# ?? => o
|
|
186
|
-
"\u00F3" => "o"
|
|
187
|
-
|
|
188
|
-
# ?? => o
|
|
189
|
-
"\u00F4" => "o"
|
|
190
|
-
|
|
191
|
-
# ?? => o
|
|
192
|
-
"\u00F5" => "o"
|
|
193
|
-
|
|
194
|
-
# ?? => o
|
|
195
|
-
"\u00F6" => "o"
|
|
196
|
-
|
|
197
|
-
# ?? => o
|
|
198
|
-
"\u00F8" => "o"
|
|
199
|
-
|
|
200
|
-
# ?? => oe
|
|
201
|
-
"\u0153" => "oe"
|
|
202
|
-
|
|
203
|
-
# ?? => ss
|
|
204
|
-
"\u00DF" => "ss"
|
|
205
|
-
|
|
206
|
-
# ?? => th
|
|
207
|
-
"\u00FE" => "th"
|
|
208
|
-
|
|
209
|
-
# ?? => u
|
|
210
|
-
"\u00F9" => "u"
|
|
211
|
-
|
|
212
|
-
# ?? => u
|
|
213
|
-
"\u00FA" => "u"
|
|
214
|
-
|
|
215
|
-
# ?? => u
|
|
216
|
-
"\u00FB" => "u"
|
|
217
|
-
|
|
218
|
-
# ?? => u
|
|
219
|
-
"\u00FC" => "u"
|
|
220
|
-
|
|
221
|
-
# ?? => y
|
|
222
|
-
"\u00FD" => "y"
|
|
223
|
-
|
|
224
|
-
# ?? => y
|
|
225
|
-
"\u00FF" => "y"
|
|
226
|
-
|
|
227
|
-
# ??? => ff
|
|
228
|
-
"\uFB00" => "ff"
|
|
229
|
-
|
|
230
|
-
# ??? => fi
|
|
231
|
-
"\uFB01" => "fi"
|
|
232
|
-
|
|
233
|
-
# ??? => fl
|
|
234
|
-
"\uFB02" => "fl"
|
|
235
|
-
|
|
236
|
-
# ??? => ffi
|
|
237
|
-
"\uFB03" => "ffi"
|
|
238
|
-
|
|
239
|
-
# ??? => ffl
|
|
240
|
-
"\uFB04" => "ffl"
|
|
241
|
-
|
|
242
|
-
# ??? => ft
|
|
243
|
-
"\uFB05" => "ft"
|
|
244
|
-
|
|
245
|
-
# ??? => st
|
|
246
|
-
"\uFB06" => "st"
|
data/solr/config/protwords.txt
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
# The ASF licenses this file to You under the Apache License, Version 2.0
|
|
2
|
-
# (the "License"); you may not use this file except in compliance with
|
|
3
|
-
# the License. You may obtain a copy of the License at
|
|
4
|
-
#
|
|
5
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
#
|
|
7
|
-
# Unless required by applicable law or agreed to in writing, software
|
|
8
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
9
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
10
|
-
# See the License for the specific language governing permissions and
|
|
11
|
-
# limitations under the License.
|
|
12
|
-
|
|
13
|
-
#-----------------------------------------------------------------------
|
|
14
|
-
# Use a protected word file to protect against the stemmer reducing two
|
|
15
|
-
# unrelated words to the same base word.
|
|
16
|
-
|
|
17
|
-
# Some non-words that normally won't be encountered,
|
|
18
|
-
# just to test that they won't be stemmed.
|
|
19
|
-
dontstems
|
|
20
|
-
zwhacky
|
|
21
|
-
|