klastera 1.4.1 → 1.4.4.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f45dc24f8870c8dc07dc2e7702f6021b66b5c71b97529ca4aece12ce47399348
4
- data.tar.gz: 1c8673aaef5fb0d562376e80cdf787e302601672e4a4285066f3be4da04fb925
3
+ metadata.gz: 775712865aa542b64dd8fff79f0051ee39ed45c9db8153e63639c897b44f406c
4
+ data.tar.gz: '0328c25a8ad44e5cacec26c77d4d703d129adc493c205b300387cc8ff83e1ff7'
5
5
  SHA512:
6
- metadata.gz: c59493dadf8ac3a4b52a235f3a4f96c52cef9668ec215bf9f857bad90c72241ad8564fe11c86f3a212587fba37440c87230487ce10da9bdd09519be907a433ca
7
- data.tar.gz: 838347a85ffdfb1144dad6cf83094ff11fa9a8d78398e70f382a65e51df31d80bc557b3022175e7d13a8ddcbd88567f5c8af1b8a7ca6056194f475ed5d57b12d
6
+ metadata.gz: f4ad8a8c3a8d6cdf00aa92d7dcaf04317462aa023c9e59640d15f57a555e049f44276e1bd93237e9ee8a2600ac7e0585058c626ef79a34a3bd2673e8e3ef9451
7
+ data.tar.gz: 9be95730d3ce71ac9f8ed73b5b6ea5ed1d3ba384b05cba2a52ca926518ddc261c164fabcefc3c67c15d08d92c97c098f22f6e10d095b691dafc90f7c613079ae
@@ -8,5 +8,11 @@ module Klastera::Concerns::ClusterEntity
8
8
  end
9
9
 
10
10
  module ClassMethods
11
+ def left_join_sources_of(scope_klass)
12
+ scope_klass_arel_table = scope_klass.arel_table
13
+ scope_klass_arel_table.join(arel_table, Arel::Nodes::OuterJoin).on(
14
+ scope_klass_arel_table[:id].eq(arel_table[:entity_id]), arel_table[:entity_type].eq(scope_klass.name)
15
+ ).join_sources
16
+ end
11
17
  end
12
18
  end
@@ -1,13 +1,16 @@
1
1
  module Klastera::Concerns::Clusterizable
2
2
  extend ActiveSupport::Concern
3
+
3
4
  included do
5
+ class MutipleClustersOperationError < StandardError; end
6
+
4
7
  belongs_to :cluster
5
8
 
6
9
  has_many :cluster_entities, as: :entity, class_name: Klastera::ClusterEntity
7
10
  accepts_nested_attributes_for :cluster_entities, reject_if: :all_blank, allow_destroy: true
8
11
 
9
- validates :cluster_id, presence: true, if: proc { self.try(:cluster_id) && self.organization.required_suborganization_mode? }
10
- validate :at_least_one_cluster_entity, if: proc { self.organization.required_suborganization_mode? }
12
+ validates :cluster_id, presence: true, if: -> { cluster_id.present? && organization.present? && organization.required_suborganization_mode? }
13
+ validate :at_least_one_cluster_entity, if: -> { organization.present? && organization.required_suborganization_mode? }
11
14
  validate :uniqueness_of_cluster_entity_record
12
15
 
13
16
  scope :includes_cluster, -> { includes(cluster_entities: :cluster) }
@@ -18,6 +21,10 @@ module Klastera::Concerns::Clusterizable
18
21
  end
19
22
  end
20
23
 
24
+ def allow_multiple_clusters?(default=:one)
25
+ organization.present? && organization.cluster_cardinality_of(self.class, default: default) == :many
26
+ end
27
+
21
28
  ##
22
29
  # This is a legacy method and we don't recommend using it.
23
30
  # Implement directly Klastera.entity_clusters_string_list instead of this method.
@@ -25,7 +32,7 @@ module Klastera::Concerns::Clusterizable
25
32
  ##
26
33
  def clusters_string_separated_by(separator,attribute=:name)
27
34
  Klastera.entity_clusters_string_list!(
28
- self.cluster_entities, separator, attribute
35
+ cluster_entities, separator, attribute
29
36
  )
30
37
  end
31
38
 
@@ -1,7 +1,7 @@
1
1
  module Klastera::Concerns::Organization
2
2
  extend ActiveSupport::Concern
3
3
  included do
4
-
4
+ serialize :cluster_config
5
5
  has_many :clusters
