Daniel Green | 1 Dec 2007 01:23
Picon
Gravatar

[lift] Re: Welcome Maciek Starzyk to the lift committers


Welcome! Great to have you on board (and some one working on adding
support for additional databases!)

On Nov 30, 2007 3:43 PM, Maciek <mstarzyk@...> wrote:
>
>
>
> On 30 Lis, 21:18, "David Pollak" <feeder.of.the.be...@...>
> wrote:
>
> > Marciek has just joined the lift committers.  He is currently working on
> > support for more databases in Mapper and who knows what he'll contribute
> > next.
> >
> > Welcome!
>
> Hi everyone :) Thanks David, it looks like you work really fast, so I
> have svn access within minutes :)
> I will be working with Jorge on adding Postgres (and H2) support to
> lift.
> I hope I will not break anything on the way ;) (will use branch for
> any changes).
>
> Cheers,
> Maciek
>
>
> >
>
(Continue reading)

Jeremy Hughes | 1 Dec 2007 02:08
Picon

[lift] lift:with-param XML content


Is it possible to give XML to a lift:with-param tag? It doesn't work
for me so I'm curious as to whether I'm doing somethin wrong or if
it's a /lift/ design decision.

Something like:

<lift:surround with="default" at="content">
  <lift:with-param name="epigraph">
    <div>`Twas brillig, and the slithy toves<br/>
          Did gyre and gimble in the wabe:<br/>
          All mimsy were the borogoves,<br/>
          And the mome raths outgrabe.<br/>
          --Lewis Carroll</div>
  </lift:with-param>
  [...]
</lift:surround>

Regards,

Jeremy

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb@...
To unsubscribe from this group, send email to liftweb-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

(Continue reading)

Picon

[lift] Re: Comet list question


I'm not sure if I'm getting this right, but if I am:

If someone was to trigger events, in an effort to circumvent security,
and carry out an action above their privileges, given the fact that
these events are batched would that not in turn lead to some really
weird state issues? On a less sinister note, this could also lead to
some hard to chase down bugs. Am I off base?

On Nov 30, 8:48 am, David Pollak <d...@...> wrote:
> Peter Hart wrote:
> > I have a table of real time resources that I'm keeping up to date
> > using comet. So far, I'm sending the entire list every time a change
> > occurs, but the list might get large in a real application, and I want
> > to keep user input in some of the list even when upates occur. I think
> > I really need to just send changes to the table instead. It looks like
> > I can do this with a JsCmd, but I'm not quite sure how to render the
> > actual table the first time through. What's the best approach for
> > doing this?
>
> Peter,
>
> I'm tackling this problem right now.
>
> What I'm working on is a "shared object" system where the client
> contains JavaScript object that, when changed, cause an event to be
> propagated to the server causing the corresponding object to change on
> the server.  Any other clients listening to the object will get a change
> notification.  Also, if a change happens on the server, then any objects
> listening on any client will receive change notifications.
(Continue reading)

David Pollak | 1 Dec 2007 04:16
Picon
Gravatar

[lift] Re: Comet list question

you're way off base.

the only way to trigger the events is to have the cryptographically secure unique ID of the item *and* the current session that holds that item's id.

If you're running an app in clear text (port 80) someone could sniff this information and spoofy notifications, but if you're running in clear text, someone can hijack your session in a lot of other ways.

The batching just means that if you have a series (let's say 10) object changes, they'll be sent in 1 HTTP transaction rather than 10 separate transactions.

On 11/30/07, saemghani-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org <saemghani-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:

I'm not sure if I'm getting this right, but if I am:

If someone was to trigger events, in an effort to circumvent security,
and carry out an action above their privileges, given the fact that
these events are batched would that not in turn lead to some really
weird state issues? On a less sinister note, this could also lead to
some hard to chase down bugs. Am I off base?

On Nov 30, 8:48 am, David Pollak <d...-+OHtpZWnG1vQT0dZR+AlfA@public.gmane.org> wrote:
> Peter Hart wrote:
> > I have a table of real time resources that I'm keeping up to date
> > using comet. So far, I'm sending the entire list every time a change
> > occurs, but the list might get large in a real application, and I want
> > to keep user input in some of the list even when upates occur. I think
> > I really need to just send changes to the table instead. It looks like
> > I can do this with a JsCmd, but I'm not quite sure how to render the
> > actual table the first time through. What's the best approach for
> > doing this?
>
> Peter,
>
> I'm tackling this problem right now.
>
> What I'm working on is a "shared object" system where the client
> contains JavaScript object that, when changed, cause an event to be
> propagated to the server causing the corresponding object to change on
> the server.  Any other clients listening to the object will get a change
> notification.  Also, if a change happens on the server, then any objects
> listening on any client will receive change notifications.
>
> There will be some "delays" built in so that a series of changes on
> either client or server are batched into 1 change set.  Sending the
> change sets will be *significantly* more efficient than sending the
> whole page redrawn.
>
> The second part of the project is the renderer.
>
> Basically, I'm working on a way to convert JavaScript objects to XHTML.
>
> The system is going to be an extension of the existing Scala XML
> mechanism that will allow you to define the transformation of JavaScript
> objects to XHTML.  For example:
>
> ConvJs(<div><ul>{
> MapJs("it.users")(
> <li>{V("it.name")}</li>
> )
>
> }</ul></div>)
>
> Will create list of names for all the users.  "it" is the "current
> object" (this, self)
>
> In addition to the "create an XHTML chunk", there will be guards so that
> different choices can be made for XHTML creation based on object fields.
>
> Anyway, that's where I am in the design stage.  It's not likely that any
> of this will be reality before end of year.
>
> Thoughts?
>
> Thanks,
>
> David
>
>
>
> > Thanks,
> >   -Peter



--
lift, the secure, simple, powerful web framework http://liftweb.net
Collaborative Task Management http://much4.us
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to liftweb-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

David Pollak | 1 Dec 2007 04:17
Picon
Gravatar

[lift] Re: lift:with-param XML content

Why would you want this?  What's wrong with <lift:surround with="default" at="content" name="eipigraph">....</lift:surround> ?

On 11/30/07, Jeremy Hughes <itsjdh-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:

Is it possible to give XML to a lift:with-param tag? It doesn't work
for me so I'm curious as to whether I'm doing somethin wrong or if
it's a /lift/ design decision.

Something like:

<lift:surround with="default" at="content">
  <lift:with-param name="epigraph">
    <div>`Twas brillig, and the slithy toves<br/>
          Did gyre and gimble in the wabe:<br/>
          All mimsy were the borogoves,<br/>
          And the mome raths outgrabe.<br/>
          --Lewis Carroll</div>
  </lift:with-param>
  [...]
