rails-disco 0.3.0 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -5
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9c356acc16ba120871b75d4c377d9fb3d430b0c8
|
4
|
+
data.tar.gz: 0ad6d0a93c6887b485e238ee85fa6d2ece35a74e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0bda6600252cda2a114c555a5be900886d5b4d77541b6427e70908e6053174dd031f5806dddcf31686b87c09da4839c6a3d323cab3f9ecdb5ee573dba1bbc202
|
7
|
+
data.tar.gz: 0d17cf63d0841da29a53e9bb1dd73fd5dac2f57c873389449df09805fe31d246dce20ab0251b9bb8029dee8a949f2e6dc53c4a5cc4fd0176e422b20d25432d79
|
data/README.md
CHANGED
@@ -20,7 +20,7 @@ Finally _projections_ are your representation of your data, they get the events
|
|
20
20
|
|
21
21
|
* Because Rails Disco relies on [bunny](https://github.com/ruby-amqp/bunny) for sending the events from the domain to the projection, you need [RabbitMQ](http://www.rabbitmq.com/download.html) on your system.
|
22
22
|
|
23
|
-
* Any Server which is capable of streaming, e.g. puma or thin
|
23
|
+
* Any Server which is capable of streaming, e.g. puma or thin (Standard Rails Server Webrick will **not** work). If you are facing problems installing puma on windows, here is a [tutorial](https://github.com/hicknhack-software/rails-disco/wiki/Installing-puma-on-windows).
|
24
24
|
|
25
25
|
# Getting Started
|
26
26
|
|
@@ -30,6 +30,7 @@ Finally _projections_ are your representation of your data, they get the events
|
|
30
30
|
|
31
31
|
gem install rails-disco
|
32
32
|
|
33
|
+
|
33
34
|
3. At the command prompt, create a new Rails Disco application.
|
34
35
|
|
35
36
|
drails new myapp
|
@@ -41,7 +42,7 @@ Finally _projections_ are your representation of your data, they get the events
|
|
41
42
|
4. Change directory to `myapp`, if you haven't yet and migrate the databases:
|
42
43
|
|
43
44
|
cd myapp
|
44
|
-
|
45
|
+
rake drails:db:setup
|
45
46
|
|
46
47
|
This will create the two databases domain and projection (for database details look in config/disco.yml)
|
47
48
|
|
@@ -59,14 +60,16 @@ Finally _projections_ are your representation of your data, they get the events
|
|
59
60
|
|
60
61
|
7. Before we can start, we need to tell rails that we have some shiny new db. Open up config/database.yml and edit the config for your environment (propably development) to the projection database. So basically:
|
61
62
|
|
62
|
-
|
63
|
-
|
63
|
+
```diff
|
64
|
+
- database: db/development.sqlite3
|
65
|
+
+ database: db/projection_dev.sqlite3
|
66
|
+
```
|
64
67
|
|
65
68
|
8. Now that we have something to rely on, lets see it in action:
|
66
69
|
|
67
70
|
drails server
|
68
71
|
|
69
|
-
9. Go to http://localhost:3000/posts and you'll see an empty list of our posts with a link to create a new one. Go ahead and create one. If you watch the console output, you can see that an event will be created for the creating of the post and will be published to the projection.
|
72
|
+
9. Go to [http://localhost:3000/posts](http://localhost:3000/posts) and you'll see an empty list of our posts with a link to create a new one. Go ahead and create one. If you watch the console output, you can see that an event will be created for the creating of the post and will be published to the projection.
|
70
73
|
|
71
74
|
10. If you look at your databases, you see in both of them a table `posts`, which contains your freshly created post. The domain database also contains a table `domain_events`. There you find an event for your post creation. Lets see this in action.
|
72
75
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails-disco
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Robert Kranz
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-11-21 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: drailties
|
@@ -17,14 +17,14 @@ dependencies:
|
|
17
17
|
requirements:
|
18
18
|
- - '='
|
19
19
|
- !ruby/object:Gem::Version
|
20
|
-
version: 0.
|
20
|
+
version: 0.4.1
|
21
21
|
type: :runtime
|
22
22
|
prerelease: false
|
23
23
|
version_requirements: !ruby/object:Gem::Requirement
|
24
24
|
requirements:
|
25
25
|
- - '='
|
26
26
|
- !ruby/object:Gem::Version
|
27
|
-
version: 0.
|
27
|
+
version: 0.4.1
|
28
28
|
description: Rails Disco is a framework on top of the rails framework to provide cqrs
|
29
29
|
and simple event sourcing possibilities to rails.
|
30
30
|
email: rails-disco@hicknhack-software.com
|