You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "John Sisson (JIRA)" <de...@geronimo.apache.org> on 2006/06/09 07:43:29 UTC

[jira] Created: (GERONIMO-2097) PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open

PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open
---------------------------------------------------------------------------------------

         Key: GERONIMO-2097
         URL: http://issues.apache.org/jira/browse/GERONIMO-2097
     Project: Geronimo
        Type: Bug
    Security: public (Regular issues) 
  Components: core, Plugins  
    Versions: 1.1    
    Reporter: John Sisson
    Priority: Trivial
     Fix For: 1.1.1


The code contains the following statement, where the mavenFile variable is a File.

xform.transform(new DOMSource(doc), new StreamResult(mavenFile));

We have experienced in another issue ( GERONIMO-2095 ) that this does not close the FileOutputStream that gets created automatically on your behalf.

It is safer to create your own FileOutputStream and pass it on the StreamResult constructor and ensure it is closed in a finally block. See fix for GERONIMO-2095 for an example. 

Since this is in a standalone tool, it probably isn't a high priority as the file will be closed when the JVM terminates, but this may not always be used as a standalone tool.

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


[jira] Closed: (GERONIMO-2097) PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open

Posted by "Aaron Mulder (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2097?page=all ]

Aaron Mulder closed GERONIMO-2097.
----------------------------------

    Resolution: Won't Fix
      Assignee: Aaron Mulder

Removed PluginRepositoryExporter

> PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open
> ---------------------------------------------------------------------------------------
>
>                 Key: GERONIMO-2097
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2097
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: core, Plugins
>    Affects Versions: 1.1
>            Reporter: John Sisson
>         Assigned To: Aaron Mulder
>            Priority: Trivial
>             Fix For: 1.1.x
>
>
> The code contains the following statement, where the mavenFile variable is a File.
> xform.transform(new DOMSource(doc), new StreamResult(mavenFile));
> We have experienced in another issue ( GERONIMO-2095 ) that this does not close the FileOutputStream that gets created automatically on your behalf.
> It is safer to create your own FileOutputStream and pass it on the StreamResult constructor and ensure it is closed in a finally block. See fix for GERONIMO-2095 for an example. 
> Since this is in a standalone tool, it probably isn't a high priority as the file will be closed when the JVM terminates, but this may not always be used as a standalone tool.

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

        

[jira] Updated: (GERONIMO-2097) PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open

Posted by "Alan Cabrera (JIRA)" <de...@geronimo.apache.org>.
     [ http://issues.apache.org/jira/browse/GERONIMO-2097?page=all ]

Alan Cabrera updated GERONIMO-2097:
-----------------------------------

    Fix Version/s: 1.1.x
                       (was: 1.1.1)

Moving unassigned issues over to the 1.1.x pool where they can be worked on for the, in all probability, 1.1.2 patch.

> PluginRepositoryExporter.updateMavenMetadata(..) may leave maven-metadata.xml file open
> ---------------------------------------------------------------------------------------
>
>                 Key: GERONIMO-2097
>                 URL: http://issues.apache.org/jira/browse/GERONIMO-2097
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: core, Plugins
>    Affects Versions: 1.1
>            Reporter: John Sisson
>            Priority: Trivial
>             Fix For: 1.1.x
>
>
> The code contains the following statement, where the mavenFile variable is a File.
> xform.transform(new DOMSource(doc), new StreamResult(mavenFile));
> We have experienced in another issue ( GERONIMO-2095 ) that this does not close the FileOutputStream that gets created automatically on your behalf.
> It is safer to create your own FileOutputStream and pass it on the StreamResult constructor and ensure it is closed in a finally block. See fix for GERONIMO-2095 for an example. 
> Since this is in a standalone tool, it probably isn't a high priority as the file will be closed when the JVM terminates, but this may not always be used as a standalone tool.

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