Closed Mercy811 closed 2 years ago
Applied https://github.com/amplitude/Amplitude-Go/commit/1ef72e780994144384aa3434f26cbaf681b81927. And for my understanding what it does:
EnrichmentPlugin
and DestinationPlugin
interfaces instead of structEnrichmentPlugin
inlcudes BEFORE
and ENRICHMENT
plugins, and use MiddlewarePriority
to distinguish themPlugins
into middlewarePlugins
and destinationPlugins
Changes in https://github.com/amplitude/Amplitude-Go/pull/6/commits/28364c5b50e1c6c74b9fbec6dad93ae5a22a02d8 for API consistency:
client.add(plugin)
client.remove(plugin)
MiddlewarePlugin
to EnrichmentPlugin
Summary
add()
andremove()
to add and remove pluginsprocess()
to process/enrich eventsflush()
andshutdown()
sends events to assigned destinationsEnrichmentPlugin
for BEFORE and ENRICHMENT typeDestinationPlugin
for DESTINATION typeChecklist