Skip to content
This repository was archived by the owner on Jun 27, 2023. It is now read-only.
This repository was archived by the owner on Jun 27, 2023. It is now read-only.

Reflection very slow and using a lot of memory #205

@grahamburgsma

Description

@grahamburgsma

I have a table with over 100 columns. Using migrations addProperties(to: builder) has no issues, but when specifying each column using builder.field(for: \.myColumn), then bad things happen.

Memory usage climbs to over 100mb and the execution is frozen for ~1 minute. From profiling, I believe CodableReflection is the cause of this, specifically this function:
public static func anyDecodeProperty(valueType: Any.Type, keyPath: AnyKeyPath) throws -> ReflectedProperty?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions