You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Bengt Rodehav (Created) (JIRA)" <ji...@apache.org> on 2011/11/15 19:41:52 UTC

[jira] [Created] (KARAF-1014) Make files specified by ${includes} optional

Make files specified by ${includes} optional
--------------------------------------------

                 Key: KARAF-1014
                 URL: https://issues.apache.org/jira/browse/KARAF-1014
             Project: Karaf
          Issue Type: Improvement
          Components: karaf-config
    Affects Versions: 2.2.4
            Reporter: Bengt Rodehav
            Priority: Minor


The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Assigned JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Baptiste Onofré reassigned KARAF-1014:
-------------------------------------------

    Assignee: Jean-Baptiste Onofré
    
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Commented JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152697#comment-13152697 ] 

Jean-Baptiste Onofré commented on KARAF-1014:
---------------------------------------------

Good point Glen. However, we have to enhance the way for the users to provide its custom file. I would prefer to let user use the custom.properties file and clearly replace variables in this file.
                
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] [Closed] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jamie goodyear (Closed) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jamie goodyear closed KARAF-1014.
---------------------------------

    
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 2.2.5, 3.0.0
>
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Glen Mazza (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152599#comment-13152599 ] 

Glen Mazza commented on KARAF-1014:
-----------------------------------

This seems dangerous to do.  If a user explicitly specified a file that will provide some security rules or other important configuration information, but accidentally mistyped the filename in the ${includes}, then Karaf would run without the intended security rules or other configuration occurring *and* quite possibly without the Karaf administrator being aware of that fact.  Nine times out of ten, the would-be Karaf user would be thrilled that Karaf refused to start, and would then fix the problem--moving the proper config file to the directory, removing the config file from the ${includes} property, or fixing the typo over the filename.

                
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Commented JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13174406#comment-13174406 ] 

Jean-Baptiste Onofré commented on KARAF-1014:
---------------------------------------------

Fixed on karaf-2.2.x: revision 1221877 (introduction of ${optionals} property).
                
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 2.2.5, 3.0.0
>
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] [Resolved] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Resolved JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Baptiste Onofré resolved KARAF-1014.
-----------------------------------------

    Resolution: Fixed
    
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 2.2.5, 3.0.0
>
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] [Updated] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Updated JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Baptiste Onofré updated KARAF-1014:
----------------------------------------

    Fix Version/s: 3.0.0
                   2.2.5
    
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 2.2.5, 3.0.0
>
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Jean-Baptiste Onofré (Commented JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13174403#comment-13174403 ] 

Jean-Baptiste Onofré commented on KARAF-1014:
---------------------------------------------

Fixed on trunk: revision 1221872 (introduction of ${optionals} property).
                
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>             Fix For: 2.2.5, 3.0.0
>
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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] (KARAF-1014) Make files specified by ${includes} optional

Posted by "Bengt Rodehav (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/KARAF-1014?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152771#comment-13152771 ] 

Bengt Rodehav commented on KARAF-1014:
--------------------------------------

Glen (and JB),

I agree that it is necessary to "require" a properties file as well as "optionally include" a properties file. I originally wrote that in the description but thought it better to see if there is a need for this. Your comment confirms that this is also a requirement.

I would then propose either:

# Extending the syntax so that it is possible to specify whether the file should be regarded as optional or mandatory.
# Having one property for mandatory includes and another for optional includes. 

The second option is probably the easiest to implement. However, I'm not sure whether ordering might be an issue. Does Karaf perform a multipass evaluation so that all variables can be cross-referenced between the property files or do you only perform a single pass? In the latter case I assume that ordering matters.

The first option lets you specify the ordering and would also let you override mandatory properties. The second option would probably imply that you first evaluate all mandatory files and then all optional files which puts a restriction on how you can order the files. Might be OK I guess and would definitely be easier to implement.

                
> Make files specified by ${includes} optional
> --------------------------------------------
>
>                 Key: KARAF-1014
>                 URL: https://issues.apache.org/jira/browse/KARAF-1014
>             Project: Karaf
>          Issue Type: Improvement
>          Components: karaf-config
>    Affects Versions: 2.2.4
>            Reporter: Bengt Rodehav
>            Assignee: Jean-Baptiste Onofré
>            Priority: Minor
>
> The ${includes} property in custom.properties is used to list property files that will be read and evaluated by Karaf at startup. However, if a file listed this way does not exist, then Karaf fails to start. When using this as a means to give a user the possibility to add custom properties, it makes sense to change this behaviour so that Karaf picks up the file if it exists otherwise it will be ignored and Karaf will continue its startup process.

--
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