6
6
 
7
7
  validates :use_cluster_as, inclusion: { in: ::Cluster::MODES.map{|m|m.to_s}, message: I18n.t('klastera.clusters.wrong_option') }, if: proc{ use_cluster_as.present? }
@@ -11,6 +11,17 @@ module Klastera::Concerns::Organization
11
11
  self.use_cluster_as.to_s.to_sym
12
12
  end
13
13
 
14
+ def cluster_cardinality_of(entity, default: :many)
15
+ if cluster_config.is_a?(Hash)
16
+ entities_cardinality = cluster_config[:entities]&.[](:cardinality)||{}
17
+ entity = entity.to_s.to_sym
18
+ if entities_cardinality.has_key?(entity)
19
+ default = entities_cardinality[entity]
20
+ end
21
+ end
22
+ default.to_s.to_sym
23
+ end
24
+
14
25
  ##
15
26
  # Return a boolean if one of three of options was set in organization
16
27
  # As useless option you can retrieve the value passing false as argument.
@@ -11,29 +11,29 @@ module Klastera::Concerns::User
11
11
 
12
12
  has_many :cluster_users, inverse_of: :user, class_name: ::ClusterUser.to_s
13
13
  accepts_nested_attributes_for :cluster_users, reject_if: :all_blank, allow_destroy: true
14
- validates :cluster_role, presence: true, if: proc{ self.organization.is_in_cluster_mode? }
15
- validates :cluster_role, inclusion: { in: CLUSTER_ROLES , message: I18n.t('klastera.clusters.wrong_option') }, if: proc{ cluster_role.present? }
16
- validate :at_least_one_role, if: proc{ self.use_cluster? && self.try(:need_cluster_assignation?) }
14
+ validates :cluster_role, presence: true, if: -> { organization.present? && organization.is_in_cluster_mode? }
15
+ validates :cluster_role, inclusion: { in: CLUSTER_ROLES , message: I18n.t('klastera.clusters.wrong_option') }, if: -> { cluster_role.present? }
16
+ validate :at_least_one_role, if: -> { use_cluster? && try(:need_cluster_assignation?) }
17
17
 
18
- def use_cluster?; self.cluster_role.present?; end
18
+ def use_cluster?; cluster_role.present?; end
19
19
 
20
- def is_a_cluster_root?; self.cluster_role == CLUSTER_ROOT; end
21
- def is_a_cluster_admin?; self.cluster_role == CLUSTER_ADMIN; end
22
- def is_a_cluster_user?; self.cluster_role == CLUSTER_USER; end
20
+ def is_a_cluster_root?; cluster_role == CLUSTER_ROOT; end
21
+ def is_a_cluster_admin?; cluster_role == CLUSTER_ADMIN; end
22
+ def is_a_cluster_user?; cluster_role == CLUSTER_USER; end
23
23
 
24
24
  def need_cluster_assignation?
25
- self.try(:organization).try(:required_suborganization_mode?) && self.is_a_cluster_user?
25
+ organization.present? && organization.required_suborganization_mode? && is_a_cluster_user?
26
26
  end
27
27
 
28
28
  def can_admin_clusters?
29
- self.organization.is_in_cluster_mode? && ( self.is_a_cluster_admin? || self.is_a_cluster_root? )
29
+ organization.present? && organization.is_in_cluster_mode? && ( is_a_cluster_admin? || is_a_cluster_root? )
30
30
  end
31
31
 
32
32
  #
33
33
  # It tells if this user should see what they cluster role or organization dictates
34
34
  # Adminers and users from show cluster modes skip cluster clause
35
35
  def cannot_skip_cluster_clause?
36
- ! ( self.is_a_cluster_admin? || self.is_a_cluster_root? || ( self.organization.optional_suborganization_mode? && self.cluster_users.blank? ) )
36
+ ! ( is_a_cluster_admin? || is_a_cluster_root? || ( organization.present? && organization.optional_suborganization_mode? && cluster_users.blank? ) )
37
37
  end
38
38
 
39
39
  #
@@ -43,9 +43,9 @@ module Klastera::Concerns::User
43
43
  # cluster_id is present (on show/use mode organizations).
44
44
  #
45
45
  def try_to_clusterify!(role,cluster_ids)
46
- if self.try(:organization).try(:is_in_cluster_mode?)
46
+ if organization.present? && organization.is_in_cluster_mode?
47
47
  self.cluster_role = role
