You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Erwan de FERRIERES (Created) (JIRA)" <ji...@apache.org> on 2012/03/27 12:51:26 UTC

[jira] [Created] (OFBIZ-4763) create and use startup profiles

create and use startup profiles
-------------------------------

                 Key: OFBIZ-4763
                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
             Project: OFBiz
          Issue Type: New Feature
    Affects Versions: SVN trunk
            Reporter: Erwan de FERRIERES
            Assignee: Erwan de FERRIERES
             Fix For: SVN trunk


from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html

we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13274233#comment-13274233 ] 

Jacques Le Roux commented on OFBIZ-4763:
----------------------------------------

Also related to the comment above, I was wondering about ports in serviceengine.xml, I mean
{code}
<service-location name="main-rmi" location="rmi://localhost:1099/RMIDispatcher"/>
<service-location name="entity-sync-rmi" location="rmi://localhost:1099/RMIDispatcher"/>
<service-location name="rita-rmi" location="rmi://localhost:1099/RMIDispatcher"/>
{code}
                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Markus M. May (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13239903#comment-13239903 ] 

Markus M. May commented on OFBIZ-4763:
--------------------------------------

Hello,

I would like to use the following process, like already written in the ML (see above thread):

1) read environment variables
2) read variables from a set "profile"-properties file
3) read default variables
4) set variables in the configuration-XML-files of ofbiz 

The profile-specific properties (e.g. local, test, production) are read from the profile-properties files, which are named like the profile (above mentioned local, test and production) and which are chosen based on the environment variable "profile". 
So, if a variable -Dprofile=local is given on the ant command line, the property file runtime/config/local.properties is read. If no variable is given a default value is used (local?). All variables set in these files can be set via command line parameters as well.

The main point here is now how to replace the variables in the already existing configuration files (e.g. framework/base/config/ofbiz-containers.xml). IMHO, we should move these configuration files to the framework/base/conf-templates directory and put the variables (e.g. ${port}) in there. On the call of the "config"-task in ant (which is a dependency of the "run"-task) these files are copied and the variables are replaced through the set values.

This would mean, that we do move several files and put the original ones into the .gitignore, .hgignore, svn:ignore properties/files. Most probably we would also need to check if these files do exist in the platform specific startup-scripts, otherwise the ant-task would need to get called or an error message is to be thrown.

We need to define, what kind of properties we would like to configure centrally. This could be a "start small" approach or an "all or nothing" approach. I would like to keep it simple and just start with the hostname and port-stuff, which is the reason why this issue came up.

WDYT?



                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13240307#comment-13240307 ] 

Jacques Le Roux commented on OFBIZ-4763:
----------------------------------------

I think that before doing anytning we need to review all suggestions (including David's) and make a mix of them keeping the best on consensus.
This could be done here of if really complicated in a new dev thread
                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Michael Brohl (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13239940#comment-13239940 ] 

Michael Brohl commented on OFBIZ-4763:
--------------------------------------

Hi everyone,

interesting discussion for me, because I proposed a similar solution in 2008 (as described in http://ofbiz.135035.n4.nabble.com/contribution-configurable-OFBiz-configuration-td190566.html).

We are using it for a few years now and it simplifies things a lot.

The mechanism does not cover all properties in all configuration files, it's primarily used for the system stages we normally have (development, testing, acceptance, production) and mainly covers ports, security, caching, connectors, urls and such.

We are still willing to contribute ;-)

Regards,

Michael


                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13259280#comment-13259280 ] 

Jacques Le Roux commented on OFBIZ-4763:
----------------------------------------

We need also to take into account ofbiz.admin.port in start.properties 

                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13253775#comment-13253775 ] 

Jacques Le Roux commented on OFBIZ-4763:
----------------------------------------

I closed OFBIZ-3162 as duplicate
                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13264486#comment-13264486 ] 

Jacques Le Roux commented on OFBIZ-4763:
----------------------------------------

We need to take into account: http://svn.apache.org/viewvc?view=revision&revision=1330778
                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (OFBIZ-4763) create and use startup profiles

Posted by "Jacques Le Roux (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux reassigned OFBIZ-4763:
--------------------------------------

    Assignee: Jacques Le Roux  (was: Erwan de FERRIERES)
    
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Jacques Le Roux
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (OFBIZ-4763) create and use startup profiles

Posted by "Markus M. May (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-4763?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13240311#comment-13240311 ] 

Markus M. May commented on OFBIZ-4763:
--------------------------------------

I really do like the solution Michael proposed (I am currently working with this one). In the light of the "OFBIZ diet" I definitly would like to suggest to keep the "configuration-templates" in the corresponding components (in contrast to Michaels solution). Furthermore we probably need to adopt the solution slightly in that the profile configuration files should be splitted, so that there is not a "central, big configuration" like e.g. local.properties, but ones for components e.g. local-base.properties or production-base.properties.

I guess that not all configuration parameters could/should be stored in the DB (e.g. port configurations, or even db connection parameters itself). Therefor we do have IMHO two kind of properties, technical and functional properties. Technical properties are more likely to not end up in the db and these should definitly be configured in property files and these are right now not really easy to handle. 

WDYT?
                
> create and use startup profiles
> -------------------------------
>
>                 Key: OFBIZ-4763
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4763
>             Project: OFBiz
>          Issue Type: New Feature
>    Affects Versions: SVN trunk
>            Reporter: Erwan de FERRIERES
>            Assignee: Erwan de FERRIERES
>             Fix For: SVN trunk
>
>
> from this thread http://ofbiz.135035.n4.nabble.com/OFBiz-integration-in-Apache-sonar-instance-td4484597.html
> we should be able to choose a profile when starting OFBiz, which will configure at least the ports used.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira