Displaying 20 results from an estimated 1000 matches similar to: "Middleware example from Railscast #151 doesn't work as expected. Need help."
2010 Dec 15
2
Error reverse engineering MySQL with RMRE
Hi
I am been trying in vain to auto-gen models by reverse-engineering
mysql using RMRE. It complains mysql2 gem missing but as seen in my
Rails environment below, it is there.
Here''s my Rails environment and RMRE error. Experts... please help!
Thanks a ton in advance!!
===
Ruby version 1.9.2 (x86_64-linux)
RubyGems version 1.3.7
Rack version 1.2
Rails version 3.0.3
Active Record
2011 Jan 10
0
Can't use ActionDispatch::Request in Rails middleware because path_parameters get lost
Hi,
I just encountered a bit of an issue where we call request.params of
an ActionDispatch::Request inside a rack middleware right before a
Rails 3.0.3 app. The issue is that the path_parameters never appear
in the parameters hash if you call request.params before the rails
app.
It seems that that the requests.params method memoizes itself in
"action_dispatch.request.parameters"
2013 Jul 22
0
How to handle exception that is generated in rack middleware before it reach rails app?
I know that we can use config.exception_app to set up custom exception
handling and also use rescue_from. However, I have an issue that there is
malformed request (testing generated request) that caused Rails Rack
middleware to throw an exception when Rack''s parse_query method. Here is
the detail of the
problem:
2011 Jun 03
0
Rack Middleware support for Rails 2.0.2? If not what is the alternative to implement similar functionality in Rails 2.0.2..
Hello all,
I am using Rails 2.0.2 and Ruby 1.8.7 and I need to make use of rack
middleware for integrating an ajax file upload plugin(https://
github.com/valums/file-uploader) with paperclip in Rails( As given in
this tutorial:-
http://mooooooooooo.wordpress.com/2010/12/03/paperclip-valums%E2%80%99s-file-uploader-and-middleware-continued/).
I have referred to the rack-middleware Railscast by
2012 Jul 23
4
uninitialized constant ActionController::Flash::FlashHash [NameError])
My application, a very simple general ledger, that worked very well until
June 26 does not work any longer. It is used under Ubuntu 12.04 and I
believe there was a Ruby update after that.
What happens?
When I try to start the appIication I get the following output in my web
browser:
ActionDispatch::Session::SessionRestoreError
Session contains objects whose class definition isn''t
2012 Jan 12
0
telling app to use middleware in gem
I have a gem, and part of the gem is a piece of rack middleware. In
Rails 2.3, I could make the gem set up the middleware without adding
anything to config/*.rb in the app. I did this with the following
line:
ActionController::Dispatcher.middleware.use ''MyMiddleware''
But in Rails 3, this doesn''t work.
I''ve tried putting the following into the gem''s
2011 Feb 28
4
best_standards_support
File ./lib/rails/generators/rails/app/templates/config/environments/development.rb.tt:
# Only use best-standards-support built into browsers
config.action_dispatch.best_standards_support = :builtin
File ./lib/rails/application.rb:
middleware.use ::ActionDispatch::BestStandardsSupport,
config.action_dispatch.best_standards_support if
config.action_dispatch.best_standards_support
What''s
2012 May 31
1
Rack Middleware or after filter
Hi All
I need an solution that i should catch response and based
on some conditions i have to modify response body and send back to
client.
I have tried with a Middleware and got a solution.Can i use a
Middleware or simply one after_filter.
On performance wise which is best.Or is there any other ways to do it.
thanks in advance.
--
You received this
2013 Apr 06
0
Bug#693137: marked as done (ITP: swift-plugin-s3 -- swift3 (S3 compatibility) middleware plugin for swift)
Your message dated Sat, 06 Apr 2013 13:00:07 +0000
with message-id <E1UOSj1-0002As-63 at franck.debian.org>
and subject line Bug#693137: fixed in swift-plugin-s3 1.7-1
has caused the Debian Bug report #693137,
regarding ITP: swift-plugin-s3 -- swift3 (S3 compatibility) middleware plugin for swift
to be marked as done.
This means that you claim that the problem has been dealt with.
If this
[Bug 3585] New: "misc.h" required when build the sk middleware ("sk-usbhid.c") as standalone library
2023 Jul 02
0
[Bug 3585] New: "misc.h" required when build the sk middleware ("sk-usbhid.c") as standalone library
https://bugzilla.mindrot.org/show_bug.cgi?id=3585
Bug ID: 3585
Summary: "misc.h" required when build the sk middleware
("sk-usbhid.c") as standalone library
Product: Portable OpenSSH
Version: 9.3p1
Hardware: All
OS: All
Status: NEW
Severity: enhancement
2015 Jul 01
0
[PATCH 7/9] v2v: Introduce the concept of target buses.
The target VM will have several buses to which disks can be attached.
Commonly it will have an IDE bus, and possibly a virtio-blk "bus" (not
really a bus) and/or a SCSI bus.
Virt-v2v does not model this at the moment. Disks are just added to
the output XML in the order that we write them, and so they can move
around with respect to the target VM.
This commit introduces the idea that
2009 Oct 06
0
Named routes and a Railscast
I''m looking at railscast#102 ( http://railscasts.com/episodes/102-auto-complete-association
) and when I implement it, a certain named
( "formatted_channelnotes_path(:js)" ) route is used in:
<%= text_field_with_auto_complete :channel, :channelnote_name, { :size
=> 15 }, { :url => formatted_channelnotes_path(:js), :method
=> :get, :param_name =>
2014 Mar 27
0
Rack middleware for shared connection pools?
I have a Rails app that makes connections to other DBs. There may be
multiple users connecting to multiple DBs.
The app makes a database connection as part of an action. However, I
noticed a problem: there's too many DB connections remaining open, which is
causing the DB to not have enough connections remaining for new connections.
So the answer is using a shared connection pool.
2011 Nov 01
2
Railscast 262 different partial in helper
Hi RoR Community,
in Ryan Bates Railscasts Episode #262 he put the index code
<% for message in @messages %>
<div class="message">
<div class="created_at"><%= message.created_at.strftime("%B %d, %Y")
%></div>
<div class="content">
<%= message.content %>
</div>
<div
2009 Sep 22
4
rspec-rails and rack middleware
It doesn''t seem like my controller specs are calling my middleware on
requests. Has anyone figured out a good way to test middlware with rspec?
I''m thinking something like
rails'' rails/actionpack/test/controller/session/mem_cache_store_test.rb but
with rspec... any thoughts?
Thanks!
Best,
Aaron
-------------- next part --------------
An HTML attachment was scrubbed...
2008 Oct 24
4
Railscast 75, Observe_field and Shopping Cart
Hi all,
I have the shopping cart page where a user can add items dynamically
through ajax as explained in Railscast episode 75. I am using
observe_field to observe the ''quantity'' and ''cost'' fields to update
the total field for each item.
This does not work however, for records that are added through the
Ajax. How can i name the fields and observe them as i have
2013 Jun 22
4
ActiveRecord::Base.transaction - SystemStackError - stack level too deep:
Im having an issue that seems to only happen when trying to use a
transaction. Ive used transactions many times in the past and Im at a loss
as to why im getting the stack level too deep problem.
SystemStackError - stack level too deep:
actionpack (3.2.13) lib/action_dispatch/middleware/reloader.rb:70:in `''
I have a StackOveflow with more detail -
2013 Mar 26
2
Using rack.hijack with ActionController::Live
Pinging @tenderlove
Some questions on how best to move forward with this:
1.) AC::Live is making use of the stream object on
ActionDispatch::Response. Should the rack.hijack_io object be used instead
of this in AC::Live or should ActionDispatch::Response be changed to use
rack.hijack_io?
2.) What do you think about changing AC::Live to work with adapters? I
suspect the primary use case for
2010 Apr 26
2
/lib/rack/request.rb in my gem - is this reserved?
Hi!
I write a gem at the moment. The Gem need to register during the
process in the rack middleware.
So I make an folder "rack" inside my "lib" folder. I called the file
"request.rb" because it keeps track of requests.
So we speaking about the file /lib/rack/request.rb
But even if I place an empty file on this, I get the following:
2012 Sep 21
9
Using PostgreSQL with RoR on windows. Help!
So I just got involved in a huge team project with RoR and PostgreSQL.
But I can''t find anywhere on the internet to find a proper way to put
them together. I did find one but it is for iOS :-/
http://railscasts.com/episodes/342-migrating-to-postgresql?view=asciicast
I have them both installed and the gem package for postgres also. the
database.yml is already configured. I just