48
- if self.try(:organization).try(:required_suborganization_mode?) || cluster_ids.present?
48
+ if ( organization.present? && organization.required_suborganization_mode? ) || cluster_ids.present?
49
49
  timestamp = DateTime.now.to_i
50
50
  nested_attributes = {}
51
51
  cluster_ids.each do |cluster_id|
@@ -1,6 +1,6 @@
1
1
  <tr class="nested-fields">
2
2
  <td class="field">
3
- <%= f.select :cluster_id, @clusters_session.map{|c|[c.name,c.id]}, { include_blank: true }, { class: 'form-control' } %>
3
+ <%= f.select :cluster_id, @clusters_session.order(:order,:name).map{|c|[c.name,c.id]}, { include_blank: true }, { class: 'form-control' } %>
4
4
  </td>
5
5
  <td class="action vertical-align-middle text-center" width="44">
6
6
  <%= link_to_remove_association f, class: 'btn btn-danger btn-xs text-danger' do %>
@@ -7,7 +7,7 @@
7
7
  <%=yield(f) if block_given? %>
8
8
 
9
9
  <% if cluster_organization.is_in_cluster_mode? %>
10
- <% cluster_collection = cluster_list.map{|c|[c.name,(c.id||c.nid)]} %>
10
+ <% cluster_collection = cluster_list.order(:order, :name).map{|c|[c.name,(c.id||c.nid)]} %>
11
11
  <% if cluster_collection.size > 1 %>
12
12
  <div class="inline-label-control-block">
13
13
  <%= f.input :cluster_id, collection: cluster_collection, prompt: t('klastera.clusters.all'), label: false, wrapper: false %>
@@ -1,6 +1,6 @@
1
1
  <tr class="nested-fields">
2
2
  <td class="field">
3
- <%= f.select :cluster_id, @user.organization.clusters.map{|c|[c.name,c.id]}, { include_blank: true }, { class: 'form-control' } %>
3
+ <%= f.select :cluster_id, @user.organization.clusters.order(:order, :name).map{|c|[c.name,c.id]}, { include_blank: true }, { class: 'form-control' } %>
4
4
  </td>
5
5
  <td class="action vertical-align-middle text-center" width="44">
6
6
  <%= link_to_remove_association f, class: 'btn btn-danger btn-xs text-danger' do %>
@@ -0,0 +1,5 @@
1
+ class AddClusterConfigToOrganization < ActiveRecord::Migration
2
+ def change
3
+ add_column :organizations, :cluster_config, :text
4
+ end
5
+ end
@@ -54,7 +54,7 @@ module Klastera
54
54
  end
55
55
  _cluster_entities.map do |ce|
56
56
  ce.cluster.try(attribute)
57
- end.compact.join(separator)
57
+ end.sort.compact.join(separator)
58
58
  end
59
59
 
60
60
  ##
@@ -79,9 +79,8 @@ module Klastera
79
79
  # cluster_filter_id is present when the optional_suborganization mode is on. BUT!
80
80
  # Be aware that if the cluster_filter is not present, the value of force_cluster_clause
81
81
  # will be overridden by the returned value of cannot_skip_cluster_clause? method.
82
- #
83
- def cluster_scope!(scope_klass, user, organization, cluster_filter=nil, force_cluster_clause=false)
84
- scope_klass = scope_class(scope_klass)
82
+ def should_clusterize_scope?(user, organization, cluster_filter=nil, force_cluster_clause=false)
83
+ should = false # I don't know if this is a good idea
85
84
  if organization.is_in_cluster_mode? && ( cluster_filter.present? || force_cluster_clause = user.cannot_skip_cluster_clause? ) # yes, this is an assignation
86
85
  cluster_ids = []
87
86
  # Set another variable as array to get the cluster id(s)
@@ -92,15 +91,27 @@ module Klastera
92
91
  end
93
92
  # We will avoid the query unless cluster_ids is having values OR force_cluster_clause is set (see method description)
94
93
  if cluster_ids.present? || force_cluster_clause
95
- scope_klass = scope_klass.eager_load(:organization,cluster_entities: :cluster)
96
94
  # We add the unclustered if the value of cluster_filter have the special without_cluster string or as method description says
97
95
  if cluster_ids.delete(UNCLUSTERED_ENTITY) || ( force_cluster_clause && organization.optional_suborganization_mode? )
98
96
  cluster_ids << nil
99
97
  end
