[Lift] Conversation Context

2009-01-22 Thread Bryan
Does lift offer conversation contexts? If so, could someone provide me with an example. I am not sure if conversation context is the proper term, but I am using this term as it is used by JBoss Seam. A partial description would be an "approach that allows state to be scoped to a unit of work an

[Lift] Re: Heartbeat

2009-01-22 Thread Marius
Hmmm ... personally I'm not that thrilled about it. Can't we have an internal keep-alive mechanism that keeps the HTTP session not to expire? ... I wonder if just getting the HttpSession reference periodically and just don't do much with it would make the container to not expire the session.(Haven

[Lift] Re: Heartbeat

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 9:12 AM, Marius wrote: > > Hmmm ... personally I'm not that thrilled about it. Can't we have an > internal keep-alive mechanism that keeps the HTTP session not to > expire? ... I wonder if just getting the HttpSession reference > periodically and just don't do much with it

[Lift] Re: Conversation Context

2009-01-22 Thread Marius
The conversation context could be kept in a SessionVar. When your context terminates (say user clicked a button). You can attach a cleanUp function to the SessionVar (see registerCleanupFunc) so when your context terminates you can just call remove() on your SessionVar Would that help or I'm jus

[Lift] Re: Heartbeat

2009-01-22 Thread Marius
On Jan 22, 7:17 pm, David Pollak wrote: > On Thu, Jan 22, 2009 at 9:12 AM, Marius wrote: > > > Hmmm ... personally I'm not that thrilled about it. Can't we have an > > internal keep-alive mechanism that keeps the HTTP session not to > > expire? ... I wonder if just getting the HttpSession refe

[Lift] Re: Heartbeat

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 9:35 AM, Marius wrote: > > > > On Jan 22, 7:17 pm, David Pollak > wrote: > > On Thu, Jan 22, 2009 at 9:12 AM, Marius wrote: > > > > > Hmmm ... personally I'm not that thrilled about it. Can't we have an > > > internal keep-alive mechanism that keeps the HTTP session not

[Lift] Re: Heartbeat

2009-01-22 Thread Marius
On Jan 22, 8:20 pm, David Pollak wrote: > On Thu, Jan 22, 2009 at 9:35 AM, Marius wrote: > > > On Jan 22, 7:17 pm, David Pollak > > wrote: > > > On Thu, Jan 22, 2009 at 9:12 AM, Marius wrote: > > > > > Hmmm ... personally I'm not that thrilled about it. Can't we have an > > > > internal keep

[Lift] Re: Conversation Context

2009-01-22 Thread Bryan
Hi Marius, I would like the conversations contained within each tab. If I were to use just a Session variable then the user's state/data would "collide" and therefore cause unexpected behavior. This link does a better job of describing how conversations solve this problem: http://www.informit

[Lift] Re: Conversation Context

