I am developing an endpoint using the SQS Transport, and I found the documentation for custom topic mappings, but my topic is still being created as EndpointName-EventTypeFullName.
Here is a snippet of the relevant endpoint configuration:
var credentials = new BasicAWSCredentials(“myKey”, “mySecret”);
var sqsClient = new AmazonSQSClient(credentials, RegionEndpoint.USEast1);
var snsClient = new AmazonSimpleNotificationServiceClient(credentials, RegionEndpoint.USEast1);
var sqsTransport = new SqsTransport(sqsClient, snsClient);sqsTransport.MapEvent(“myCustomTopicName”);
endpoint.UseTransport(sqsTransport);
If I am doing something wrong above, I am having a hard time spotting it.
Edit: I think I am going crazy, but today, the custom topic name is sort of working. I am getting a topic named “myCustomTopicName”, but I am also getting one named “EndpointName-EventTypeFullName”. I would only expect the former to be created.
I am also aware of the queue/topic name prefix and generator properties on the SqsTransport, but I would prefer to use MapEvent as I believe it is more clear. I also cannot find documentation on what the arguments to the QueueNameGenerator and TopicNameGenerator functions. If someone could provide some clarity on that, it would be very helpful. I’ve partially figured it out by running in the debugger and inspecting the values, but the second value to the TopicNameGenerator is always null with the events I have, so I can’t tell what that is for.