Re: Assign workflow steps to groups/roles

"Philipp Hug" <[email protected]>
Newsgroups gmane.comp.java.open-symphony.devel
Message-ID <025601c31328$fbc18850$3c0112ac@chimera>
well, the problem is, if you use a WorkflowQuery to find the
open taks/steps for a specific user, you need to fetch each step 
that has owner "null", then load the coresponding workflow
definition and call the OSUserGroup function.

> AbstractWorkflow subclassing
well, you can't access the OSUserGroupFunction sections in sql, because
they're in the XML definition and not in the database.

You're using CMP, right? Maybe I should switch to CMP too,
it seems to be better supported than JDBC ;-).

philipp
----- Original Message ----- 
From: "Hani Suleiman" <[email protected]>
Subject: Re: [Opensymphony-developers] Assign workflow steps to groups/roles


> I solve this by using my own caching group check function, using 
> ThreadLocals. Basically what happens is that every time there's a group 
> check (OSUserGroupFunction I think, too lazy to look up the actual 
> classname), I use my own group function, which pretty much does what 
> the standard group function does, except that it uses a threadlocal 
> context which stores both cache hits and misses, so that the user is 
> only ever checked against a group once, with the rest of the checks 
> being very fast cache hits. Unfortunately you still end up potentially 
> looping over hundreds of steps, but the cost per iteration is very 
> minimal, so the performance becomes a lot more decent.
> 
> Another option is to subclass your chosen AbstractWorkflow 
> implementation and add a method which uses jdbc to constrain the number 
> of steps returned to somehting that matches your group requirement, 
> rather than doing it at the appserver level.
> 
> On Monday, May 5, 2003, at 11:36 AM, Philipp Hug wrote:
> 
> > Does anyone use roles/groups in his workflows? How did you implement 
> > them?
> > The example workflow assigns workflow steps to owner "null" and then 
> > uses
> > permissions
> > to see if a uses is allowed to see/change this workflow.
> > The problem with this implementation is, that it doesn't perform very 
> > well,
> > because you might need to loop over hundereds of steps assigned to 
> > "null".
> > How about adding a owner group field to Step? But now, if someone is 
> > in a
> > bunch
> > of groups you have to do a lot of queries.
> > Any ideas?
> >
> > Philipp
> >
> >
> >
> > -------------------------------------------------------
> > This sf.net email is sponsored by:ThinkGeek
> > Welcome to geek heaven.
> > http://thinkgeek.com/sf
> > _______________________________________________
> > Opensymphony-developers mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/opensymphony-developers
> >
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Opensymphony-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-developers
> 
> 


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.