2009-01-22 Thread David Pollak
Bryan, There's no much in Lift to support what you're looking to do. For 1.1, there will be something like SmartMode Wizard (see https://www.lostlake.org/wizard.wmv ) If you can tell us something about your application, requirements, use cases, whatever, we'll work to tailor a solution for you.

[Lift] Re: Conversation Context

2009-01-22 Thread Bryan
That type of Wizard would be nice, though I am not a big fan of XML. Thank you for your willingness to come up with a solution, but I don't have a specific need for it right now. There is a project I may be working on in the future that is similar to the hotel website featured in that document I

[Lift] Re: Conversation Context

2009-01-22 Thread David Pollak
Bryan, On Thu, Jan 22, 2009 at 10:54 AM, Bryan wrote: > > That type of Wizard would be nice, though I am not a big fan of XML. There will be no XML in Lift. All Lift code is in Scala. Java did not allow for DSL creation, so in SmartMode we used XML. Scala allows for very flexible DSL creati

[Lift] Reading BLOB (images) from database with Mapper

2009-01-22 Thread Tim Perrett
Hey guys, I usually use JPA for my persistence, but have a small project that I just need to bang out, so I thought id give Mapper a go. Before I get started, does anyone know how one would go about reading a BLOB from mysql that holds an image? Cheers Tim --~--~-~--~~---

[Lift] Re: Reading BLOB (images) from database with Mapper

2009-01-22 Thread David Pollak
Tim, Make it a MappedBinary field. That corresponds to MySQL Blob. Thanks, David On Thu, Jan 22, 2009 at 11:08 AM, Tim Perrett wrote: > > Hey guys, > > I usually use JPA for my persistence, but have a small project that I just > need to bang out, so I thought id give Mapper a go. Before I ge

[Lift] Re: Reading BLOB (images) from database with Mapper

2009-01-22 Thread Tim Perrett
Hey David, Interesting, thanks ­ excuse my ignorance, but will I need anything else to output those images from the database col? Cheers, Tim On 22/01/2009 19:15, "David Pollak" wrote: > Tim, > > Make it a MappedBinary field. That corresponds to MySQL Blob. > > Thanks, > > David > > On

[Lift] "Starting with Lift" - a quick-start.

2009-01-22 Thread TylerWeir
You can find a quick-start guide that allows you to jump right into Lift development here: http://static.liftweb.net/StartingWithLift.pdf This combines a tutorial written by Dave Pollak with the first chapter of the Lift book, http://www.github.com/tjweir/liftbook/ . --~--~-~--~~---

[Lift] Bug in with-param ?

2009-01-22 Thread Tim Perrett
Guys, I think I might have just found a bug in the with-param use in layouts... If I do: The bind doesn't actually work, and the img tag gets inserted just above the main content bind point. However, if I do: (in case google groups breaks it, it should all be on one, single line)

[Lift] Re: Bug in with-param ?

2009-01-22 Thread Tim Perrett
It appears that to make with-param work you need to have a root node inside the with-param node and that the single closed element such as an ing tag is just a bit of a special case. It is a bit annoying to have to wrap valid markup with a just to make it insert it properly - my understand

[Lift] Re: Heartbeat

2009-01-22 Thread Jorge Ortiz
Summary: DPP: I can haz heartbeat? Marius: Heartbeat? I dunno... that sounds ugly... DPP: It comes with GC too! Marius: Oh hellz yeah! --j On Thu, Jan 22, 2009 at 10:30 AM, Marius wrote: > > > > On Jan 22, 8:20 pm, David Pollak > wrote: > > On Thu, Jan 22, 2009 at 9:35 AM, Marius wrote: > >

[Lift] Re: Heartbeat

2009-01-22 Thread David Pollak
LoL :-) On Jan 22, 2009 12:46 PM, "Jorge Ortiz" wrote: Summary: DPP: I can haz heartbeat? Marius: Heartbeat? I dunno... that sounds ugly... DPP: It comes with GC too! Marius: Oh hellz yeah! --j On Thu, Jan 22, 2009 at 10:30 AM, Marius wrote: > > > > > On Jan 22, 8:2... --~--~-~--~--

[Lift] Re: Heartbeat

2009-01-22 Thread TylerWeir
Jorge, the Lift Group Lulz Stenographer :) On Jan 22, 3:46 pm, Jorge Ortiz wrote: > Summary: > > DPP: I can haz heartbeat? > Marius: Heartbeat? I dunno... that sounds ugly... > DPP: It comes with GC too! > Marius: Oh hellz yeah! > > --j > > On Thu, Jan 22, 2009 at 10:30 AM, Marius wrote: > > >

[Lift] Re: Heartbeat

2009-01-22 Thread Tim Perrett
This actually made me LOL - great stuff Jorge! On 22/01/2009 21:11, "TylerWeir" wrote: > > Jorge, the Lift Group Lulz Stenographer :) > > On Jan 22, 3:46 pm, Jorge Ortiz wrote: >> Summary: >> >> DPP: I can haz heartbeat? >> Marius: Heartbeat? I dunno... that sounds ugly... >> DPP: It comes

[Lift] Re: Bug in with-param ?

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 12:33 PM, Tim Perrett wrote: > > It appears that to make with-param work you need to have a root node > inside the with-param node and that the single closed element such as > an ing tag is just a bit of a special case. > > It is a bit annoying to have to wrap valid markup

[Lift] Re: Bug in with-param ?

2009-01-22 Thread Meredith Gregory
David, Do you have a schema to govern lift tags so that this sort of syntactic constraint could be statically checked? Best wishes, --greg On Thu, Jan 22, 2009 at 2:11 PM, David Pollak wrote: > > > On Thu, Jan 22, 2009 at 12:33 PM, Tim Perrett wrote: > >> >> It appears that to make with-param

[Lift] Re: Bug in with-param ?

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 2:18 PM, Meredith Gregory wrote: > David, > > Do you have a schema to govern lift tags so that this sort of syntactic > constraint could be statically checked? No. Perhaps it's something we should add to our documentation to-do list. > > > Best wishes, > > --greg > > O

[Lift] Re: Bug in with-param ?

2009-01-22 Thread Tim Perrett
> > The tag has to be a child of the tag. > > I'm in the process of checking in a change to relax this constraint, but it > will have a negative impact on the ability to do nested tags. It being a child of lift:surround is not directly the problem. IMO, its just not obvious that if you want

