Recently in curso Category

Seaside book

| 5 Comments | No TrackBacks

Last weekend I installed LaTeX and began to write my first book.

It is a book about Seaside.

I want to include, at least, the following topics:


  • Seaside basics

  • Advanced Seaside

  • Ajax

  • Announcements

  • Persistance (GLORP, Magma, GemStone/S)

  • Scalability (load balancing, static content caching)

  • Deployment (big iron, VPS, Amazon EC2)

  • Unit Testing

  • Maintenance (monitoring, updating)

  • Magritte (just a little)

  • Data export (JSON/REXX)


I am thinking of creating a full application, from design to deployment, following an agile process (write a test, write the code, you know). Of course it will be hard as I'm by no means an expert, but in writing the book I will learn a lot more about Seaside, and at the same time this knowledge will be preserved in print.

I have read An introduction to Seaside by Michael Perscheid et al and I know about the book that Stéphane Ducasse and others are writing. Also I have read all I could from Ramon Leon's blog, Lukas Renggli's blog and the mailing lists. In spite of that I think that something else is necessary. This is my little contribution to the Seaside documentation.

I don't have idea how long this will take as I have never written a book (except my thesis). I have just finished the first chapter, but I hope that as the time pass I will write faster.

Wish me luck!

Seaside menus

| 8 Comments | No TrackBacks

Finally, after long hours (days and more exactly months) searching the archives, the Smalltalk/Seaside blogosphere and the web, I had my Aha! moment with Seaside.

I was trying to grasp the Seaside way to do menus. First I was using call:/answer to make the links in the menu work. So in my menu I had something like:



renderContentOn: html
html anchor on: #newContact of: self.
html space.
html anchor on: #contactList of: self.

newContact
| contact |
contact := self call: (ContactEditor contact: Contact new)
contact ifNotNil: [ContactDatabase contacts add: contact].

contactList
self call: (ContactList contacts: ContactDatabase contacts)


This would show a pair of links: 'New Contact' for adding a new Contact to the database and 'Contact List' for listing the current contents of your database.

What is the problem with this code? It worked, sort of. See: you want to add a contact, so you press the 'New contact' link and a ContactEditor call: is invoked. A contact form is presented for you to fill it. A pair of buttons (Save, Cancel) are shown too. The Save button submits the form and adds the Contact to the Contacts database. The cancel button, well, just cancels the process. But, as the menu is always visible, you could as well click the 'New contact' link instead of pressing the Cancel button in order to get a new blank Contact form.
What it is wrong with this? You are doing a new call: to a new ContactEditor and this call: is stacked in Seaside. The same happens if you click 5 or 4000 times the 'New Contact' link.
If, after clicking the 'New contact' many times, you fill the form and press the Save button, the last ContactEditor invoked answers back the Contact and it's saved to the database. But Seaside, noting that a call: was just answered, returns the application to the point where the call: was made. That is, to the 4th or 3999th call: stored in the stack. That is not the way you want the application to behave.
In a classical menu, for example in Wordpress when I click the 'Write a new post' link many times, it is the same as clicking it only once. You don't have a stack growing and growing endless.

How to solve it?

Usando Ruby on Rails - Parte 3

| No Comments | No TrackBacks

En el post anterior agregamos autenticación usando restful_authentication.
En este haremos que la autenticación permita a los usuarios que ya cuenten con una cuenta de OpenID, usarla para acceder a nuestro sistema.

Usando Ruby on Rails - Parte 2

| 1 Comment | No TrackBacks

Usando Ruby on Rails - Parte 1

| 3 Comments | No TrackBacks

Esta es la primera entrega de una serie de posts que pretenden crear un sistema básico sobre el cual construir una aplicación completa.
Este código surgió después de investigar las mejores prácticas de programación en Ruby on Rails para el proyecto que estoy desarrollando actualmente.
Como ya había comentado en otro post, el proyecto que estoy haciendo será el típico sistema web que permite a usuarios registrarse, obtener una cuenta de acceso al sistema y comenzar a usar la funcionalidad propia de la aplicación.
Como todo lo relacionado con RoR, hay muchísimas referencias y tips para hacer determinada funcionalidad. Estos posts reflejan lo que a mi consideración es la mejor manera, al momento, de crear una aplicación en RoR.

About this Archive

This page is a archive of recent entries in the curso category.

books is the previous category.

debian is the next category.

Find recent content on the main index or look in the archives to find all content.