100
- scope_klass = scope_klass.where( cluster_entities: { cluster_id: cluster_ids } )
98
+ should = true
99
+ end
100
+ end
101
+ yield(should,cluster_ids)
102
+ end
103
+
104
+ #
105
+ # The cleanest and fast way to clusterize a entity!
106
+ #
107
+ def cluster_scope!(scope_klass, user, organization, cluster_filter=nil, force_cluster_clause=false)
108
+ scope = scope_class(scope_klass)
109
+ should_clusterize_scope?(user,organization,cluster_filter,force_cluster_clause) do |should,cluster_ids|
110
+ if should
111
+ scope = scope.eager_load(:organization,cluster_entities: :cluster).where( cluster_entities: { cluster_id: cluster_ids } )
101
112
  end
102
113
  end
103
- scope_klass.where(organization_id: organization)
114
+ scope.where(organization_id: organization)
104
115
  end
105
116
 
106
117
 
@@ -110,7 +121,7 @@ module Klastera
110
121
  unclusterized_scope = scope_class(scope_klass)
111
122
 
112
123
  if organization.is_in_cluster_mode? && ( force_cluster_clause || user.cannot_skip_cluster_clause? )
113
- unclusterized_scope = unclusterized_scope.joins(relation => :cluster_entities)
124
+ unclusterized_scope = unclusterized_scope.joins(relation).joins(Klastera::ClusterEntity.left_join_sources_of(cluster_entity_klass))
114
125
  end
115
126
 
116
127
  if scope_klass.respond_to?(:organization)
@@ -158,19 +169,13 @@ module Klastera
158
169
  # instead of the default INNER JOIN provide by ActiveRecord's joins method
159
170
  #
160
171
  def cluster_scope_left_join!(scope_klass,organization)