[Lift] Re: Bug in with-param ?

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 2:28 PM, Tim Perrett wrote: > > > > > The tag has to be a child of the tag. > > > > I'm in the process of checking in a change to relax this constraint, but > it > > will have a negative impact on the ability to do nested > tags. > > It being a child of lift:surround is

[Lift] Fwd: lift production experience was Re: [scala-user] Are there any Scala friend small embeddable HTTP Severs?

2009-01-22 Thread Meredith Gregory
P.S. the liftweb alias escaped the cc line -- Forwarded message -- From: Meredith Gregory Date: Thu, Jan 22, 2009 at 2:38 PM Subject: lift production experience was Re: [scala-user] Are there any Scala friend small embeddable HTTP Severs? To: David Pollak Cc: Ricky Clarkson , Chr

[Lift] Re: Bug in with-param ?

2009-01-22 Thread Meredith Gregory
David, If you can give me some quick and dirty informal description of the constraints, i can code up a schema in short order. Best wishes, --greg On Thu, Jan 22, 2009 at 2:20 PM, David Pollak wrote: > > > On Thu, Jan 22, 2009 at 2:18 PM, Meredith Gregory < > lgreg.mered...@gmail.com> wrote:

[Lift] Re: Bug in with-param ?

2009-01-22 Thread David Pollak
Greg, I'm going to spend some time late next week cleaning up the render pipeline. I'll prepare the notes during my cleaning session. It would also be nice to have tests for the expected behaviors. Any volunteers out there? Thanks, David On Thu, Jan 22, 2009 at 2:47 PM, Meredith Gregory wrot

[Lift] JPA is killing me. Enumeration hell.

2009-01-22 Thread Charles F. Munat
I have an entity thus: @Entity @Table{val name = "cocktails"} class Cocktail extends BaseEntity { @Id @GeneratedValue{val strategy = GenerationType.AUTO} var id : Long = _ var name : String = "" var description : String = "" var ingredients : String = "" @Column{val name

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Jorge Ortiz
I don't really know much about JPA, but just a quick observation on the code you posted: Your code has line: abstract class EnumvType(val et: Enumeration with EnumTrait) extends UserType { whereas JPA Demo has line: abstract class EnumvType(val et: Enumeration with Enumv) extends UserType { I

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 4:05 PM, Jorge Ortiz wrote: > I don't really know much about JPA, but just a quick observation on the > code you posted: > > Your code has line: > abstract class EnumvType(val et: Enumeration with EnumTrait) extends > UserType { > whereas JPA Demo has line: > abstract

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Jorge Ortiz
Ahh, I see what the problem might be. There was another change to EnumvType: Replace this line: return et.valueOf(value) With this line: return et.valueOf(value).getOrElse(null) I'm sorry this is causing you so much trouble Chas. I made changes to classes in JPADemo and didn't realize they we

[Lift] Re: Bug in with-param ?

2009-01-22 Thread David Pollak
On Thu, Jan 22, 2009 at 2:11 PM, David Pollak wrote: > > > On Thu, Jan 22, 2009 at 12:33 PM, Tim Perrett wrote: > >> >> It appears that to make with-param work you need to have a root node >> inside the with-param node and that the single closed element such as >> an ing tag is just a bit of a sp

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Charles F. Munat
My bad. Thanks for noticing, but that's not the problem. I don't actually call it Enumv, I call it EnumTrait, and I just failed to change it back in the email. Jorge Ortiz wrote: > I don't really know much about JPA, but just a quick observation on the > code you posted: > > Your code has lin

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Charles F. Munat
Jorge Ortiz wrote: > Perhaps these classes should be rolled into a lift-jpa module so that > everyone can share the same code? That would rock. Chas. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group.

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Charles F. Munat
Thank you! Thank you! Thank you! Thank you! Thank you! That worked. I should've seen it though as I'd already made that fix on other sites. I don't know how I missed it. Tired, I guess. Pressure off now for a moment at least. Chas. Jorge Ortiz wrote: > Ahh, I see what the problem might be. Th

[Lift] Still confused about redirects

2009-01-22 Thread Charles F. Munat
I'm trying to do something dead simple, so it's impossible, of course. I have some legacy pages that don't exist anymore, and I want to send permanent (301) redirects to the browser. For example: Redirect permanent /thebook.html http://mysite.com/the_book/ The above should work in my vhosts.d

[Lift] Re: JPA is killing me. Enumeration hell.

2009-01-22 Thread Jorge Ortiz
Glad it worked. I'll see what can be done about preventing this kind of bug in the future. --j On Thu, Jan 22, 2009 at 4:58 PM, Charles F. Munat wrote: > > Thank you! Thank you! Thank you! Thank you! Thank you! > > That worked. I should've seen it though as I'd already made that fix on > other