</lift:surround>


Regards,

Jeremy

http://liftweb.net
Collaborative Task Management http://much4.us
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to liftweb-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

edgarchan | 1 Dec 2007 04:30
Picon

[lift] Re: Different scripts and styles per page


Nice!! .. it works very well ... thank you for your fast and clear
advice. cheers!

On Nov 30, 4:32 pm, "David Pollak" <feeder.of.the.be...@...>
wrote:
> Oddly enough, I was just dealing with a very similar issue.
>
> The answer comes in two parts.
>
> First, (after checking out head from SVN), you can do the following:
> <lift:surround with="default" extra_script="foo"/>
>
> The attributes passed are now available in S.attr("extra_script")
>
> In your template, you can have a <lift:snippet
> type="Util:processExtraScript"/>
>
> class Util {
>   def processExtraScript = S.attr("extra_script").map(n => <script
> src={"/scripts/"+n+".js"}/>).openOr(Nil)
>
> }
>
> What this does is it allows you to define an extra script in the page that's
> surrounding itself.  In the surround template, you can process the
> attributes.
>
> Sound reasonable?
>
> Thanks,
>
> David
>
> On 11/30/07, edgarchan <edgarchancarri...@...> wrote:
>
>
>
>
>
> > Hi all.
>
> > Question about this:
> > Suppose i have many pages that requires different styles and scripts
> > but results too heavy to put them all on the decorator's head. How can
> > i load specific scripts on different templates?
>
> > Is there any tag that can be used to attach anything to the decorator
> > from the template?
>
> > something like <lift:bind name="content" /> or the opposite of
> > lift:snipped
>
> > After looking around lift examples and code i didn't find a hint. do i
> > missing something?
>
> > thanks.
>
> --
> lift, the secure, simple, powerful web frameworkhttp://liftweb.net
> Collaborative Task Managementhttp://much4.us
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb@...
To unsubscribe from this group, send email to liftweb-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

