Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v0.14.0 #1313

Merged
merged 224 commits into from
Sep 6, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
224 commits
Select commit Hold shift + click to select a range
891c119
Bump github.com/stretchr/testify from 1.3.0 to 1.4.0
dependabot-preview[bot] Aug 16, 2019
ff2369a
Merge branch 'dev' into dependabot/go_modules/github.com/stretchr/tes…
antho1404 Aug 16, 2019
6589856
Merge pull request #1232 from mesg-foundation/dependabot/go_modules/g…
Aug 16, 2019
42a3c5b
simplify function initDependencies in main.go. Only the returned SDK …
NicolasMahe Aug 20, 2019
de2ffd8
Merge pull request #1239 from mesg-foundation/feature/simplify-dep-main
antho1404 Aug 20, 2019
c120c61
add input resolution struct in workflow
antho1404 Aug 21, 2019
603ef15
update workflow api
antho1404 Aug 21, 2019
1346de4
add missing db cleanup in grpc core test
NicolasMahe Aug 22, 2019
3a9345e
Merge pull request #1242 from mesg-foundation/test/fix-missing-cleanu…
antho1404 Aug 22, 2019
4fbe6f6
add find edge function
antho1404 Aug 22, 2019
9818f07
remove invalid test
antho1404 Aug 22, 2019
764e136
add store package
NicolasMahe Aug 22, 2019
f1716d1
Remove serviceDB interface. Update LevelDBServiceDB to a generic data…
NicolasMahe Aug 22, 2019
09ac8a0
update codebase to reflect change in service db
NicolasMahe Aug 22, 2019
7975627
add cosmos app builder
NicolasMahe Aug 22, 2019
ea70b94
add cosmos app module builder
NicolasMahe Aug 22, 2019
61b1189
add cosmos keybase (previously tendermint keybase)
NicolasMahe Aug 22, 2019
ee03f45
Add cosmos transaction builder
NicolasMahe Aug 22, 2019
d855bee
Move tendermint node helper to cosmos and simplify it
NicolasMahe Aug 22, 2019
09c9976
Merge branch 'cosmos/service-db' into cosmos/app-builder-helpers
NicolasMahe Aug 22, 2019
6d7da81
input resolution for the scheduler
antho1404 Aug 22, 2019
502cd9c
Merge branch 'dev' into feature/workflow-data-resolver
antho1404 Aug 22, 2019
5bc6793
lint
antho1404 Aug 22, 2019
71bbd02
let sdk manage cosmos module dependencies
NicolasMahe Aug 22, 2019
f9e092d
update main to reflect modification
NicolasMahe Aug 22, 2019
879b092
remove useless cosmos app file
NicolasMahe Aug 22, 2019
2e74ffc
go mod tidy
NicolasMahe Aug 22, 2019
ea4fd02
go mod
NicolasMahe Aug 22, 2019
9e723de
Merge branch 'cosmos/app-helpers' into cosmos/start-node
NicolasMahe Aug 22, 2019
9f83f5f
remove useless cosmos app file
NicolasMahe Aug 22, 2019
7f64631
update main to reflect new cosmos helpers
NicolasMahe Aug 22, 2019
30a1c46
Merge branch 'cosmos/app-helpers' into cosmos/start-node
NicolasMahe Aug 22, 2019
365ace9
go mod
NicolasMahe Aug 22, 2019
287d5fb
Rename cosmos.New to cosmos.NewApp
NicolasMahe Aug 22, 2019
cfc7d59
Merge branch 'cosmos/app-helpers' into cosmos/start-node
NicolasMahe Aug 22, 2019
d5d28e5
final result
NicolasMahe Aug 22, 2019
722de33
Update service sdk to include a interface and rename the current impl…
NicolasMahe Aug 22, 2019
f4b9e07
separate new sdk functions. update main.go init process
NicolasMahe Aug 22, 2019
9e726ec
Merge branch 'cosmos/start-node' into cosmos/service-sdk-step-2
NicolasMahe Aug 22, 2019
ea47bd2
Add service sdk new sdk and its module. update sdk
NicolasMahe Aug 22, 2019
c5d49f1
Update protobuf/types/workflow.proto
antho1404 Aug 23, 2019
57eff71
simplify edge validation
antho1404 Aug 23, 2019
9a93bc6
remove useless struct on top of LevelDB iterator
NicolasMahe Aug 23, 2019
560e1c5
use EdgesFrom function
antho1404 Aug 23, 2019
c1dca5a
add error when reference's node key not found
antho1404 Aug 23, 2019
a580750
Merge branch 'feature/workflow-data-resolver' of https://github.com/m…
antho1404 Aug 23, 2019
cbf5bdd
Merge pull request #1241 from mesg-foundation/feature/workflow-data-r…
antho1404 Aug 23, 2019
e71b027
Add comments to store packages
NicolasMahe Aug 23, 2019
58e5c95
Catch error not found of goleveldb and return nil instead
NicolasMahe Aug 23, 2019
b45e190
Merge branch 'dev' into cosmos/store
Aug 23, 2019
970e4e5
Add ErrNotFound in store
NicolasMahe Aug 23, 2019
0a18c8d
add graph struct
antho1404 Aug 23, 2019
78de0ee
update workflow with graph and extract filter
antho1404 Aug 23, 2019
659de21
use goleveldb has function
NicolasMahe Aug 23, 2019
19cd2a9
Merge pull request #1243 from mesg-foundation/cosmos/store
Aug 23, 2019
6ebba27
Merge branch 'dev' into cosmos/service-db
NicolasMahe Aug 23, 2019
1076a26
update workflow validation
antho1404 Aug 23, 2019
8a5c4b3
apply suggestions from code review and improve comments
NicolasMahe Aug 23, 2019
c34dbb3
apply suggestions from code review #2
NicolasMahe Aug 23, 2019
5a8fa64
fix start of cosmos app by adding cosmos modules
NicolasMahe Aug 23, 2019
a2f57ae
fix comment
NicolasMahe Aug 23, 2019
89b86f0
simplify access to trigger
antho1404 Aug 23, 2019
bd0a70a
Refactor database pacakge
krhubert Aug 23, 2019
f9f018e
Merge pull request #1254 from mesg-foundation/reafactor/db-rm-err-not…
Aug 23, 2019
3218062
Merge branch 'reafactor/db-rm-err-not-found' into cosmos/service-db
NicolasMahe Aug 23, 2019
245731f
Merge pull request #1244 from mesg-foundation/cosmos/service-db
Aug 23, 2019
16777f8
Merge commit 'dev' into cosmos/start-node
NicolasMahe Aug 23, 2019
5312a7e
Merge branch 'cosmos/app-helpers' into cosmos/start-node
NicolasMahe Aug 23, 2019
290a331
Merge branch 'dev' into cosmos/service-sdk-step-1
NicolasMahe Aug 23, 2019
33c3377
Create tendermint client
krhubert Aug 22, 2019
bd00075
Merge branch 'cosmos/service-sdk-step-1' into cosmos/service-sdk-step-2
NicolasMahe Aug 23, 2019
5924acb
Merge branch 'cosmos/start-node' into cosmos/service-sdk-step-2
NicolasMahe Aug 23, 2019
61a7fb8
Merge branch 'dev' into cosmos/app-helpers
Aug 23, 2019
3dfd9bd
Recover from panic in cosmos store
krhubert Aug 23, 2019
9927313
update proto definition
antho1404 Aug 23, 2019
fe2c788
update workflow type
antho1404 Aug 23, 2019
4fb43c5
update workflow validation
antho1404 Aug 23, 2019
94cb2bc
Merge pull request #1248 from mesg-foundation/cosmos/app-helpers
antho1404 Aug 23, 2019
89003c1
Merge branch 'dev' into cosmos/tmclient
antho1404 Aug 23, 2019
2a162d3
Merge branch 'dev' into cosmos/start-node
NicolasMahe Aug 24, 2019
5e026b1
Merge branch 'cosmos/start-node' into cosmos/service-sdk-step-2
NicolasMahe Aug 24, 2019
fd64642
start system service only in non-network mode
NicolasMahe Aug 24, 2019
0b3fd2a
fix workflow encoding/decoding
antho1404 Aug 24, 2019
c563310
Merge branch 'dev' into feature/cosmos-store
antho1404 Aug 24, 2019
35757e7
Merge pull request #1257 from mesg-foundation/feature/cosmos-store
antho1404 Aug 24, 2019
685fa6d
Merge branch 'dev' into cosmos/tmclient
antho1404 Aug 24, 2019
ad56036
Merge pull request #1255 from mesg-foundation/cosmos/tmclient
antho1404 Aug 24, 2019
be61880
Merge pull request #1249 from mesg-foundation/cosmos/start-node
Aug 26, 2019
4ed1bfd
Merge branch 'dev' into cosmos/service-sdk-step-2
Aug 26, 2019
7704de9
Merge branch 'dev' into cosmos/service-sdk-step-1
Aug 26, 2019
14092f8
Bump github.com/cosmos/cosmos-sdk from 0.36.0 to 0.37.0
dependabot-preview[bot] Aug 26, 2019
019e0b9
fix merge
NicolasMahe Aug 26, 2019
b68fcad
Merge pull request #1250 from mesg-foundation/cosmos/service-sdk-step-1
Aug 26, 2019
0a9c066
Merge branch 'dev' into dependabot/go_modules/github.com/cosmos/cosmo…
krhubert Aug 26, 2019
a007ae6
Merge commit 'b68fcadcaab26e12a6b967afc578a4057f13206c' into cosmos/s…
NicolasMahe Aug 26, 2019
d30c3f5
gofmt
antho1404 Aug 26, 2019
9b7212a
add event filtering
antho1404 Aug 26, 2019
fb99e19
update processing behavior
antho1404 Aug 26, 2019
c6ce018
add task processing
antho1404 Aug 26, 2019
b85ce2d
add mapping processing
antho1404 Aug 26, 2019
b31cc0e
remove single switch
antho1404 Aug 26, 2019
8a5cad8
remove useless error
antho1404 Aug 26, 2019
4293f93
reduce complexity of unmashal
antho1404 Aug 26, 2019
6b24828
rearrange node search
antho1404 Aug 26, 2019
a2ebfc0
Merge branch 'dev' into feature/workflow-pure-graph
antho1404 Aug 26, 2019
e342a25
code improvement
antho1404 Aug 27, 2019
0686f34
Merge pull request #1252 from mesg-foundation/cosmos/service-sdk-step-2
Aug 27, 2019
e4c8e6a
Install gogo protobuf in docker tools
krhubert Aug 27, 2019
8cd4832
Build service.proto with gogo protobuf
krhubert Aug 27, 2019
63722e9
Move service tags to proto type definition
krhubert Aug 27, 2019
d817583
Update service api proto import name
krhubert Aug 27, 2019
89b02b4
Add protobuf customtype interface to Hash type
krhubert Aug 27, 2019
bd21972
Regenerate service proto api and type
krhubert Aug 27, 2019
8859ad0
Remove previous Service struct
krhubert Aug 27, 2019
14c2998
Update go.mod
krhubert Aug 27, 2019
48129c7
Update source to use new service struct
krhubert Aug 27, 2019
ccbe5b4
Add missing comment
krhubert Aug 27, 2019
c324f24
rename mapping to map and reorganize proto
antho1404 Aug 28, 2019
2a382cf
simplify logic in the scheduler
antho1404 Aug 28, 2019
73da677
keep service dependency independent from service configuration
NicolasMahe Aug 28, 2019
8d95e57
use same protobuf number as the current api for service dependency
NicolasMahe Aug 28, 2019
eed99bc
Fix hash size method
krhubert Aug 28, 2019
cbc1785
Merge branch 'refactor/remove-custom-service-type-separate-service-de…
krhubert Aug 28, 2019
281dd92
Remove customtype from hash in proto definition of service
NicolasMahe Aug 28, 2019
a4cec63
Merge branch 'refactor/remove-custom-service-type-no-custom-type-hash…
krhubert Aug 28, 2019
70d7e04
Fix validation tags
krhubert Aug 28, 2019
3689a1f
Merge pull request #1260 from mesg-foundation/refactor/remove-custom-…
antho1404 Aug 28, 2019
964decb
Change service.proto package back to types
krhubert Aug 28, 2019
b1bd356
Make cosmos store iterator works the same way as goleveldb iterator
NicolasMahe Aug 28, 2019
bf61887
Merge pull request #1269 from mesg-foundation/refactor/remove-custom-…
Aug 28, 2019
8738868
Change proto hash type from string to bytes
krhubert Aug 28, 2019
9710255
Use hash.Hash type in service proto definition
krhubert Aug 29, 2019
54b4a7e
Merge branch 'dev' into feature/workflow-pure-graph
antho1404 Aug 29, 2019
6a0eac0
fix test due to hash modification
antho1404 Aug 29, 2019
bd440f1
Merge pull request #1258 from mesg-foundation/feature/workflow-pure-g…
antho1404 Aug 29, 2019
d0547e1
Fix lint
Aug 30, 2019
4517157
Merge branch 'dev' into fix/store-iterator
antho1404 Aug 30, 2019
888e2c0
Merge pull request #1268 from mesg-foundation/fix/store-iterator
antho1404 Aug 30, 2019
e283171
Merge pull request #1272 from mesg-foundation/refactor/servcie-proto-…
Aug 30, 2019
2fe1dbc
Marshal json hash to base58
krhubert Aug 30, 2019
dae744c
Merge branch 'dev' into refactor/hash-string-to-bytes
krhubert Aug 30, 2019
d1d5aa5
Fix merge errors
krhubert Aug 30, 2019
a80d90c
Merge pull request #1270 from mesg-foundation/refactor/hash-string-to…
Aug 30, 2019
09d151d
add filter support for the orchestrator
antho1404 Aug 30, 2019
14f8000
Merge pull request #1274 from mesg-foundation/feature/orchestrator-fi…
antho1404 Aug 30, 2019
84aa7ec
rename workflow to process
antho1404 Aug 30, 2019
2322606
gofmt
antho1404 Aug 30, 2019
7c1bb76
rename and rearange orchestrator
antho1404 Aug 30, 2019
1e67a57
golint and pluralized version of process
antho1404 Aug 30, 2019
c5d49f4
gofmt
antho1404 Aug 30, 2019
7f4f7dd
Merge pull request #1278 from mesg-foundation/feature/workflow-process-2
antho1404 Aug 30, 2019
a37b35d
add test for both cosmos store and leveldb store
NicolasMahe Aug 31, 2019
a107fdf
fix marshal issue with filter
antho1404 Sep 2, 2019
124836c
refactor unmarshal function
antho1404 Sep 2, 2019
e743798
add tests
antho1404 Sep 2, 2019
74acfd7
Merge pull request #1286 from mesg-foundation/bug/filter-marshaling
antho1404 Sep 2, 2019
88e913b
Fix that hash of info API were still in string instead of bytes.
NicolasMahe Sep 2, 2019
6df0d0f
Update system services to work on latest gRPC API
NicolasMahe Sep 2, 2019
0d2c570
Add test on index in iterator test of stores
NicolasMahe Sep 2, 2019
4df8104
Merge pull request #1287 from mesg-foundation/ss/update
antho1404 Sep 2, 2019
9876d36
Merge branch 'dev' into fix/ss-hash-grpc
antho1404 Sep 2, 2019
9cbd764
Merge pull request #1288 from mesg-foundation/fix/ss-hash-grpc
antho1404 Sep 2, 2019
738a44e
Merge branch 'dev' into test/stores
antho1404 Sep 2, 2019
13a6fc9
Merge pull request #1284 from mesg-foundation/test/stores
antho1404 Sep 2, 2019
f296128
Use gogo protobuf
krhubert Sep 2, 2019
2a9dc37
Regenerate protobuf file
krhubert Sep 2, 2019
c2c40fc
Fix tests and lint
krhubert Sep 2, 2019
a26df8e
Customize protobuf messages
krhubert Sep 2, 2019
11cebb6
Regenerate protobuf apis and types
krhubert Sep 2, 2019
38ec3e1
Set nullabe to false for service configuration
krhubert Sep 2, 2019
ed4ba11
Replace instance struct with protobuf
krhubert Sep 2, 2019
b2dfe07
Merge pull request #1290 from mesg-foundation/feature/use-gogo-protobuf
Sep 3, 2019
8c6d618
Merge branch 'dev' into feature/use-hash
Sep 3, 2019
b6ec56e
Merge pull request #1291 from mesg-foundation/feature/use-hash
Sep 3, 2019
263dfd8
Merge pull request #1292 from mesg-foundation/fix/nullable-configuration
Sep 3, 2019
f576ae3
Merge pull request #1293 from mesg-foundation/refactor/remove-instance
Sep 3, 2019
a292681
Remove old generated instance struct
NicolasMahe Sep 3, 2019
2b9b3db
Add explicit marshal and unmarshal function to service db to be compa…
NicolasMahe Sep 3, 2019
3579669
Merge pull request #1295 from mesg-foundation/fix/remove-old-instance-pb
Sep 3, 2019
cd3c3bc
Merge branch 'dev' into cosmos/database-service-deprecated
Sep 3, 2019
372b4e1
Create a cosmos app factory struct. Start to rename sdk module to bac…
NicolasMahe Sep 3, 2019
75b6559
Improve a bit cdc dependency
NicolasMahe Sep 3, 2019
23a72fc
Remove and refactor rest protobuf types
krhubert Sep 3, 2019
535af34
Prepare cosmos client
NicolasMahe Sep 4, 2019
05efa4f
Remove deprecated new function in service db
NicolasMahe Sep 4, 2019
17e959d
Merge branch 'dev' into refactor/drop-rest-custom-types
Sep 4, 2019
26de5dd
Replace cnf structhash with custom one
krhubert Sep 3, 2019
c275a29
Merge pull request #1296 from mesg-foundation/refactor/drop-rest-cust…
krhubert Sep 4, 2019
584700f
Merge branch 'dev' into feature/new-structhash
krhubert Sep 4, 2019
1a9a273
Fix comments for linter
krhubert Sep 4, 2019
3c631e8
Merge pull request #1298 from mesg-foundation/feature/new-structhash
krhubert Sep 4, 2019
f7c1eb4
Merge branch 'dev' into cosmos/database-service-deprecated
krhubert Sep 4, 2019
5405ddb
Merge branch 'dev' into cosmos/cosmos-client
krhubert Sep 4, 2019
569b5c4
Merge pull request #1297 from mesg-foundation/cosmos/database-service…
krhubert Sep 4, 2019
7c127bd
Merge branch 'dev' into cosmos/cosmos-client
krhubert Sep 4, 2019
8320445
Merge pull request #1300 from mesg-foundation/cosmos/cosmos-client
krhubert Sep 4, 2019
9cb9c15
Bump github.com/tendermint/tendermint from 0.32.2 to 0.32.3
dependabot-preview[bot] Sep 4, 2019
374e22f
Bump github.com/gogo/protobuf from 1.2.1 to 1.3.0
dependabot-preview[bot] Sep 4, 2019
2611dc9
update database path to ensure no issue on startup
antho1404 Sep 4, 2019
b425add
Merge pull request #1301 from mesg-foundation/feature/update-db
antho1404 Sep 4, 2019
c01a299
Merge branch 'dev' into cosmos/app-factory
NicolasMahe Sep 4, 2019
2d7f794
Merge branch 'dev' into cosmos/app-factory
krhubert Sep 4, 2019
d4df111
Merge pull request #1299 from mesg-foundation/cosmos/app-factory
krhubert Sep 4, 2019
a14ab2e
Merge branch 'dev' into dependabot/go_modules/github.com/cosmos/cosmo…
krhubert Sep 4, 2019
4c54f79
Merge branch 'dev' into dependabot/go_modules/github.com/gogo/protobu…
krhubert Sep 4, 2019
e306e20
Merge branch 'dev' into dependabot/go_modules/github.com/tendermint/t…
krhubert Sep 4, 2019
9049ca7
Merge pull request #1245 from mesg-foundation/dependabot/go_modules/g…
krhubert Sep 4, 2019
092541a
Merge branch 'dev' into dependabot/go_modules/github.com/gogo/protobu…
krhubert Sep 4, 2019
11cb3bc
Merge pull request #1285 from mesg-foundation/dependabot/go_modules/g…
krhubert Sep 4, 2019
c6af963
Merge pull request #1271 from mesg-foundation/dependabot/go_modules/g…
Sep 4, 2019
ddca6ed
update changelog script to match new labels
NicolasMahe Sep 4, 2019
2a6511a
generate changelog for v0.14.0
NicolasMahe Sep 4, 2019
676a20d
Update gogo protobuf with fixed json and custom tags generation
krhubert Sep 5, 2019
0211b79
Generate equal method for process
krhubert Sep 6, 2019
b02ed1f
Change process database marshal to proto
krhubert Sep 6, 2019
482c439
Remove custom json marshaler from proto
krhubert Sep 6, 2019
eb1060f
Merge pull request #1310 from mesg-foundation/fix/process-protobuf
antho1404 Sep 6, 2019
f49b811
Merge branch 'dev' into fix/process-db-marshal
antho1404 Sep 6, 2019
a2ad965
Merge pull request #1311 from mesg-foundation/fix/process-db-marshal
antho1404 Sep 6, 2019
8aa3282
fix issue with execution update
antho1404 Sep 6, 2019
50f9bed
add equal function and fix test
antho1404 Sep 6, 2019
03ac602
Merge pull request #1312 from mesg-foundation/bug/execution-serializing
Sep 6, 2019
b61f53c
Merge branch 'dev' into changelog/v0.14.0
NicolasMahe Sep 6, 2019
b907226
update changelog
NicolasMahe Sep 6, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,58 @@
#### Removed
#### Experimental

