You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Ali Naddaf (JIRA)" <ji...@apache.org> on 2009/04/23 20:17:30 UTC

[jira] Created: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
-----------------------------------------------------------

                 Key: FELIX-1055
                 URL: https://issues.apache.org/jira/browse/FELIX-1055
             Project: Felix
          Issue Type: Improvement
          Components: File Install
         Environment: All
            Reporter: Ali Naddaf
            Priority: Minor


A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:

Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
===================================================================
--- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
+++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
@@ -68,7 +68,7 @@
         Object o = context.getProperty(key);
         if (o == null)
         {
-            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
+           o = System.getProperty(key.toUpperCase().replace('.', '_'));
             if (o == null)
             {
                 return;
----------------------------------------------------------------------------------------------------------

The only needed change is in the FileInstall class:
1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
2. Using System.getProperty(..) instead of System.getenv(...)

Thanks,


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


[jira] Resolved: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Clement Escoffier resolved FELIX-1055.
--------------------------------------

    Resolution: Fixed

Fixed in the revision 768149.

I applied the patch, and replaced Boolean.parseBolean.

Close the issue if it's ok for you

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>    Affects Versions: fileinstall-0.9.2
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>             Fix For:  fileinstall-1.0.0
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Updated: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Clement Escoffier updated FELIX-1055:
-------------------------------------

    Affects Version/s: fileinstall-0.9.2
        Fix Version/s:  fileinstall-1.0.0

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>    Affects Versions: fileinstall-0.9.2
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>             Fix For:  fileinstall-1.0.0
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Updated: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Clement Escoffier updated FELIX-1055:
-------------------------------------

              Assignee: Clement Escoffier
    Remaining Estimate: 0h
     Original Estimate: 0h

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Closed: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Ali Naddaf closed FELIX-1055.
-----------------------------


Thanks Clement, works fine.

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>    Affects Versions: fileinstall-0.9.2
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>             Fix For:  fileinstall-1.0.0
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Updated: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Clement Escoffier updated FELIX-1055:
-------------------------------------

    Assignee: Clement Escoffier

Right,

Strange the Since tag on the class says 1.4:

Since:
1.4

So, the only remaining issue is a Boolean.parse(xxx).

Clement

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Commented: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

Posted by "Ali Naddaf (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1055?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12702083#action_12702083 ] 

Ali Naddaf commented on FELIX-1055:
-----------------------------------

Hi Clement.
java.net.URi is part of the CDC-1.1/Foundation 1.1; if you look at the Compendium specs, under OSGi Defined Execution Environment, (section 999.3), you will find that class included in CDC (but not in OSGi-Minumum). Please correct me if I am wrong. I also checked my J9 Found1.1 java runtime environment and java.net.URI class was indeed there.

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>         Environment: All
>            Reporter: Ali Naddaf
>            Priority: Minor
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Updated: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

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

Clement Escoffier updated FELIX-1055:
-------------------------------------

    Assignee:     (was: Clement Escoffier)

Hi,

It seems that the patch is not enough (at least for the trunk version). The code uses java.net.URI that was added in Java 1.4 and is not available in Foundation 1.1. 

> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>         Environment: All
>            Reporter: Ali Naddaf
>            Priority: Minor
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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


[jira] Commented: (FELIX-1055) Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible

Posted by "Filippo Diotalevi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/FELIX-1055?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12702287#action_12702287 ] 

Filippo Diotalevi commented on FELIX-1055:
------------------------------------------

I installed the latest trunk build in my application and it works fine. 
Issue can be closed as far as I'm concerned.



> Making FileInstall bundle CDC-1.1/Foundation 1.1 compatible
> -----------------------------------------------------------
>
>                 Key: FELIX-1055
>                 URL: https://issues.apache.org/jira/browse/FELIX-1055
>             Project: Felix
>          Issue Type: Improvement
>          Components: File Install
>    Affects Versions: fileinstall-0.9.2
>         Environment: All
>            Reporter: Ali Naddaf
>            Assignee: Clement Escoffier
>            Priority: Minor
>             Fix For:  fileinstall-1.0.0
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> A minor change will make File Install bundle compatible with the CDC-1.1/Foundation-1.1 compatible:
> Index: src/main/java/org/apache/felix/fileinstall/FileInstall.java
> ===================================================================
> --- src/main/java/org/apache/felix/fileinstall/FileInstall.java (revision 761715)
> +++ src/main/java/org/apache/felix/fileinstall/FileInstall.java (working copy)
> @@ -68,7 +68,7 @@
>          Object o = context.getProperty(key);
>          if (o == null)
>          {
> -            o = System.getenv(key.toUpperCase().replaceAll(".", "_"));
> +           o = System.getProperty(key.toUpperCase().replace('.', '_'));
>              if (o == null)
>              {
>                  return;
> ----------------------------------------------------------------------------------------------------------
> The only needed change is in the FileInstall class:
> 1. replacing String.replaceAll(String, String) with String.replace(char, char) (since replaceAll is not part of that profile and we are only making one char replacement). If a more robust replaceAll functionality is required, please let me know and I provide a simple implementation.
> 2. Using System.getProperty(..) instead of System.getenv(...)
> Thanks,

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