I need to pass INamespace to CloudMapOptions in order that the ECS tasks register to the AWS CloudMap, I get following error. I can't decouple them with CfnOutput, because I need the namespace in the ECS cloudMapOptions:
Stack "users" cannot consume a cross reference from stack "servicediscovery". Cross stack references are only supported for stacks deployed to the same environment or between nested stacks and their parent stack.
I tried this : https://bobbyhadz.com/blog/aws-cdk-share-vpc-between-stacks, but without any success. How can I pass a variable of type INamespace between stacks?