I am using Ruby on Rails 3 and I am trying to use middlewares in order to set a variable @variable_name accessible later in controllers.
@variable_name
For example my midd
You can have a cattr_accessor :my_var in any model and set this variable from middleware by
MyModel.my_var = 'something'
And you can access this anywhere in the application.