You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Ron Piterman (JIRA)" <ta...@jakarta.apache.org> on 2005/10/21 10:01:45 UTC

[jira] Created: (TAPESTRY-717) Easier accessing the hivemind registry

Easier accessing the hivemind registry
--------------------------------------

         Key: TAPESTRY-717
         URL: http://issues.apache.org/jira/browse/TAPESTRY-717
     Project: Tapestry
        Type: Improvement
    Versions: 4.0    
    Reporter: Ron Piterman


Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).

This is also a J2EE compatibility issue. 
If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.

wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org


[jira] Updated: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Brian K. Wallace (JIRA)" <ta...@jakarta.apache.org>.
     [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=all ]

Brian K. Wallace updated TAPESTRY-717:
--------------------------------------

    Component: Framework

> Easier accessing the hivemind registry
> --------------------------------------
>
>          Key: TAPESTRY-717
>          URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>      Project: Tapestry
>         Type: Improvement

>   Components: Framework
>     Versions: 4.0
>     Reporter: Ron Piterman

>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Norbert Sándor (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12459851 ] 
            
Norbert Sándor commented on TAPESTRY-717:
-----------------------------------------

I agree with Navin.
Besides in more complex applications I often find it necessary to access hivemind services from POJOs.

There is a related hivemind issue as well: http://issues.apache.org/jira/browse/HIVEMIND-179

> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>         Assigned To: Jesse Kuhnert
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Ron Piterman (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12459869 ] 
            
Ron Piterman commented on TAPESTRY-717:
---------------------------------------

There are some usecases in which one needs such an access, for me the most important one is sharing information across the context.

For example, if one decides to use the same hivemind registry tapestry uses (and not spring or another IoC container) for some front-end services, and want's to share those services in the context.

I would like to enhance this feature request and ask to externalize all state obejct access to static methods:

e.g, in the session state manager, add:

public static Object getStateObject( HttpSession session , String tapestryServletName, String stateName );

or in the context state manager, add:

public static Object getStateObject( ServletContext ctx, String tapestryServletName , String stateName );

or in case of registry:

public static Registry getHivemindRegistry( ServletContext ctx, String tapestryServletName );



BTW, I don't think static-storing of the registry is possible due to clustering issues, we must always use the ServletContext.
Currently, it is alsa possible to access the registry: copy the key tapestry uses to store the registry in the context, add the servlet name, and peek it - but this is not very "nice"...



> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>         Assigned To: Jesse Kuhnert
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Updated: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Jesse Kuhnert (JIRA)" <ta...@jakarta.apache.org>.
     [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=all ]

Jesse Kuhnert updated TAPESTRY-717:
-----------------------------------

    Fix Version/s: 4.1.2

> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Ron Piterman (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12332685 ] 

Ron Piterman commented on TAPESTRY-717:
---------------------------------------

On second thought, JNDI would expose the whole application outside of the context, which is naturally out of question. So another solution would be great...


> Easier accessing the hivemind registry
> --------------------------------------
>
>          Key: TAPESTRY-717
>          URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>      Project: Tapestry
>         Type: Improvement
>     Versions: 4.0
>     Reporter: Ron Piterman

>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Jesse Kuhnert (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12459853 ] 
            
Jesse Kuhnert commented on TAPESTRY-717:
----------------------------------------

In response to Navin,

The way that most of the enhancement workers do this is by simply injecting the reference to the service in question into the enhancement worker where it is further injected into the component/page/etc in question. 

Because of the way that hivemind dynamically creates proxies that hide the relationship between the object you are injected and which actual hivemind service is used at the time of invocation it should really just be "magic" to people using the service. 

So, I still don't see why in this particular instance direct access to the registry is needed. I'm still being open minded about it, but so far in my experience about 99% of the time people want this it means that they just aren't understanding/using hivemind to its fullest potential. 


> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>         Assigned To: Jesse Kuhnert
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Resolved: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Jesse Kuhnert (JIRA)" <ta...@jakarta.apache.org>.
     [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=all ]

Jesse Kuhnert resolved TAPESTRY-717.
------------------------------------

    Resolution: Won't Fix
      Assignee: Jesse Kuhnert

> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>         Assigned To: Jesse Kuhnert
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "B.S.Navin (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12459817 ] 
            
B.S.Navin commented on TAPESTRY-717:
------------------------------------

I think that this is more of a question of "ease of doing" rather than "not able to do".

One case where I preferred having direct access to the hivemind registry, is in Enhancement Workers - I had one enhancement worker, where the code generates  needed to use a hivemind service (Ognl service). I had 2 alternatives - 

1. Add an inject specification into the component that injects the required hivemind service. Make sure that my EW gets called before other related EWs and then generate code to call to the get method to get the service

2. Get hold of hivemind registry from some static method and call a getService() on it.

I would say, that the second approach is much simpler to implement, provided that the hivemind registry was directly accessible.

> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>         Assigned To: Jesse Kuhnert
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


[jira] Commented: (TAPESTRY-717) Easier accessing the hivemind registry

Posted by "Jesse Kuhnert (JIRA)" <ta...@jakarta.apache.org>.
    [ http://issues.apache.org/jira/browse/TAPESTRY-717?page=comments#action_12459787 ] 
            
Jesse Kuhnert commented on TAPESTRY-717:
----------------------------------------

I think I'd first like to know what problems are being solved by making the registry easier to get access to. 

I believe this is currently actually done on purpose, ie "by design". I really doubt there is anything you need to do that couldn't/shouldn't be done using built-in hivemind service capabilities but I'm open to suggestion. 

Closing this out for now but will happily re-open if anyone cares enough to throw in some more thoughts.

> Easier accessing the hivemind registry
> --------------------------------------
>
>                 Key: TAPESTRY-717
>                 URL: http://issues.apache.org/jira/browse/TAPESTRY-717
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.0
>            Reporter: Ron Piterman
>             Fix For: 4.1.2
>
>
> Currently, the servlet stores the hivemind registry in the content, but provides no easy way of obtaining access to it. Both the prefix and the _registry members are private, so one must hack in order to access it ( by hack I also mean just copying the registry prefix to another visible static member).
> This is also a J2EE compatibility issue. 
> If one wishes to integrate Tapestry with other features, the hivemind registry is essential.
> Currently I stumble on a SessionListener, which needs to do some cleanu, and depends on ASOs and Hivemind (custom) services to do so.
> wouldn't it be possible to "publish" the registry using JNDI ?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org