David Bernard | 1 Dec 2007 09:34
Picon
Favicon

[lift] Re: Welcome Maciek Starzyk to the lift committers


Welcome Maciek.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb@...
To unsubscribe from this group, send email to liftweb-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

Viktor Klang | 1 Dec 2007 15:02
Picon

[lift] Re: Welcome Maciek Starzyk to the lift committers

Welcome aboard Maciek!

Cheers,
Viktor

On Dec 1, 2007 9:34 AM, David Bernard <dwayneb-GANU6spQydw@public.gmane.org> wrote:

Welcome Maciek.





--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to liftweb-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

j.k. | 1 Dec 2007 09:00
Picon

[lift] Lift memory requirements


The cheat sheet states that 64-bit machines require more than a gig of
RAM. Is this specific to what is being done on that page, or for any
lift-based app? Is it the case for both development and production
deployment, or is there perhaps a way to trim the app down when
deployed into production? If not, why is the memory requirement so
high?

I would really like to use lift/scala on a project i'm starting, but
the deployment environment is a 64-bit virtual host with 1 gig of RAM,
half of which is needed for other services.

Am I just out of luck? If so, are there any plans to reduce the memory
requirements, or for perhaps a Lift-lite?

Thanks for any info. I would love to use lift if possible.

j.k.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb@...
To unsubscribe from this group, send email to liftweb-unsubscribe@...
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---

David Pollak | 1 Dec 2007 17:34
Picon
Gravatar

[lift] Re: Lift memory requirements



On Dec 1, 2007 12:00 AM, j.k. <spaecious-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:

The cheat sheet states that 64-bit machines require more than a gig of
RAM. Is this specific to what is being done on that page, or for any
lift-based app? Is it the case for both development and production
deployment, or is there perhaps a way to trim the app down when
deployed into production? If not, why is the memory requirement so
high?

The requirement is for compiling the lift source on a 64 bit machine, not for running a lift app.

The JVM has much higher memory requirements on 64 bit machines as each object reference takes twice as many bytes.  Given that some of us are using 64 bit machines to develop lift (not lift apps, but lift itself), we have the maven scripts set up to work on our machines.

It has to do with the complexity of the data structures in the Scala compiler.  While lift itself has been hovering around 13K LoC for quite a while, those 13K LoC compile into 2,200 classes.  That's a lot of "stuff" for the Scala compiler to keep track of and it takes a lot of memory.

Using a 64 bit machine it *NOT* required for either development of lift itself or for deployment.  I routinely develop on a ThinkPad with an Intel Centrino 1.1ghz processor (slow 32 bit) with 1GB of RAM.



I would really like to use lift/scala on a project i'm starting, but
the deployment environment is a 64-bit virtual host with 1 gig of RAM,
half of which is needed for other services.

Once again, this is not a deployment requirement or even a requirement for building lift apps against the lift JARs.  It's only a requirement for compiling lift from source.

I have a Tomcat instance with -Xmx256M running http://much4.us, 2 other lift-based apps, and one non-lift based app.  I haven't had any problems memory-wise.
 


Am I just out of luck? If so, are there any plans to reduce the memory
requirements, or for perhaps a Lift-lite?

You can deploy a lift-based app in just about any servlet hosting environment.

Thanks,

David


Thanks for any info. I would love to use lift if possible.

j.k.

http://liftweb.net
Collaborative Task Management http://much4.us
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "liftweb" group.
To post to this group, send email to liftweb-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to liftweb-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at http://groups.google.com/group/liftweb?hl=en
-~----------~----~----~----~------~----~------~--~---


Gmane