You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by "Dan Bentley (JIRA)" <ji...@apache.org> on 2008/05/26 04:31:55 UTC

[jira] Created: (SHINDIG-307) Default to using state file from this server, no matter what port

Default to using state file from this server, no matter what port
-----------------------------------------------------------------

                 Key: SHINDIG-307
                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
             Project: Shindig
          Issue Type: Improvement
          Components: RESTful API (Java)
            Reporter: Dan Bentley


We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599764#action_12599764 ] 

Kevin Brown commented on SHINDIG-307:
-------------------------------------

Both the common and gadget renderer artifacts use properties files. I thought social-api already had one, but if not you can add one trivially.

The default file location should be wherever the default state file is served from. If the default location is localhost:8080/foo/bar/statefile.xml, that's what should go in the properties file. If someone modifies the default config to use a different port or context path or whatever, they can just edit that properties file.

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Cassie Doll (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599793#action_12599793 ] 

Cassie Doll commented on SHINDIG-307:
-------------------------------------

You can just use guice to inject the string. That's really the cleanest way. 

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Dan Bentley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599746#action_12599746 ] 

Dan Bentley commented on SHINDIG-307:
-------------------------------------

Yeah; that's a reasonable point.

In fact, this patch doesn't even work when the port isn't specified on the command line (i.e, the default case).

But is the samplecontainer expected to work without jetty?  This file is purely for the samplecontainer, which seems far more limited than "shindig".  What are we allowed to assume?

And what's a better way of doing this.  Is there a reasonable way of figuring out where I'm serving, so that I can make a URL incorporating it?

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599745#action_12599745 ] 

Kevin Brown commented on SHINDIG-307:
-------------------------------------

You can't depend on a jetty-specific property. Shindig is not tied to jetty.

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Dan Bentley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599761#action_12599761 ] 

Dan Bentley commented on SHINDIG-307:
-------------------------------------

I'd be happy to do that; do you have any examples of where shindig does that already?

But it still seems that, for the sample container, the default state file ought to be relevant to the sample container, right?

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599796#action_12599796 ] 

Kevin Brown commented on SHINDIG-307:
-------------------------------------

That's exactly right; using the Named annotation binding from a properties is the preferred way to go about this, as is done everywhere else in the code base where a global configuration value is used.

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Dan Bentley (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dan Bentley updated SHINDIG-307:
--------------------------------

    Attachment: port.patch

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-307) Default to using state file from this server, no matter what port

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599760#action_12599760 ] 

Kevin Brown commented on SHINDIG-307:
-------------------------------------

Why not just stick this url in a properties file so that anyone running this can modify it for whatever they're running in?

> Default to using state file from this server, no matter what port
> -----------------------------------------------------------------
>
>                 Key: SHINDIG-307
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-307
>             Project: Shindig
>          Issue Type: Improvement
>          Components: RESTful API (Java)
>            Reporter: Dan Bentley
>         Attachments: port.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> We should default to using the state file from the same server, even when it's not on port 8080.  Instead, use the system property jetty.port to construct the default state file uri.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.