Persisting Data Across Redirects

20 views
Skip to first unread message

Nick

unread,
May 20, 2012, 9:22:33 AM5/20/12
to FubuMVC Development Group
Hey Guys,

Suppose you are are doing a redirect - let's say validation has failed
has failed so you want to go back to the GET action. You now need the
validation errors to be available.

What do you guys see as the best way to do this?

I can see:

+ IFlash
+ ISessionState
+ Serialize the validation errors in say a request header

With the first two options, what if my app is running across multiple
servers - does the redirect stay inside the same process or would it
be routed as per any other request to say a load balancer?

Cheers

Dru Sellers

unread,
May 20, 2012, 9:41:24 AM5/20/12
to fubumv...@googlegroups.com
Well a redirect is sent to the browser and the browser makes the request so it would be subject to your load balancers. A serverside transfer would avoid that. I am pretty sure Ryan has just felt with this problem and may have a good idea if no one else does. 

-d

--
You received this message because you are subscribed to the Google Groups "FubuMVC Development Group" group.
To post to this group, send email to fubumv...@googlegroups.com.
To unsubscribe from this group, send email to fubumvc-deve...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/fubumvc-devel?hl=en.

Dru Sellers

unread,
May 20, 2012, 10:06:20 AM5/20/12
to fubumv...@googlegroups.com
Just a guess, but a memcached / asp.net cache backed IFlash would probably be the best, since you have some scale issues.

-d

Nick (ntcoding)

unread,
May 20, 2012, 11:47:48 AM5/20/12
to fubumv...@googlegroups.com
Cheers for the replies. That's basically what I though, just checking fubu didn't do something clever with redirects.

I think I'll just add the errors to the redirect request in the  most efficient - serialize the errors object or something with a smaller footprint.

Nick (ntcoding)

unread,
May 20, 2012, 1:17:52 PM5/20/12
to fubumv...@googlegroups.com
As it happens I was being dumb anyway. Partials are what I wanted. I love the concept of partials though :)

Kevin Miller

unread,
May 20, 2012, 11:01:27 PM5/20/12
to fubumv...@googlegroups.com
*Blush* Glad you found the post helpful. 

KevM

Sent from my couch computer 
--
You received this message because you are subscribed to the Google Groups "FubuMVC Development Group" group.
To view this discussion on the web visit https://groups.google.com/d/msg/fubumvc-devel/-/fuU_V5kZSRAJ.
Reply all
Reply to author
Forward
0 new messages