message-db 2.1.1 → 2.1.2
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/database/VERSION.txt +1 -1
- data/database/functions/get-category-messages.sql +7 -3
- data/database/functions/get-stream-messages.sql +7 -3
- data/database/functions/message-store-version.sql +1 -1
- data/database/update/1.2.2.md +12 -0
- data/database/update/1.2.2.sh +65 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7892ee4f77dad72c6a2b193e29f13b9505a0daf6fcd81ba66afc46d5c127da77
|
4
|
+
data.tar.gz: b3410f3f9e26e1e4b27295ffd80f80631ff1246293b28efd601d5afaa85afafd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19444da029ffaa0ec179bae754aea49b8a8cac5530ccfc8ac12c0aca0339768ed884c626d6f9a5e6a9d77d2f4e853d1712f45ad475282984e537180608061e47
|
7
|
+
data.tar.gz: 6c7b04fc9433b07d92bdfe53cdd034a6e6def05258bfded0aa09586fc6fe3c93fb39a048adcd36e0cd37fa3fb170a1c701c46f07e72026043f40216d70d4c6b3
|
data/database/VERSION.txt
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.2.
|
1
|
+
1.2.2
|
@@ -101,9 +101,13 @@ BEGIN
|
|
101
101
|
|
102
102
|
_command := _command || '
|
103
103
|
ORDER BY
|
104
|
-
global_position ASC
|
105
|
-
|
106
|
-
|
104
|
+
global_position ASC';
|
105
|
+
|
106
|
+
IF get_category_messages.batch_size != -1 THEN
|
107
|
+
_command := _command || '
|
108
|
+
LIMIT
|
109
|
+
$3';
|
110
|
+
END IF;
|
107
111
|
|
108
112
|
IF current_setting('message_store.debug_get', true) = 'on' OR current_setting('message_store.debug', true) = 'on' THEN
|
109
113
|
RAISE NOTICE '» get_category_messages';
|
@@ -49,9 +49,13 @@ BEGIN
|
|
49
49
|
|
50
50
|
_command := _command || '
|
51
51
|
ORDER BY
|
52
|
-
position ASC
|
53
|
-
|
54
|
-
|
52
|
+
position ASC';
|
53
|
+
|
54
|
+
IF get_stream_messages.batch_size != -1 THEN
|
55
|
+
_command := _command || '
|
56
|
+
LIMIT
|
57
|
+
$3';
|
58
|
+
END IF;
|
55
59
|
|
56
60
|
IF current_setting('message_store.debug_get', true) = 'on' OR current_setting('message_store.debug', true) = 'on' THEN
|
57
61
|
RAISE NOTICE '» get_stream_messages';
|
@@ -0,0 +1,12 @@
|
|
1
|
+
# 1.2.2 Update
|
2
|
+
|
3
|
+
Note: There are no backward-incompatible changes in this update.
|
4
|
+
|
5
|
+
This update requires the execution of the v1.2.2 update script: `1.2.2.sh`. For instructions on applying update scripts, see:
|
6
|
+
|
7
|
+
[http://docs.eventide-project.org/user-guide/message-db/update.html](http://docs.eventide-project.org/user-guide/message-db/update.html)
|
8
|
+
|
9
|
+
The following changes are made by the 1.2.2.sh update script:
|
10
|
+
|
11
|
+
- The `get_category_messages` server function will return the entire, unlimited extent of messages in a category if -1 is sent as the `batch_size` argument
|
12
|
+
- The `get_stream_messages` server function will return the entire, unlimited extent of messages in a stream if -1 is sent as the `batch_size` argument
|
@@ -0,0 +1,65 @@
|
|
1
|
+
#!/usr/bin/env bash
|
2
|
+
|
3
|
+
set -e
|
4
|
+
|
5
|
+
echo
|
6
|
+
echo "Message DB"
|
7
|
+
echo
|
8
|
+
echo "Update the message_store database to v1.2.2"
|
9
|
+
echo
|
10
|
+
echo "WARNING:"
|
11
|
+
echo "This script updates a post-v1 message_store database to Message DB v1.2.2"
|
12
|
+
echo "Do not run this script on a Message DB pre-v1 database"
|
13
|
+
echo
|
14
|
+
echo "Fore more information about the changes made to the message store by"
|
15
|
+
echo "this update, see: https://github.com/message-db/message-db/blob/master/database/update/1.2.2.md"
|
16
|
+
echo
|
17
|
+
echo "- Press CTRL+C to stop this script from running"
|
18
|
+
echo "- Press RETURN to allow the script to proceed"
|
19
|
+
echo
|
20
|
+
|
21
|
+
read
|
22
|
+
|
23
|
+
function script_dir {
|
24
|
+
val="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
25
|
+
echo "$val"
|
26
|
+
}
|
27
|
+
|
28
|
+
base="$(script_dir)/.."
|
29
|
+
echo $base
|
30
|
+
|
31
|
+
echo
|
32
|
+
echo "Updating Database"
|
33
|
+
echo "Version: $(cat $base/VERSION.txt)"
|
34
|
+
echo "= = ="
|
35
|
+
|
36
|
+
if [ -z ${DATABASE_NAME+x} ]; then
|
37
|
+
echo "(DATABASE_NAME is not set. Default will be used.)"
|
38
|
+
database=message_store
|
39
|
+
export DATABASE_NAME=$database
|
40
|
+
else
|
41
|
+
database=$DATABASE_NAME
|
42
|
+
fi
|
43
|
+
echo
|
44
|
+
|
45
|
+
if [ -z ${PGOPTIONS+x} ]; then
|
46
|
+
export PGOPTIONS='-c client_min_messages=warning'
|
47
|
+
fi
|
48
|
+
|
49
|
+
function install-functions {
|
50
|
+
echo "» get_stream_messages function"
|
51
|
+
psql $database -q -f $base/functions/get-stream-messages.sql
|
52
|
+
|
53
|
+
echo "» get_category_messages function"
|
54
|
+
psql $database -q -f $base/functions/get-category-messages.sql
|
55
|
+
}
|
56
|
+
|
57
|
+
echo "Installing Functions"
|
58
|
+
echo "- - -"
|
59
|
+
install-functions
|
60
|
+
echo
|
61
|
+
|
62
|
+
echo "= = ="
|
63
|
+
echo "Done Updating Database"
|
64
|
+
echo "Version: $(cat $base/VERSION.txt)"
|
65
|
+
echo
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: message-db
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The Eventide Project
|
8
8
|
autorequire:
|
9
9
|
bindir: scripts
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-04
|
11
|
+
date: 2020-05-04 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: " "
|
14
14
|
email: opensource@eventide-project.org
|
@@ -81,6 +81,8 @@ files:
|
|
81
81
|
- database/update.sh
|
82
82
|
- database/update/1.0.0.md
|
83
83
|
- database/update/1.0.0.sh
|
84
|
+
- database/update/1.2.2.md
|
85
|
+
- database/update/1.2.2.sh
|
84
86
|
- database/views/category-type-summary.sql
|
85
87
|
- database/views/stream-summary.sql
|
86
88
|
- database/views/stream-type-summary.sql
|