Uploaded image for project: 'QuickFIX/J'
  1. QuickFIX/J
  2. QFJ-625

Intermittent File Handle Issues While Generating Code

    Details

    • Type: Bug
    • Status: Open
    • Priority: Default
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Build
    • Labels:
    • Environment:
      Windows 7 Professional x64 (latest updates)
      java version "1.6.0_26"
      Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
      Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02, mixed mode)

      Description

      Intermittently, we're having the following error while running the default ant task:

      [java] SEVERE: error during code generation
      [java] quickfix.codegen.CodeGenerationException: java.io.FileNotFoundException: target\generated-sources\messages\quickfix\fix50\component\UnderlyingInstrument.java (The requested operation cannot be performed on a file with a user-mapped section open)

      The following patch has worked so far:

      Index: quickfixj-local/core/src/main/java/quickfix/codegen/MessageCodeGenerator.java
      ===================================================================
      — quickfixj-local/core/src/main/java/quickfix/codegen/MessageCodeGenerator.java (revision xyz)
      +++ quickfixj-local/core/src/main/java/quickfix/codegen/MessageCodeGenerator.java (working copy)
      @@ -269,8 +269,11 @@
      }

      File outputFile = new File(outputFileName);

      • if (!task.isOverwrite() && outputFile.exists()) {
      • return;
        + if (outputFile.exists())
        Unknown macro: {+ if (!task.isOverwrite()) { + return; + }+ outputFile.delete(); }

      DOMSource source = new DOMSource(document);

      Thanks,
      François

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              francois Francois Auger
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: