[Yanel-dev] Resources and Usecases

Josias Thöny josias.thoeny at wyona.com
Fri Mar 16 20:08:27 CET 2007


Michael Wechner wrote:
> Josias Thöny wrote:
> 
>> Hi all,
>>
>> Here's an attempt to define resources and usecases. It's quite similar 
>> to how it is in Lenya.
>> This is just meant as food for thought. Some people may come up with 
>> completely different ideas, and I'm interested to hear them.

Michi and I had a skype discussion and we think that the functionality 
of resources and usecases is somewhat overlapping. It might be better to 
have only one concept which covers all needs, if possible.
Now we're trying to find examples of usecases to determine the 
requirements and to see if it could be done only with resources.

Here are some "usecases" we have already:
- create new page
- create new realm
- show meta of a page
- edit user profile
- login

some usecases we may want to have:
- show all registered users/groups
- edit meta data of a page
- show server status
- show/edit policies of a page
- ...

For the following usecases, I'm not sure whether yanel needs a 
web-frontend or if that would be handled by neutron:
- delete/restore page
- copy/paste page
- rename page
- ...

Does anybody have more/better examples?

Josias


>>
>>
>> Resource:
>> ========
>> A resource is responsible to create/render/deliver the content for a 
>> certain url of the website.
>>
>>
>> Usecase:
>> =======
>> A usecase takes actions and/or delivers the content for any url with a 
>> request-parameter yanel.usecase=myusecase
> 
> 
> do you have any concrete examples which you would like to implement as a 
> usecase?
> 
> Cheers
> 
> Michi
> 
>>
>> In particular, a usecase may represent an action which may take some 
>> user interaction according to a certain "workflow" like e.g. :
>> (It would not be limited to this schema though)
>>
>> show screen
>>   |
>>   +--> click ok  --> check conditions
>>   |                     |
>>   |                     +-> if ok: execute  --> handle errors
>>   |                     |
>>   |                     +-> if nok: go back to 'show screen'
>>   |
>>   +--> click cancel --> cancel
>>
>> The usecase framework takes care of the following tasks which are 
>> common to most executable usecases:
>> - parameter passing (how to pass form parameters to the java code
>>   and vice-versa)
>> - error handling (check preconditions, handle parameter validation
>>   errors and other kind of errors)
>> - view processing (creating a view using a template and applying
>>   standard xslt or i18n transformer)
>>   (jelly support would be nice, it's similar to jx)
>> - control flow (handle pre-defined actions like submit/cancel)
>> - allow automated execution of a usecase (e.g. by a scheduler)
>>
>>
>> Moreover, I would like to achieve the following with a usecase framework:
>> - creation of new usecases is easy (e.g. no need to create individual
>>   ant build files for each usecase)
>> - a usecase only contains the code which is really necessary
>>   (e.g. a java handler class, a view template, and a configuration)
>> - no code duplication between usecases
>> - common look & feel for form-based usecases
>> - no need to register usecases for each realm individually.
>>
>> josias
>>
>> _______________________________________________
>> Yanel-development mailing list
>> Yanel-development at wyona.com
>> http://wyona.com/cgi-bin/mailman/listinfo/yanel-development
>>
> 
> 




More information about the Yanel-development mailing list