In Rails 3 routing, it seems we''re using the match() method to hook up arbitrary url patterns to rack endpoints (which I think is a great new routing feature). I''d like to suggest that we name it "connect", instead of "match": 1. It maintains continuity with previous versions of rails 2. It''s more descriptive of the intention of a route: to connect a requested url with an endpoint that can generate a response. Feedback? Thanks! Jeff -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
Anybody have thoughts on this one? (Criticism is ok if I''m off my rocker.) Jeff On Feb 20, 2:13 pm, Jeff <cohen.j...@gmail.com> wrote:> In Rails 3 routing, it seems we''re using the match() method to hook up > arbitrary url patterns to rack endpoints (which I think is a great new > routing feature). > > I''d like to suggest that we name it "connect", instead of "match": > > 1. It maintains continuity with previous versions of rails > 2. It''s more descriptive of the intention of a route: to connect a > requested url with an endpoint that can generate a response. > > Feedback? > > Thanks! > Jeff-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
I''m oppose to this though. In my point of view, I think the name `match` is already appropriate for it, as it mean that the router will try ''match'' the incoming request with each route, and sent the one that ''matched'' to the appropriate controller. Not core team I am, so let''s see how other thinks :) -- Prem S. On 23 ก.พ. 2553, at 13:06, Jeff wrote:> Anybody have thoughts on this one? (Criticism is ok if I''m off my > rocker.) > > Jeff > > On Feb 20, 2:13 pm, Jeff <cohen.j...@gmail.com> wrote: >> In Rails 3 routing, it seems we''re using the match() method to hook up >> arbitrary url patterns to rack endpoints (which I think is a great new >> routing feature). >> >> I''d like to suggest that we name it "connect", instead of "match": >> >> 1. It maintains continuity with previous versions of rails >> 2. It''s more descriptive of the intention of a route: to connect a >> requested url with an endpoint that can generate a response. >> >> Feedback? >> >> Thanks! >> Jeff > > -- > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. > To post to this group, send email to rubyonrails-core@googlegroups.com. > To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. > For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en. >
Absolutely agree with you. On 23.02.2010, at 11:11, Prem Sichanugrist wrote:> I''m oppose to this though. In my point of view, I think the name `match` is already appropriate for it, as it mean that the router will try ''match'' the incoming request with each route, and sent the one that ''matched'' to the appropriate controller.On Feb 20, 2:13 pm, Jeff wrote:>> 1. It maintains continuity with previous versions of railsYou MUST rewrite your routes anyway, so what a problem? Is it too hard to learn just 1 word?>> It''s more descriptive of the intention of a route: to connect a >> requested url with an endpoint that can generate a response.As opposite, there are rules that must be "matched". -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
On Feb 23, 12:36 am, Alexander Uvarov <alexander.uva...@gmail.com> wrote:> >> 1. It maintains continuity with previous versions of rails > > You MUST rewrite your routes anyway, so what a problem? Is it too hard to learn just 1 word?I said criticism is ok, not personal attacks. Of course it''s not too hard to learn. My point is that it''s a change from every previous version of Rails that seems unnecesary to me. If it is not necessary, then it should not be done.> >> It''s more descriptive of the intention of a route: to connect a > >> requested url with an endpoint that can generate a response. > > As opposite, there are rules that must be "matched".That''s been true since Rails 0.x. I think "connect" has been the right choice ever since, and I''m not seeing why we need to rename it to match(). My hope is that either someone on the core team will agree that it should remain as connect, or that someone from the core team will explain why a change is necessary. I''ll be happy if either of those happen, because I will have learned something. Jeff -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
On 23.02.2010, at 20:58, Jeff wrote:> On Feb 23, 12:36 am, Alexander Uvarov <alexander.uva...@gmail.com> > wrote: >>>> 1. It maintains continuity with previous versions of rails >> >> You MUST rewrite your routes anyway, so what a problem? Is it too hard to learn just 1 word? > > I said criticism is ok, not personal attacks. Of course it''s not too > hard to learn. My point is that it''s a change from every previous > version of Rails that seems unnecesary to me. If it is not necessary, > then it should not be done.This is not personal attack. Well, s/You/Developer -- that''s exactly what I mean. Peace :) -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
On Feb 23, 11:18 am, Alexander Uvarov <alexander.uva...@gmail.com> wrote:> On 23.02.2010, at 20:58, Jeff wrote: > > > On Feb 23, 12:36 am, Alexander Uvarov <alexander.uva...@gmail.com> > > wrote: > >>>> 1. It maintains continuity with previous versions of rails > > >> You MUST rewrite your routes anyway, so what a problem? Is it too hard to learn just 1 word? > > > I said criticism is ok, not personal attacks. Of course it''s not too > > hard to learn. My point is that it''s a change from every previous > > version of Rails that seems unnecesary to me. If it is not necessary, > > then it should not be done. > > This is not personal attack. Well, s/You/Developer -- that''s exactly what I mean. Peace :)Ah, thanks for the clarification. Peace :-) Jeff -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
On Feb 23, 2010, at 1:06 AM, Jeff wrote:> Anybody have thoughts on this one? (Criticism is ok if I''m off my > rocker.) > > Jeff >I''m certainly not an expert, but I think this syntax was carried over from Merb''s router. It''s distinctly different in that you can specify a route in "chunks"; for example, see the last example of this tutorial: http://merbunity.com/tutorials/12 Note that the Merb syntax wasn''t 100% retained (.to has become :to, and the block argument has vanished), but it''s much closer. --Matt Jones -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.