Occasionally Connected Components
In working with Seam and some of the ideas behind it, I quickly came to realize some of the faults of having stateful UIs. Take a h:dataTable for a second-- where it's great that we have a stateful dataTable component, but anything that's dynamic-- such as the data itself, must be retained in a stateful scope that matches the UI. So with something like JSF, you are getting half of the cake. It's taking care of managing all that state when really, you don't care-- you just care about your model and any state you do care about is represented in existing scopes-- such as the request or session or-- conversation.
When you write JSF components... anything you want that's dynamic must be handled as a special case-- see some of the 'getter' code in UIInput. What if the component was meant to be stateless in the first place-- the tree static-- everything hardwired and shared across all threads? Facelet TagHandlers are damn easy to write, and their stateless. They are so easy to write that people were wondering about using Facelets as a general templating language, but it's built on top of JSF-- and there's nothing wrong with that, it's a win-win situation for developers.
Fast forward a month later, and I started to look at what it meant to be part of a component tree-- a view, and where the dynamisism could lie in relation to rich UIs and AJAX or whatever. JSF's lifecycle is built around processing the whole tree, which doesn't leave much room for partial tree processing-- only render component 'A' in some table. It's hard, but there's the idea of a ProcessingContext that I brought up on Java.net which basically 'short circuits' tree processing into the selected branches and leaves. But upon more discussion, then there's the issue of state saving-- which brings us full circle about stateless component models.
I've shared the idea of ProcessingContexts with JSF, but I'm still worried about state management and model management, I want something that works for Yahoo.com or Google. My idea is to pursue some of these concepts into a new version of Facelets-- called Avatar, which will skim out all of the JSF statemanagement and offer a pure alternative to JSP/Velocity that can be used with Struts or WebWork, or just Servlets. I'm still working out all the details, but it will be fully declarative and offer partial tree processing as a first-class citizen in the API. AJAX will be a piece of cake-- invoke some Action and render component 'C' on this Avatar page.
I'm still working out how to handle updates, I might just give components two phases (like portlets) with a render and update phase. But then there's the question of validation, where you want to update, or at least validate everything before applying, but since there has to be opportunity for iterative scopes, it's not something that can easily be retained unless I determine that there's some kind of updateevent that can be queued or action events... hmmm... maybe this is the alternate answer to all of those lifecycles-- here, we provide two phases, but queue how many events you want for evaluation later. More to think about.
When you write JSF components... anything you want that's dynamic must be handled as a special case-- see some of the 'getter' code in UIInput. What if the component was meant to be stateless in the first place-- the tree static-- everything hardwired and shared across all threads? Facelet TagHandlers are damn easy to write, and their stateless. They are so easy to write that people were wondering about using Facelets as a general templating language, but it's built on top of JSF-- and there's nothing wrong with that, it's a win-win situation for developers.
Fast forward a month later, and I started to look at what it meant to be part of a component tree-- a view, and where the dynamisism could lie in relation to rich UIs and AJAX or whatever. JSF's lifecycle is built around processing the whole tree, which doesn't leave much room for partial tree processing-- only render component 'A' in some table. It's hard, but there's the idea of a ProcessingContext that I brought up on Java.net which basically 'short circuits' tree processing into the selected branches and leaves. But upon more discussion, then there's the issue of state saving-- which brings us full circle about stateless component models.
I've shared the idea of ProcessingContexts with JSF, but I'm still worried about state management and model management, I want something that works for Yahoo.com or Google. My idea is to pursue some of these concepts into a new version of Facelets-- called Avatar, which will skim out all of the JSF statemanagement and offer a pure alternative to JSP/Velocity that can be used with Struts or WebWork, or just Servlets. I'm still working out all the details, but it will be fully declarative and offer partial tree processing as a first-class citizen in the API. AJAX will be a piece of cake-- invoke some Action and render component 'C' on this Avatar page.
I'm still working out how to handle updates, I might just give components two phases (like portlets) with a render and update phase. But then there's the question of validation, where you want to update, or at least validate everything before applying, but since there has to be opportunity for iterative scopes, it's not something that can easily be retained unless I determine that there's some kind of updateevent that can be queued or action events... hmmm... maybe this is the alternate answer to all of those lifecycles-- here, we provide two phases, but queue how many events you want for evaluation later. More to think about.

2 Comments:
I'd love to use Facelets for non-JSF purposes! We have been looking for a more usable alternative to Freemarker in Struts Action 2, and this Avatar just might be it. Let me know how I can help.
By
Don Brown, at 12:20 PM
情趣用品,情趣用品,情趣用品,情趣用品,情趣用品,情趣用品,情趣用品,情趣用品,情趣,情趣,情趣,情趣,情趣,情趣,情趣,情趣,A片,視訊聊天室,聊天室,視訊,視訊聊天室,080苗栗人聊天室,上班族聊天室,成人聊天室,中部人聊天室,一夜情聊天室,情色聊天室,視訊交友網a片,a片
免費A片,AV女優,美女視訊,情色交友,免費AV,色情網站,辣妹視訊,美女交友,色情影片,成人影片,成人網站,A片,H漫,18成人,成人圖片,成人漫畫,情色網,日本A片,免費A片下載,性愛
A片,色情,成人,做愛,情色文學,A片下載,色情遊戲,色情影片,色情聊天室,情色電影,免費視訊,免費視訊聊天,免費視訊聊天室,一葉情貼圖片區,情色,情色視訊,免費成人影片,視訊交友,視訊聊天,視訊聊天室,言情小說,愛情小說,AIO,AV片,A漫,avdvd,聊天室,自拍,情色論壇,視訊美女,AV成人網,色情A片,SEX,成人論壇
情趣用品,A片,免費A片,AV女優,美女視訊,情色交友,色情網站,免費AV,辣妹視訊,美女交友,色情影片,成人網站,H漫,18成人,成人圖片,成人漫畫,成人影片,情色網
情趣用品,A片,免費A片,日本A片,A片下載,線上A片,成人電影,嘟嘟成人網,成人,成人貼圖,成人交友,成人圖片,18成人,成人小說,成人圖片區,微風成人區,成人文章,成人影城,情色,情色貼圖,色情聊天室,情色視訊,情色文學,色情小說,情色小說,臺灣情色網,色情,情色電影,色情遊戲,嘟嘟情人色網,麗的色遊戲,情色論壇,色情網站,一葉情貼圖片區,做愛,性愛,美女視訊,辣妹視訊,視訊聊天室,視訊交友網,免費視訊聊天,美女交友,做愛影片
av,情趣用品,a片,成人電影,微風成人,嘟嘟成人網,成人,成人貼圖,成人交友,成人圖片,18成人,成人小說,成人圖片區,成人文章,成人影城,愛情公寓,情色,情色貼圖,色情聊天室,情色視訊,情色文學,色情小說,情色小說,色情,寄情築園小遊戲,情色電影,aio,av女優,AV,免費A片,日本a片,美女視訊,辣妹視訊,聊天室,美女交友,成人光碟
情趣用品.A片,情色,情色貼圖,色情聊天室,情色視訊,情色文學,色情小說,情色小說,色情,寄情築園小遊戲,情色電影,色情遊戲,色情網站,聊天室,ut聊天室,豆豆聊天室,美女視訊,辣妹視訊,視訊聊天室,視訊交友網,免費視訊聊天,免費A片,日本a片,a片下載,線上a片,av女優,av,成人電影,成人,成人貼圖,成人交友,成人圖片,18成人,成人小說,成人圖片區,成人文章,成人影城,成人網站,自拍,尋夢園聊天室
By
sexy, at 7:24 AM
Post a Comment
<< Home