161
- scope_klass_arel_table = scope_klass.arel_table
162
- cluster_entities_arel_table = Klastera::ClusterEntity.arel_table
163
-
164
- scope_klass_cluster_entities = scope_klass_arel_table.join(cluster_entities_arel_table, Arel::Nodes::OuterJoin).on(
165
- scope_klass_arel_table[:id].eq(cluster_entities_arel_table[:entity_id]), cluster_entities_arel_table[:entity_type].eq(scope_klass.name)
166
- ).join_sources
167
-
168
- cluster_arel_table = ::Cluster.arel_table
169
- cluster_entities_cluster = cluster_entities_arel_table.join(cluster_arel_table, Arel::Nodes::OuterJoin).on(
172
+ cluster_entities_arel_table = Klastera::ClusterEntity.arel_table
173
+ cluster_arel_table = ::Cluster.arel_table
174
+ cluster_entities_cluster = cluster_entities_arel_table.join(cluster_arel_table, Arel::Nodes::OuterJoin).on(
170
175
  cluster_entities_arel_table[:cluster_id].eq(cluster_arel_table[:id]),
171
176
  ).join_sources
172
177
 
173
- scope_class(scope_klass).where(organization_id: organization).joins(scope_klass_cluster_entities).joins(cluster_entities_cluster)
178
+ scope_class(scope_klass).where(organization_id: organization).joins(Klastera::ClusterEntity.left_join_sources_of(scope_klass)).joins(cluster_entities_cluster)
174
179
  end
175
180
  end
176
181
 
@@ -1,3 +1,3 @@
1
1
  module Klastera
2
- VERSION = "1.4.1"
2
+ VERSION = "1.4.4.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: klastera
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gino Barahona
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-08-05 00:00:00.000000000 Z
11
+ date: 2020-11-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -93,14 +93,12 @@ files:
93
93
  - db/migrate/20200330010551_create_klastera_cluster_users.rb
94
94
  - db/migrate/20200330221601_add_order_field_to_clusters.rb
95
95
  - db/migrate/20200518142609_create_klastera_cluster_entities.rb
96
+ - db/migrate/20200908180057_add_cluster_config_to_organization.rb
96
97
  - lib/klastera.rb
97
98
  - lib/klastera/engine.rb
98
99
  - lib/klastera/version.rb
99
100
  - lib/tasks/klastera_tasks.rake
100
101
  - test/controllers/klastera/clusters_controller_test.rb
101
- - test/dummy/log/development.log
102
- - test/dummy/log/test.log
103
- - test/dummy/tmp/pids/server.pid
104
102
  - test/fixtures/klastera/cluster_users.yml
105
103
  - test/fixtures/klastera/clusters.yml
106
104
  - test/integration/navigation_test.rb
@@ -112,7 +110,7 @@ homepage: https://github.com/ginosx/klastera
112
110
  licenses:
113
111
  - MIT
114
112
  metadata: {}
115
- post_install_message:
113
+ post_install_message:
116
114
  rdoc_options: []
117
115
  require_paths:
118
116
  - lib
@@ -127,14 +125,11 @@ required_rubygems_version: !ruby/object:Gem::Requirement
127
125
  - !ruby/object:Gem::Version
128
126
  version: '0'
129
127
  requirements: []
130
- rubygems_version: 3.1.2
131
- signing_key:
128
+ rubygems_version: 3.0.8
129
+ signing_key:
132
130
  specification_version: 4
133
131
  summary: Clusterization Engine
134
132
  test_files:
135
- - test/dummy/log/test.log
136
- - test/dummy/log/development.log
137
- - test/dummy/tmp/pids/server.pid
138
133
  - test/integration/navigation_test.rb
139
134
  - test/models/klastera/cluster_user_test.rb
140
135
  - test/models/klastera/cluster_test.rb
@@ -1,108 +0,0 @@
1
-
2
-
3
- Started GET "/" for ::1 at 2020-03-24 17:46:51 -0300
4
-
5
- ActiveRecord::NoDatabaseError (FATAL: database "dummy_development" does not exist
6
- ):
7
- activerecord (4.2.11.1) lib/active_record/connection_adapters/postgresql_adapter.rb:661:in `rescue in connect'
8
- activerecord (4.2.11.1) lib/active_record/connection_adapters/postgresql_adapter.rb:650:in `connect'
9
- activerecord (4.2.11.1) lib/active_record/connection_adapters/postgresql_adapter.rb:242:in `initialize'
10
- activerecord (4.2.11.1) lib/active_record/connection_adapters/postgresql_adapter.rb:44:in `new'
11
- activerecord (4.2.11.1) lib/active_record/connection_adapters/postgresql_adapter.rb:44:in `postgresql_connection'
12
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:438:in `new_connection'
13
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:448:in `checkout_new_connection'
14
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:422:in `acquire_connection'
15
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:349:in `block in checkout'
16
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/monitor.rb:235:in `mon_synchronize'
17
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in `checkout'
18
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in `block in connection'
19
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/monitor.rb:235:in `mon_synchronize'
20
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:262:in `connection'
21
- activerecord (4.2.11.1) lib/active_record/connection_adapters/abstract/connection_pool.rb:571:in `retrieve_connection'
22
- activerecord (4.2.11.1) lib/active_record/connection_handling.rb:113:in `retrieve_connection'
23
- activerecord (4.2.11.1) lib/active_record/connection_handling.rb:87:in `connection'
24
- activerecord (4.2.11.1) lib/active_record/migration.rb:383:in `connection'
25
- activerecord (4.2.11.1) lib/active_record/migration.rb:370:in `call'
26
- actionpack (4.2.11.1) lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
27
- activesupport (4.2.11.1) lib/active_support/callbacks.rb:88:in `__run_callbacks__'
28
- activesupport (4.2.11.1) lib/active_support/callbacks.rb:778:in `_run_call_callbacks'
29
- activesupport (4.2.11.1) lib/active_support/callbacks.rb:81:in `run_callbacks'
30
- actionpack (4.2.11.1) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
31
- actionpack (4.2.11.1) lib/action_dispatch/middleware/reloader.rb:73:in `call'
32
- actionpack (4.2.11.1) lib/action_dispatch/middleware/remote_ip.rb:78:in `call'
33
- actionpack (4.2.11.1) lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
34
- actionpack (4.2.11.1) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
35
- railties (4.2.11.1) lib/rails/rack/logger.rb:38:in `call_app'
36
- railties (4.2.11.1) lib/rails/rack/logger.rb:20:in `block in call'
37
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:68:in `block in tagged'
38
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:26:in `tagged'
39
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:68:in `tagged'
40
- railties (4.2.11.1) lib/rails/rack/logger.rb:20:in `call'
41
- actionpack (4.2.11.1) lib/action_dispatch/middleware/request_id.rb:21:in `call'
42
- rack (1.6.13) lib/rack/methodoverride.rb:22:in `call'
43
- rack (1.6.13) lib/rack/runtime.rb:18:in `call'
44
- activesupport (4.2.11.1) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
45
- rack (1.6.13) lib/rack/lock.rb:17:in `call'
46
- actionpack (4.2.11.1) lib/action_dispatch/middleware/static.rb:120:in `call'
47
- rack (1.6.13) lib/rack/sendfile.rb:113:in `call'
48
- railties (4.2.11.1) lib/rails/engine.rb:518:in `call'
49
- railties (4.2.11.1) lib/rails/application.rb:165:in `call'
50
- rack (1.6.13) lib/rack/lock.rb:17:in `call'
51
- rack (1.6.13) lib/rack/content_length.rb:15:in `call'
52
- rack (1.6.13) lib/rack/handler/webrick.rb:88:in `service'
53
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/httpserver.rb:140:in `service'
54
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/httpserver.rb:96:in `run'
55
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/server.rb:307:in `block in start_thread'
56
-
57
-
58
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/_source.erb (5.9ms)
59
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/_trace.html.erb (3.9ms)
60
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/_request_and_response.html.erb (1.4ms)
61
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/diagnostics.html.erb within rescues/layout (182.3ms)
62
-
63
-
64
- Started GET "/" for ::1 at 2020-03-24 17:48:58 -0300
65
- Processing by Rails::WelcomeController#index as HTML
66
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/railties-4.2.11.1/lib/rails/templates/rails/welcome/index.html.erb (2.0ms)
67
- Completed 200 OK in 17ms (Views: 17.1ms | ActiveRecord: 0.0ms)
68
-
69
-
70
- Started GET "/clusters" for ::1 at 2020-03-24 17:51:49 -0300
71
-
72
- ActionController::RoutingError (No route matches [GET] "/clusters"):
73
- actionpack (4.2.11.1) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
74
- actionpack (4.2.11.1) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
75
- railties (4.2.11.1) lib/rails/rack/logger.rb:38:in `call_app'
76
- railties (4.2.11.1) lib/rails/rack/logger.rb:20:in `block in call'
77
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:68:in `block in tagged'
78
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:26:in `tagged'
79
- activesupport (4.2.11.1) lib/active_support/tagged_logging.rb:68:in `tagged'
80
- railties (4.2.11.1) lib/rails/rack/logger.rb:20:in `call'
81
- actionpack (4.2.11.1) lib/action_dispatch/middleware/request_id.rb:21:in `call'
82
- rack (1.6.13) lib/rack/methodoverride.rb:22:in `call'
83
- rack (1.6.13) lib/rack/runtime.rb:18:in `call'
84
- activesupport (4.2.11.1) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
85
- rack (1.6.13) lib/rack/lock.rb:17:in `call'
86
- actionpack (4.2.11.1) lib/action_dispatch/middleware/static.rb:120:in `call'
87
- rack (1.6.13) lib/rack/sendfile.rb:113:in `call'
88
- railties (4.2.11.1) lib/rails/engine.rb:518:in `call'
89
- railties (4.2.11.1) lib/rails/application.rb:165:in `call'
90
- rack (1.6.13) lib/rack/lock.rb:17:in `call'
91
- rack (1.6.13) lib/rack/content_length.rb:15:in `call'
92
- rack (1.6.13) lib/rack/handler/webrick.rb:88:in `service'
93
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/httpserver.rb:140:in `service'
94
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/httpserver.rb:96:in `run'
95
- /Users/gino/.rvm/rubies/ruby-2.5.7/lib/ruby/2.5.0/webrick/server.rb:307:in `block in start_thread'
96
-
97
-
98
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/_trace.html.erb (4.7ms)
99
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/routes/_route.html.erb (0.9ms)
100
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/routes/_route.html.erb (0.5ms)
101
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/routes/_table.html.erb (11.0ms)
102
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/_request_and_response.html.erb (9.0ms)
103
- Rendered /Users/gino/.rvm/gems/ruby-2.5.7@llegando/gems/actionpack-4.2.11.1/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb within rescues/layout (210.1ms)
104
- ActiveRecord::SchemaMigration Load (1.9ms) SELECT "schema_migrations".* FROM "schema_migrations"
105
- Migrating to AddAuthorIdToBlorghArticles (20200325002402)
106
-  (0.3ms) BEGIN
107
-  (1.0ms) ALTER TABLE "blorgh_articles" ADD "super_cluster_id" integer
108
-  (0.2ms) ROLLBACK
File without changes
@@ -1 +0,0 @@
1
- 86448