kithe 2.0.0.pre.beta1 → 2.0.0.pre.rc1
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/lib/kithe/engine.rb +11 -3
- data/lib/kithe/patch_fx.rb +39 -0
- data/lib/kithe/version.rb +1 -1
- data/spec/dummy/db/schema.rb +102 -0
- data/spec/dummy/log/development.log +2003 -0
- data/spec/dummy/log/test.log +3366 -0
- metadata +26 -6
- data/spec/dummy/db/structure.sql +0 -309
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kithe
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.0.pre.
|
4
|
+
version: 2.0.0.pre.rc1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonathan Rochkind
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-05-
|
11
|
+
date: 2020-05-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -182,6 +182,26 @@ dependencies:
|
|
182
182
|
- - ">="
|
183
183
|
- !ruby/object:Gem::Version
|
184
184
|
version: '0'
|
185
|
+
- !ruby/object:Gem::Dependency
|
186
|
+
name: fx
|
187
|
+
requirement: !ruby/object:Gem::Requirement
|
188
|
+
requirements:
|
189
|
+
- - ">="
|
190
|
+
- !ruby/object:Gem::Version
|
191
|
+
version: 0.5.0
|
192
|
+
- - "<"
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
version: '1'
|
195
|
+
type: :runtime
|
196
|
+
prerelease: false
|
197
|
+
version_requirements: !ruby/object:Gem::Requirement
|
198
|
+
requirements:
|
199
|
+
- - ">="
|
200
|
+
- !ruby/object:Gem::Version
|
201
|
+
version: 0.5.0
|
202
|
+
- - "<"
|
203
|
+
- !ruby/object:Gem::Version
|
204
|
+
version: '1'
|
185
205
|
- !ruby/object:Gem::Dependency
|
186
206
|
name: traject
|
187
207
|
requirement: !ruby/object:Gem::Requirement
|
@@ -356,6 +376,7 @@ files:
|
|
356
376
|
- lib/kithe/blacklight_tools/search_service_bulk_load.rb
|
357
377
|
- lib/kithe/engine.rb
|
358
378
|
- lib/kithe/indexable_settings.rb
|
379
|
+
- lib/kithe/patch_fx.rb
|
359
380
|
- lib/kithe/sti_preload.rb
|
360
381
|
- lib/kithe/version.rb
|
361
382
|
- lib/shrine/plugins/kithe_accept_remote_url.rb
|
@@ -421,7 +442,7 @@ files:
|
|
421
442
|
- spec/dummy/config/routes.rb
|
422
443
|
- spec/dummy/config/spring.rb
|
423
444
|
- spec/dummy/config/storage.yml
|
424
|
-
- spec/dummy/db/
|
445
|
+
- spec/dummy/db/schema.rb
|
425
446
|
- spec/dummy/log/development.log
|
426
447
|
- spec/dummy/log/test.log
|
427
448
|
- spec/dummy/package.json
|
@@ -486,8 +507,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
486
507
|
- !ruby/object:Gem::Version
|
487
508
|
version: 1.3.1
|
488
509
|
requirements: []
|
489
|
-
|
490
|
-
rubygems_version: 2.7.6
|
510
|
+
rubygems_version: 3.0.3
|
491
511
|
signing_key:
|
492
512
|
specification_version: 4
|
493
513
|
summary: Shareable tools/components for building a digital collections app in Rails.
|
@@ -548,7 +568,7 @@ test_files:
|
|
548
568
|
- spec/dummy/public/404.html
|
549
569
|
- spec/dummy/public/apple-touch-icon-precomposed.png
|
550
570
|
- spec/dummy/package.json
|
551
|
-
- spec/dummy/db/
|
571
|
+
- spec/dummy/db/schema.rb
|
552
572
|
- spec/dummy/log/test.log
|
553
573
|
- spec/dummy/log/development.log
|
554
574
|
- spec/dummy/tmp/development_secret.txt
|
data/spec/dummy/db/structure.sql
DELETED
@@ -1,309 +0,0 @@
|
|
1
|
-
SET statement_timeout = 0;
|
2
|
-
SET lock_timeout = 0;
|
3
|
-
SET idle_in_transaction_session_timeout = 0;
|
4
|
-
SET client_encoding = 'UTF8';
|
5
|
-
SET standard_conforming_strings = on;
|
6
|
-
SELECT pg_catalog.set_config('search_path', '', false);
|
7
|
-
SET check_function_bodies = false;
|
8
|
-
SET client_min_messages = warning;
|
9
|
-
SET row_security = off;
|
10
|
-
|
11
|
-
--
|
12
|
-
-- Name: pgcrypto; Type: EXTENSION; Schema: -; Owner: -
|
13
|
-
--
|
14
|
-
|
15
|
-
CREATE EXTENSION IF NOT EXISTS pgcrypto WITH SCHEMA public;
|
16
|
-
|
17
|
-
|
18
|
-
--
|
19
|
-
-- Name: EXTENSION pgcrypto; Type: COMMENT; Schema: -; Owner: -
|
20
|
-
--
|
21
|
-
|
22
|
-
COMMENT ON EXTENSION pgcrypto IS 'cryptographic functions';
|
23
|
-
|
24
|
-
|
25
|
-
--
|
26
|
-
-- Name: kithe_models_friendlier_id_gen(bigint, bigint); Type: FUNCTION; Schema: public; Owner: -
|
27
|
-
--
|
28
|
-
|
29
|
-
CREATE FUNCTION public.kithe_models_friendlier_id_gen(min_value bigint, max_value bigint) RETURNS text
|
30
|
-
LANGUAGE plpgsql
|
31
|
-
AS $$
|
32
|
-
DECLARE
|
33
|
-
new_id_int bigint;
|
34
|
-
new_id_str character varying := '';
|
35
|
-
done bool;
|
36
|
-
tries integer;
|
37
|
-
alphabet char[] := ARRAY['0','1','2','3','4','5','6','7','8','9',
|
38
|
-
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n',
|
39
|
-
'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'];
|
40
|
-
alphabet_length integer := array_length(alphabet, 1);
|
41
|
-
|
42
|
-
BEGIN
|
43
|
-
done := false;
|
44
|
-
tries := 0;
|
45
|
-
WHILE (NOT done) LOOP
|
46
|
-
tries := tries + 1;
|
47
|
-
IF (tries > 3) THEN
|
48
|
-
RAISE 'Could not find non-conflicting friendlier_id in 3 tries';
|
49
|
-
END IF;
|
50
|
-
|
51
|
-
new_id_int := trunc(random() * (max_value - min_value) + min_value);
|
52
|
-
|
53
|
-
-- convert bigint to a Base-36 alphanumeric string
|
54
|
-
-- see https://web.archive.org/web/20130420084605/http://www.jamiebegin.com/base36-conversion-in-postgresql/
|
55
|
-
-- https://gist.github.com/btbytes/7159902
|
56
|
-
WHILE new_id_int != 0 LOOP
|
57
|
-
new_id_str := alphabet[(new_id_int % alphabet_length)+1] || new_id_str;
|
58
|
-
new_id_int := new_id_int / alphabet_length;
|
59
|
-
END LOOP;
|
60
|
-
|
61
|
-
done := NOT exists(SELECT 1 FROM kithe_models WHERE friendlier_id=new_id_str);
|
62
|
-
END LOOP;
|
63
|
-
RETURN new_id_str;
|
64
|
-
END;
|
65
|
-
$$;
|
66
|
-
|
67
|
-
|
68
|
-
SET default_tablespace = '';
|
69
|
-
|
70
|
-
SET default_with_oids = false;
|
71
|
-
|
72
|
-
--
|
73
|
-
-- Name: ar_internal_metadata; Type: TABLE; Schema: public; Owner: -
|
74
|
-
--
|
75
|
-
|
76
|
-
CREATE TABLE public.ar_internal_metadata (
|
77
|
-
key character varying NOT NULL,
|
78
|
-
value character varying,
|
79
|
-
created_at timestamp without time zone NOT NULL,
|
80
|
-
updated_at timestamp without time zone NOT NULL
|
81
|
-
);
|
82
|
-
|
83
|
-
|
84
|
-
--
|
85
|
-
-- Name: kithe_derivatives; Type: TABLE; Schema: public; Owner: -
|
86
|
-
--
|
87
|
-
|
88
|
-
CREATE TABLE public.kithe_derivatives (
|
89
|
-
id bigint NOT NULL,
|
90
|
-
key character varying NOT NULL,
|
91
|
-
file_data jsonb,
|
92
|
-
asset_id uuid NOT NULL,
|
93
|
-
created_at timestamp without time zone NOT NULL,
|
94
|
-
updated_at timestamp without time zone NOT NULL
|
95
|
-
);
|
96
|
-
|
97
|
-
|
98
|
-
--
|
99
|
-
-- Name: kithe_derivatives_id_seq; Type: SEQUENCE; Schema: public; Owner: -
|
100
|
-
--
|
101
|
-
|
102
|
-
CREATE SEQUENCE public.kithe_derivatives_id_seq
|
103
|
-
START WITH 1
|
104
|
-
INCREMENT BY 1
|
105
|
-
NO MINVALUE
|
106
|
-
NO MAXVALUE
|
107
|
-
CACHE 1;
|
108
|
-
|
109
|
-
|
110
|
-
--
|
111
|
-
-- Name: kithe_derivatives_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
|
112
|
-
--
|
113
|
-
|
114
|
-
ALTER SEQUENCE public.kithe_derivatives_id_seq OWNED BY public.kithe_derivatives.id;
|
115
|
-
|
116
|
-
|
117
|
-
--
|
118
|
-
-- Name: kithe_model_contains; Type: TABLE; Schema: public; Owner: -
|
119
|
-
--
|
120
|
-
|
121
|
-
CREATE TABLE public.kithe_model_contains (
|
122
|
-
containee_id uuid,
|
123
|
-
container_id uuid
|
124
|
-
);
|
125
|
-
|
126
|
-
|
127
|
-
--
|
128
|
-
-- Name: kithe_models; Type: TABLE; Schema: public; Owner: -
|
129
|
-
--
|
130
|
-
|
131
|
-
CREATE TABLE public.kithe_models (
|
132
|
-
id uuid DEFAULT public.gen_random_uuid() NOT NULL,
|
133
|
-
title character varying NOT NULL,
|
134
|
-
type character varying NOT NULL,
|
135
|
-
"position" integer,
|
136
|
-
json_attributes jsonb,
|
137
|
-
created_at timestamp without time zone NOT NULL,
|
138
|
-
updated_at timestamp without time zone NOT NULL,
|
139
|
-
parent_id uuid,
|
140
|
-
friendlier_id character varying DEFAULT public.kithe_models_friendlier_id_gen('2821109907456'::bigint, '101559956668415'::bigint) NOT NULL,
|
141
|
-
file_data jsonb,
|
142
|
-
representative_id uuid,
|
143
|
-
leaf_representative_id uuid,
|
144
|
-
kithe_model_type integer NOT NULL
|
145
|
-
);
|
146
|
-
|
147
|
-
|
148
|
-
--
|
149
|
-
-- Name: schema_migrations; Type: TABLE; Schema: public; Owner: -
|
150
|
-
--
|
151
|
-
|
152
|
-
CREATE TABLE public.schema_migrations (
|
153
|
-
version character varying NOT NULL
|
154
|
-
);
|
155
|
-
|
156
|
-
|
157
|
-
--
|
158
|
-
-- Name: kithe_derivatives id; Type: DEFAULT; Schema: public; Owner: -
|
159
|
-
--
|
160
|
-
|
161
|
-
ALTER TABLE ONLY public.kithe_derivatives ALTER COLUMN id SET DEFAULT nextval('public.kithe_derivatives_id_seq'::regclass);
|
162
|
-
|
163
|
-
|
164
|
-
--
|
165
|
-
-- Name: ar_internal_metadata ar_internal_metadata_pkey; Type: CONSTRAINT; Schema: public; Owner: -
|
166
|
-
--
|
167
|
-
|
168
|
-
ALTER TABLE ONLY public.ar_internal_metadata
|
169
|
-
ADD CONSTRAINT ar_internal_metadata_pkey PRIMARY KEY (key);
|
170
|
-
|
171
|
-
|
172
|
-
--
|
173
|
-
-- Name: kithe_derivatives kithe_derivatives_pkey; Type: CONSTRAINT; Schema: public; Owner: -
|
174
|
-
--
|
175
|
-
|
176
|
-
ALTER TABLE ONLY public.kithe_derivatives
|
177
|
-
ADD CONSTRAINT kithe_derivatives_pkey PRIMARY KEY (id);
|
178
|
-
|
179
|
-
|
180
|
-
--
|
181
|
-
-- Name: kithe_models kithe_models_pkey; Type: CONSTRAINT; Schema: public; Owner: -
|
182
|
-
--
|
183
|
-
|
184
|
-
ALTER TABLE ONLY public.kithe_models
|
185
|
-
ADD CONSTRAINT kithe_models_pkey PRIMARY KEY (id);
|
186
|
-
|
187
|
-
|
188
|
-
--
|
189
|
-
-- Name: schema_migrations schema_migrations_pkey; Type: CONSTRAINT; Schema: public; Owner: -
|
190
|
-
--
|
191
|
-
|
192
|
-
ALTER TABLE ONLY public.schema_migrations
|
193
|
-
ADD CONSTRAINT schema_migrations_pkey PRIMARY KEY (version);
|
194
|
-
|
195
|
-
|
196
|
-
--
|
197
|
-
-- Name: index_kithe_derivatives_on_asset_id; Type: INDEX; Schema: public; Owner: -
|
198
|
-
--
|
199
|
-
|
200
|
-
CREATE INDEX index_kithe_derivatives_on_asset_id ON public.kithe_derivatives USING btree (asset_id);
|
201
|
-
|
202
|
-
|
203
|
-
--
|
204
|
-
-- Name: index_kithe_derivatives_on_asset_id_and_key; Type: INDEX; Schema: public; Owner: -
|
205
|
-
--
|
206
|
-
|
207
|
-
CREATE UNIQUE INDEX index_kithe_derivatives_on_asset_id_and_key ON public.kithe_derivatives USING btree (asset_id, key);
|
208
|
-
|
209
|
-
|
210
|
-
--
|
211
|
-
-- Name: index_kithe_model_contains_on_containee_id; Type: INDEX; Schema: public; Owner: -
|
212
|
-
--
|
213
|
-
|
214
|
-
CREATE INDEX index_kithe_model_contains_on_containee_id ON public.kithe_model_contains USING btree (containee_id);
|
215
|
-
|
216
|
-
|
217
|
-
--
|
218
|
-
-- Name: index_kithe_model_contains_on_container_id; Type: INDEX; Schema: public; Owner: -
|
219
|
-
--
|
220
|
-
|
221
|
-
CREATE INDEX index_kithe_model_contains_on_container_id ON public.kithe_model_contains USING btree (container_id);
|
222
|
-
|
223
|
-
|
224
|
-
--
|
225
|
-
-- Name: index_kithe_models_on_friendlier_id; Type: INDEX; Schema: public; Owner: -
|
226
|
-
--
|
227
|
-
|
228
|
-
CREATE UNIQUE INDEX index_kithe_models_on_friendlier_id ON public.kithe_models USING btree (friendlier_id);
|
229
|
-
|
230
|
-
|
231
|
-
--
|
232
|
-
-- Name: index_kithe_models_on_parent_id; Type: INDEX; Schema: public; Owner: -
|
233
|
-
--
|
234
|
-
|
235
|
-
CREATE INDEX index_kithe_models_on_parent_id ON public.kithe_models USING btree (parent_id);
|
236
|
-
|
237
|
-
|
238
|
-
--
|
239
|
-
-- Name: index_kithe_models_on_representative_id; Type: INDEX; Schema: public; Owner: -
|
240
|
-
--
|
241
|
-
|
242
|
-
CREATE INDEX index_kithe_models_on_representative_id ON public.kithe_models USING btree (representative_id);
|
243
|
-
|
244
|
-
|
245
|
-
--
|
246
|
-
-- Name: kithe_model_contains fk_rails_091010187b; Type: FK CONSTRAINT; Schema: public; Owner: -
|
247
|
-
--
|
248
|
-
|
249
|
-
ALTER TABLE ONLY public.kithe_model_contains
|
250
|
-
ADD CONSTRAINT fk_rails_091010187b FOREIGN KEY (container_id) REFERENCES public.kithe_models(id);
|
251
|
-
|
252
|
-
|
253
|
-
--
|
254
|
-
-- Name: kithe_derivatives fk_rails_3dac8b4201; Type: FK CONSTRAINT; Schema: public; Owner: -
|
255
|
-
--
|
256
|
-
|
257
|
-
ALTER TABLE ONLY public.kithe_derivatives
|
258
|
-
ADD CONSTRAINT fk_rails_3dac8b4201 FOREIGN KEY (asset_id) REFERENCES public.kithe_models(id);
|
259
|
-
|
260
|
-
|
261
|
-
--
|
262
|
-
-- Name: kithe_models fk_rails_403cce5c0d; Type: FK CONSTRAINT; Schema: public; Owner: -
|
263
|
-
--
|
264
|
-
|
265
|
-
ALTER TABLE ONLY public.kithe_models
|
266
|
-
ADD CONSTRAINT fk_rails_403cce5c0d FOREIGN KEY (leaf_representative_id) REFERENCES public.kithe_models(id);
|
267
|
-
|
268
|
-
|
269
|
-
--
|
270
|
-
-- Name: kithe_model_contains fk_rails_490c1158f7; Type: FK CONSTRAINT; Schema: public; Owner: -
|
271
|
-
--
|
272
|
-
|
273
|
-
ALTER TABLE ONLY public.kithe_model_contains
|
274
|
-
ADD CONSTRAINT fk_rails_490c1158f7 FOREIGN KEY (containee_id) REFERENCES public.kithe_models(id);
|
275
|
-
|
276
|
-
|
277
|
-
--
|
278
|
-
-- Name: kithe_models fk_rails_90130a9780; Type: FK CONSTRAINT; Schema: public; Owner: -
|
279
|
-
--
|
280
|
-
|
281
|
-
ALTER TABLE ONLY public.kithe_models
|
282
|
-
ADD CONSTRAINT fk_rails_90130a9780 FOREIGN KEY (parent_id) REFERENCES public.kithe_models(id);
|
283
|
-
|
284
|
-
|
285
|
-
--
|
286
|
-
-- Name: kithe_models fk_rails_afa93b7b5d; Type: FK CONSTRAINT; Schema: public; Owner: -
|
287
|
-
--
|
288
|
-
|
289
|
-
ALTER TABLE ONLY public.kithe_models
|
290
|
-
ADD CONSTRAINT fk_rails_afa93b7b5d FOREIGN KEY (representative_id) REFERENCES public.kithe_models(id);
|
291
|
-
|
292
|
-
|
293
|
-
--
|
294
|
-
-- PostgreSQL database dump complete
|
295
|
-
--
|
296
|
-
|
297
|
-
SET search_path TO "$user", public;
|
298
|
-
|
299
|
-
INSERT INTO "schema_migrations" (version) VALUES
|
300
|
-
('20181015143259'),
|
301
|
-
('20181015143413'),
|
302
|
-
('20181015143737'),
|
303
|
-
('20181031190647'),
|
304
|
-
('20181128185658'),
|
305
|
-
('20190103144947'),
|
306
|
-
('20190109192252'),
|
307
|
-
('20190404144551');
|
308
|
-
|
309
|
-
|