## [v0.14.0](https://github.com/mesg-foundation/engine/releases/tag/v0.14.0)

#### Breaking Changes

- ([#1258](https://github.com/mesg-foundation/engine/pull/1258)) Pure graph implementation for the orchestration system.
- ([#1278](https://github.com/mesg-foundation/engine/pull/1278)) Rename workflow to process.
- ([#1290](https://github.com/mesg-foundation/engine/pull/1290)) Use gogo protobuf.
- ([#1292](https://github.com/mesg-foundation/engine/pull/1292)) Set nullabe to false for service configuration.
- ([#1301](https://github.com/mesg-foundation/engine/pull/1301)) Update database path to ensure no issue on startup.

#### Added

- ([#1241](https://github.com/mesg-foundation/engine/pull/1241)) Process input resolution.

#### Changed

- ([#1254](https://github.com/mesg-foundation/engine/pull/1254)) Remove database ErrNotFound. Introduce Database Exist function.
- ([#1260](https://github.com/mesg-foundation/engine/pull/1260)) Keep only one Service struct (the one generated from protobuf definition).
- ([#1264](https://github.com/mesg-foundation/engine/pull/1264)) Refactor/remove custom service type no custom type hash.
- ([#1269](https://github.com/mesg-foundation/engine/pull/1269)) Change service.proto package back to types.
- ([#1270](https://github.com/mesg-foundation/engine/pull/1270)) Change proto hash type from string to bytes.
- ([#1285](https://github.com/mesg-foundation/engine/pull/1285)) Bump github.com/gogo/protobuf from 1.2.1 to 1.3.0.
- ([#1286](https://github.com/mesg-foundation/engine/pull/1286)) Fix marshal issue with process filter.
- ([#1287](https://github.com/mesg-foundation/engine/pull/1287)) Update system services to work with latest gRPC API.
- ([#1288](https://github.com/mesg-foundation/engine/pull/1288)) Fix that hash of info API were still in string instead of bytes.
- ([#1291](https://github.com/mesg-foundation/engine/pull/1291)) Customize protobuf messages .
- ([#1293](https://github.com/mesg-foundation/engine/pull/1293)) Replace instance struct with protobuf.
- ([#1295](https://github.com/mesg-foundation/engine/pull/1295)) Remove old generated instance struct.
- ([#1296](https://github.com/mesg-foundation/engine/pull/1296)) Remove and refactor rest protobuf types.
- ([#1298](https://github.com/mesg-foundation/engine/pull/1298)) Replace cnf structhash with custom one.
- ([#1310](https://github.com/mesg-foundation/engine/pull/1310)) Update gogo protobuf with fixed json and custom tags generation.
- ([#1311](https://github.com/mesg-foundation/engine/pull/1311)) Use protobuf marshal/unmarshal in process database.
- ([#1312](https://github.com/mesg-foundation/engine/pull/1312)) Use protobuf marshal/unmarshal in execution database.

#### Experimental

- ([#1243](https://github.com/mesg-foundation/engine/pull/1243)) Add store package.
- ([#1244](https://github.com/mesg-foundation/engine/pull/1244)) Update service db to use store.
- ([#1245](https://github.com/mesg-foundation/engine/pull/1245)) Bump github.com/cosmos/cosmos-sdk from 0.36.0 to 0.37.0.
- ([#1248](https://github.com/mesg-foundation/engine/pull/1248)) Add Cosmos helpers.
- ([#1249](https://github.com/mesg-foundation/engine/pull/1249)) SDK loads the App modules.
- ([#1250](https://github.com/mesg-foundation/engine/pull/1250)) Transform service sdk to accept cosmos service step 1.
- ([#1252](https://github.com/mesg-foundation/engine/pull/1252)) Add service sdk cosmos version step 2.
- ([#1255](https://github.com/mesg-foundation/engine/pull/1255)) Create tendermint client.
- ([#1257](https://github.com/mesg-foundation/engine/pull/1257)) Recover from panic in cosmos store.
- ([#1268](https://github.com/mesg-foundation/engine/pull/1268)) Make cosmos store iterator works the same way as goleveldb iterator.
- ([#1271](https://github.com/mesg-foundation/engine/pull/1271)) Bump github.com/tendermint/tendermint from 0.32.2 to 0.32.3.
- ([#1284](https://github.com/mesg-foundation/engine/pull/1284)) Add test for both cosmos store and leveldb store.
- ([#1297](https://github.com/mesg-foundation/engine/pull/1297)) Add explicit marshal and unmarshal function to service db.
- ([#1299](https://github.com/mesg-foundation/engine/pull/1299)) Create a cosmos app factory struct.
- ([#1300](https://github.com/mesg-foundation/engine/pull/1300)) Prepare cosmos client.

## [v0.13.0](https://github.com/mesg-foundation/engine/releases/tag/v0.13.0)

#### Added
Expand Down
17 changes: 15 additions & 2 deletions Dockerfile.tools
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,28 @@ RUN apt-get update -y && \
rm -rf /var/lib/apt/lists/*

# protobuf(protoc) version.
ARG protobuf=3.8.0
ARG protobuf=3.9.1
ARG gogoprotobuf=1.3.0

# install protobuf(protoc).
RUN wget -q https://github.com/protocolbuffers/protobuf/releases/download/v$protobuf/protoc-$protobuf-linux-x86_64.zip -O /tmp/protobuf.zip && \
mkdir /tmp/protobuf && \
unzip /tmp/protobuf.zip -d /tmp/protobuf && \
mv /tmp/protobuf/bin/* /usr/local/bin/ && \
mv /tmp/protobuf/include/* /usr/local/include/ && \
rm -rf /tmp/*
rm -rf /tmp/protobuf

RUN cd /tmp/ && \
git clone https://github.com/krhubert/protobuf.git && \
cd protobuf && \
make install && \
mkdir -p /usr/local/include/gogo/protobuf/ && \
cp gogoproto/gogo.proto /usr/local/include/gogo/protobuf/

# download gogo proto files
RUN mkdir -p /usr/local/include/gogo/protobuf/ && \
wget -qO- https://github.com/gogo/protobuf/archive/v${gogoprotobuf}.tar.gz | tar -xzf - protobuf-${gogoprotobuf}/gogoproto/gogo.proto && \
mv protobuf-${gogoprotobuf}/gogoproto /usr/local/include/gogo/protobuf/

RUN go install github.com/go-bindata/go-bindata/go-bindata
RUN go install github.com/golang/protobuf/protoc-gen-go
Expand Down
12 changes: 6 additions & 6 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ import (
const (
envPrefix = "mesg"

serviceDBVersion = "v3"
executionDBVersion = "v2"
instanceDBVersion = "v1"
workflowDBVersion = "v1"
serviceDBVersion = "v4"
executionDBVersion = "v3"
instanceDBVersion = "v2"
processDBVersion = "v2"
)

var (
Expand All @@ -49,7 +49,7 @@ type Config struct {
ServiceRelativePath string
InstanceRelativePath string
ExecutionRelativePath string
WorkflowRelativePath string
ProcessRelativePath string
}

Tendermint struct {
Expand Down Expand Up @@ -95,7 +95,7 @@ func New() (*Config, error) {
c.Database.ServiceRelativePath = filepath.Join("database", "services", serviceDBVersion)
c.Database.InstanceRelativePath = filepath.Join("database", "instance", instanceDBVersion)
c.Database.ExecutionRelativePath = filepath.Join("database", "executions", executionDBVersion)
c.Database.WorkflowRelativePath = filepath.Join("database", "workflows", workflowDBVersion)
c.Database.ProcessRelativePath = filepath.Join("database", "processes", processDBVersion)

c.Tendermint.Config = tmconfig.DefaultConfig()
c.Tendermint.Config.P2P.AddrBookStrict = false
Expand Down
129 changes: 74 additions & 55 deletions core/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,83 +6,60 @@ import (
"strconv"
"sync"

"github.com/cosmos/cosmos-sdk/codec"
"github.com/mesg-foundation/engine/config"
"github.com/mesg-foundation/engine/container"
"github.com/mesg-foundation/engine/cosmos"
"github.com/mesg-foundation/engine/database"
"github.com/mesg-foundation/engine/database/store"
"github.com/mesg-foundation/engine/hash"
"github.com/mesg-foundation/engine/logger"
"github.com/mesg-foundation/engine/scheduler"
"github.com/mesg-foundation/engine/sdk"
"github.com/mesg-foundation/engine/orchestrator"
enginesdk "github.com/mesg-foundation/engine/sdk"
instancesdk "github.com/mesg-foundation/engine/sdk/instance"
servicesdk "github.com/mesg-foundation/engine/sdk/service"
"github.com/mesg-foundation/engine/server/grpc"
"github.com/mesg-foundation/engine/tendermint"
"github.com/mesg-foundation/engine/version"
"github.com/mesg-foundation/engine/x/xerrors"
"github.com/mesg-foundation/engine/x/xnet"
"github.com/mesg-foundation/engine/x/xos"
"github.com/mesg-foundation/engine/x/xsignal"
"github.com/sirupsen/logrus"
db "github.com/tendermint/tm-db"
)

var network = flag.Bool("experimental-network", false, "start the engine with the network")

type dependencies struct {
cfg *config.Config
serviceDB database.ServiceDB
executionDB database.ExecutionDB
workflowDB database.WorkflowDB
container container.Container
sdk *sdk.SDK
}

func initDependencies(cfg *config.Config) (*dependencies, error) {
func initDatabases(cfg *config.Config) (*database.ServiceDB, *database.LevelDBInstanceDB, *database.LevelDBExecutionDB, *database.LevelDBProcessDB, error) {
// init services db.
serviceDB, err := database.NewServiceDB(filepath.Join(cfg.Path, cfg.Database.ServiceRelativePath))
serviceStore, err := store.NewLevelDBStore(filepath.Join(cfg.Path, cfg.Database.ServiceRelativePath))
if err != nil {
return nil, err
return nil, nil, nil, nil, err
}
serviceDB := database.NewServiceDB(serviceStore, codec.New())

// init instance db.
instanceDB, err := database.NewInstanceDB(filepath.Join(cfg.Path, cfg.Database.InstanceRelativePath))
if err != nil {
return nil, err
return nil, nil, nil, nil, err
}

// init execution db.
executionDB, err := database.NewExecutionDB(filepath.Join(cfg.Path, cfg.Database.ExecutionRelativePath))
if err != nil {
return nil, err
return nil, nil, nil, nil, err
}

// init workflow db.
workflowDB, err := database.NewWorkflowDB(filepath.Join(cfg.Path, cfg.Database.WorkflowRelativePath))
// init process db.
processDB, err := database.NewProcessDB(filepath.Join(cfg.Path, cfg.Database.ProcessRelativePath))
if err != nil {
return nil, err
return nil, nil, nil, nil, err
}

// init container.
c, err := container.New(cfg.Name)
if err != nil {
return nil, err
}

_, port, _ := xnet.SplitHostPort(cfg.Server.Address)

// init sdk.
sdk := sdk.New(c, serviceDB, instanceDB, executionDB, workflowDB, cfg.Name, strconv.Itoa(port))

return &dependencies{
cfg: cfg,
container: c,
serviceDB: serviceDB,
executionDB: executionDB,
workflowDB: workflowDB,
sdk: sdk,
}, nil
return serviceDB, instanceDB, executionDB, processDB, nil
}

func deployCoreServices(cfg *config.Config, sdk *sdk.SDK) error {
func deployCoreServices(cfg *config.Config, sdk *enginesdk.SDK) error {
for _, serviceConfig := range cfg.SystemServices {
logrus.WithField("module", "main").Infof("Deploying service %q", serviceConfig.Definition.Sid)
srv, err := sdk.Service.Create(serviceConfig.Definition)
Expand All @@ -97,7 +74,7 @@ func deployCoreServices(cfg *config.Config, sdk *sdk.SDK) error {
return err
}
}
logrus.WithField("module", "main").Infof("Service %q deployed with hash %q", srv.Sid, srv.Hash)
logrus.WithField("module", "main").Infof("Service %q deployed with hash %q", srv.Sid, srv.Hash.String())
instance, err := sdk.Instance.Create(srv.Hash, xos.EnvMapToSlice(serviceConfig.Env))
if err != nil {
existsError, ok := err.(*instancesdk.AlreadyExistsError)
Expand All @@ -116,7 +93,7 @@ func deployCoreServices(cfg *config.Config, sdk *sdk.SDK) error {
return nil
}

func stopRunningServices(sdk *sdk.SDK) error {
func stopRunningServices(sdk *enginesdk.SDK) error {
instances, err := sdk.Instance.List(&instancesdk.Filter{})
if err != nil {
return err
Expand Down Expand Up @@ -152,33 +129,75 @@ func main() {
logrus.Fatalln(err)
}

dep, err := initDependencies(cfg)
// init logger.
logger.Init(cfg.Log.Format, cfg.Log.Level, cfg.Log.ForceColors)

// init databases
serviceDB, instanceDB, executionDB, processDB, err := initDatabases(cfg)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// init container.
c, err := container.New(cfg.Name)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// init logger.
logger.Init(cfg.Log.Format, cfg.Log.Level, cfg.Log.ForceColors)
_, port, _ := xnet.SplitHostPort(cfg.Server.Address)

var sdk *enginesdk.SDK
if *network {
// create tendermint node
node, err := tendermint.NewNode(cfg.Tendermint.Config, &cfg.Cosmos)
// init app factory
db, err := db.NewGoLevelDB("app", cfg.Cosmos.Path)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}
appFactory := cosmos.NewAppFactory(logger.TendermintLogger(), db)

// register the backend modules to the app factory.
enginesdk.NewBackend(appFactory, c)

// init cosmos app
app, err := cosmos.NewApp(appFactory)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// init key manager
kb, err := cosmos.NewKeybase(cfg.Cosmos.Path)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// create cosmos node
node, err := cosmos.NewNode(app, kb, cfg.Tendermint.Config, &cfg.Cosmos)
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// init sdk
sdk, err = enginesdk.New(c, instanceDB, executionDB, processDB, cfg.Name, strconv.Itoa(port))
if err != nil {
logrus.WithField("module", "main").Fatalln(err)
}

// start tendermint node
logrus.WithField("module", "main").WithField("seeds", cfg.Tendermint.P2P.Seeds).Info("starting tendermint node")
if err := node.Start(); err != nil {
logrus.WithField("module", "main").Fatalln(err)
}
}
} else {
sdk = enginesdk.NewDeprecated(c, serviceDB, instanceDB, executionDB, processDB, cfg.Name, strconv.Itoa(port))

// init system services.
if err := deployCoreServices(dep.cfg, dep.sdk); err != nil {
logrus.WithField("module", "main").Fatalln(err)
// init system services.
if err := deployCoreServices(cfg, sdk); err != nil {
logrus.WithField("module", "main").Fatalln(err)
}
}

// init gRPC server.
server := grpc.New(dep.sdk)
server := grpc.New(sdk)

logrus.WithField("module", "main").Infof("starting MESG Engine version %s", version.Version)

Expand All @@ -188,8 +207,8 @@ func main() {
}
}()

logrus.WithField("module", "main").Info("starting workflow engine")
s := scheduler.New(dep.sdk.Event, dep.sdk.Execution, dep.sdk.Workflow)
logrus.WithField("module", "main").Info("starting process engine")
s := orchestrator.New(sdk.Event, sdk.Execution, sdk.Process)
go func() {
if err := s.Start(); err != nil {
logrus.WithField("module", "main").Fatalln(err)
Expand All @@ -202,7 +221,7 @@ func main() {
}()

<-xsignal.WaitForInterrupt()
if err := stopRunningServices(dep.sdk); err != nil {
if err := stopRunningServices(sdk); err != nil {
logrus.WithField("module", "main").Fatalln(err)
}
server.Close()
Expand Down
Loading