Quantcast

experimental version online

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

experimental version online

Dierk König
my first experimental version of the 'tutor' grails application is online
under
http://groovy.canoo.com/tutor

It is still experimental and uses the in-memory HSQL-DB.
Adding of new TutorialEntries currently throws an exception
because of the self-referencing issue.

Everything else should work.

cheers
Mittie

P.S. My page in history is certain: The first online Grails app ever (?)

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: experimental version online

Jochen Theodorou
Dierk Koenig wrote:
> my first experimental version of the 'tutor' grails application is online
> under
> http://groovy.canoo.com/tutor

nice ;)

> It is still experimental and uses the in-memory HSQL-DB.
> Adding of new TutorialEntries currently throws an exception
> because of the self-referencing issue.
>
> Everything else should work.

like the "Home" link? for example when showing an author Home points to
author/index instead of tutorial/index.

bye blackdrag
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: experimental version online

Dierk König
> > Everything else should work.
>
> like the "Home" link? for example when showing an author Home points to
> author/index instead of tutorial/index.

*hehe* well spotted.

Actually, for the 'admin mode' pages, I left the 'Home' buttons in their
scaffolded version, i.e. pointing to user/list and author/list.
(would be simple to change, though)

Currently, the user needs to go through the 'User' admin mode pages, which
will not longer be necessary as soon as authentication is built in.

thanks for using 'tutor' :-)
Mittie
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

'unique' constraint and updating

Dierk König
In reply to this post by Dierk König
Hi,

in http://groovy.canoo.com/tutor
I constraint e.g. the TutorialEntry title to be unique.
That now conflicts with updating any entry because this constraint
will always be violated, obviously.

What's the best way to get around this?
Make 'unique' smarter? (check against id)
Remove 'title' from the editable fields in the 'edit.gsp'?
Remove 'title' from the params in the edit action?

cheers
Mittie
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: 'unique' constraint and updating

graemer
On 11/03/06, Dierk Koenig <[hidden email]> wrote:
> Hi,
>
> in http://groovy.canoo.com/tutor
> I constraint e.g. the TutorialEntry title to be unique.
> That now conflicts with updating any entry because this constraint
> will always be violated, obviously.
Ah right silly me.. please file an issue, this shouldn't happen
>
> What's the best way to get around this?
> Make 'unique' smarter? (check against id)
Yes we need to make unique smarter

Graeme

> Remove 'title' from the editable fields in the 'edit.gsp'?
> Remove 'title' from the params in the edit action?
>
> cheers
> Mittie
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: experimental version online

graemer
In reply to this post by Dierk König
On 10/03/06, Dierk Koenig <[hidden email]> wrote:
> my first experimental version of the 'tutor' grails application is online
> under
> http://groovy.canoo.com/tutor
Excellent! Nice work :-) Its nice to see how performant Grails can be
on a real server, its nice and snappy

>
> It is still experimental and uses the in-memory HSQL-DB.
> Adding of new TutorialEntries currently throws an exception
> because of the self-referencing issue.
Is this the Groovy bug?

>
> Everything else should work.
>
> cheers
> Mittie
>
> P.S. My page in history is certain: The first online Grails app ever (?)
Indeed it is! Always to be remembered ;-)

>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: experimental version online

Dierk König
> > http://groovy.canoo.com/tutor
> Excellent! Nice work :-) Its nice to see how performant Grails can be
> on a real server, its nice and snappy

Thanks. It was a pleasure.

Performance is suprising, given that I didn't even care for
the most obvious optimizations.

Two other aspects would deserve more 'marketing':
- working with Grails feels like working with an object database
  (now really while working with Java/Hibernate doesn't really
  feel so because one is thinking in 'mappings' instead of
  objects about half of the time).
- the interplay of Grails persistence and GPath is the pure joy!
  All unique names of users having visited any Grails tutorial:
  Visit.list().findAll{it.entry.title=~/Grails/}.unique().user.name

How cool is that?

> > It is still experimental and uses the in-memory HSQL-DB.
> > Adding of new TutorialEntries currently throws an exception
> > because of the self-referencing issue.
> Is this the Groovy bug?

No, that's NPE in ctor because we cannot have in TE
 @Property parent // = new TutorialEntry() endless recursion

or is that solved meanwhile and I forgot to upgrade?

cheers
Mittie
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: experimental version online

graemer
On 11/03/06, Dierk Koenig <[hidden email]> wrote:

> > > http://groovy.canoo.com/tutor
> > Excellent! Nice work :-) Its nice to see how performant Grails can be
> > on a real server, its nice and snappy
>
> Thanks. It was a pleasure.
>
> Performance is suprising, given that I didn't even care for
> the most obvious optimizations.
>
> Two other aspects would deserve more 'marketing':
> - working with Grails feels like working with an object database
>  (now really while working with Java/Hibernate doesn't really
>  feel so because one is thinking in 'mappings' instead of
>  objects about half of the time).
> - the interplay of Grails persistence and GPath is the pure joy!
>  All unique names of users having visited any Grails tutorial:
>  Visit.list().findAll{it.entry.title=~/Grails/}.unique().user.name
>
> How cool is that?
>
> > > It is still experimental and uses the in-memory HSQL-DB.
> > > Adding of new TutorialEntries currently throws an exception
> > > because of the self-referencing issue.
> > Is this the Groovy bug?
>
> No, that's NPE in ctor because we cannot have in TE
>  @Property parent // = new TutorialEntry() endless recursion
>
> or is that solved meanwhile and I forgot to upgrade?
Ah right, is the proposed solution to this still to catch the
exception, log it and leave it up to the user to manage?

If so can you raise an issue so i don't forget

Thanks
Graeme

>
> cheers
> Mittie
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: experimental version online

Guillaume Laforge-2
In reply to this post by Dierk König
On 3/11/06, Dierk Koenig <[hidden email]> wrote:
> [...]
> > http://groovy.canoo.com/tutor

Well done! ;-)

> [...]
>   Visit.list().findAll{it.entry.title=~/Grails/}.unique().user.name
> How cool is that?

Hehe, neat, but... err... I hope there aren't millions of records in
Visit, otherwise you might be surprised by the memory consumption ;-)


--
Guillaume Laforge
Groovy Project Manager
http://glaforge.free.fr/blog/groovy
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: experimental version online

Dierk König
> > [...]
> >   Visit.list().findAll{it.entry.title=~/Grails/}.unique().user.name
> > How cool is that?
>
> Hehe, neat, but... err... I hope there aren't millions of records in
> Visit, otherwise you might be surprised by the memory consumption ;-)

*hehe* sure. In which case we would do

Visit.findByEntryLike('%Grails%').user.name

that's better anyway...
Mittie


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: experimental version online

Guillaume Laforge-2
On 3/12/06, Dierk Koenig <[hidden email]> wrote:
> > > [...]
> > Hehe, neat, but... err... I hope there aren't millions of records in
> > Visit, otherwise you might be surprised by the memory consumption ;-)
>
> *hehe* sure. In which case we would do
>
> Visit.findByEntryLike('%Grails%').user.name
>
> that's better anyway...

I think so too :-)

--
Guillaume Laforge
Groovy Project Manager
http://glaforge.free.fr/blog/groovy
Loading...