Skip to content

Parquet file used by another process #3

@smith0505

Description

@smith0505

When using the StandardPlugin to export I'm getting an exception about the created file being used by another process:

ParquetSharp.ParquetException: 'class parquet::ParquetStatusException (message: 'IOError: Failed to open local file '~/source/repos/_machineData/TestData/output/Tillage_2.parquet'. Detail: [Windows error 32] The process cannot access the file because it is being used by another process.
')'

The issue is coming from ADAPTParquet.cs here:

using (var fs = File.Create(outputFile))
{
    using (var writer = new ParquetFileWriter(outputFile, dataFields.ToArray(), keyValueMetadata: geometadata))
    {

It seems that File.Create is creating and locking the file and that the ParquetFileWriter can't access it. Removing using (var fs = File.Create(outputFile)) makes it work for me as ParquestFileWriter writes the file on its own.

Having found it difficult to process geospatial data out of ADAPT Framework, ADAPT Standard and this Plugin is really exciting!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions