I have a SqlServer source and a OpenFga sink with the following plan
INSERT INTO openfga
SELECT
'company' as user_type,
company.Id as user_id,
'company_of' as relation,
'organization' as object_type,
company.OrganizationId as object_id
FROM [MyDB].[dbo].[Company] company;
The OrganizationId column type is uniqueidentifier and it fails to be written to openfga with the following error.
fail: FlowtideDotNet.Base.Engine.Internal.StateMachine.StreamContext[25]
Stream error, stream: `stream`
System.AggregateException: One or more errors occurred. (Unsupported type Blob)
---> System.InvalidOperationException: Unsupported type Blob
at FlowtideDotNet.Connector.OpenFGA.Internal.FlowtideOpenFgaSink.ColumnToString(FlxValueRef& flxValue)
at FlowtideDotNet.Connector.OpenFGA.Internal.FlowtideOpenFgaSink.GetClientTupleKey(SimpleChangeEvent row)
at FlowtideDotNet.Connector.OpenFGA.Internal.FlowtideOpenFgaSink.UploadChanges(IAsyncEnumerable`1 rows, Watermark watermark, CancellationToken cancellationToken)
at FlowtideDotNet.Connector.OpenFGA.Internal.FlowtideOpenFgaSink.UploadChanges(IAsyncEnumerable`1 rows, Watermark watermark, CancellationToken cancellationToken)
at FlowtideDotNet.Core.Operators.Write.SimpleGroupedWriteOperator.SendData()
at FlowtideDotNet.Core.Operators.Write.SimpleGroupedWriteOperator.Checkpoint(Int64 checkpointTime)
at FlowtideDotNet.Core.Operators.Write.GroupedWriteBaseOperator`1.OnCheckpoint(Int64 checkpointTime)
at FlowtideDotNet.Base.Vertices.Egress.EgressVertex`2.HandleCheckpoint(ICheckpointEvent checkpointEvent)
at FlowtideDotNet.Base.Vertices.Egress.Internal.NonParallelEgressVertex`1.HandleLockingEvent(ILockingEvent lockingEvent)
--- End of inner exception stack trace ---
I would expect the unique identifier to be written as a string.
I tried adding the LOWER() function LOWER(company.OrganizationId) as object_id, the error goes away but the object_id value always is null.
Hello,
I have a SqlServer source and a OpenFga sink with the following plan
The
OrganizationId
column type isuniqueidentifier
and it fails to be written to openfga with the following error.I would expect the unique identifier to be written as a string.
I tried adding the LOWER() function
LOWER(company.OrganizationId) as object_id
, the error goes away but theobject_id
value always isnull
.Regards