Does segment.io servers really route events to multiple destinations or the mobile sdk do?

274 Views Asked by At

I am facing difficulty to understand how segment.io works.

Segment has explained that all data is sent to them (segment servers) and then it will be routed to destinations.

From https://segment.com/docs/guides/general/what-is-segment/

You just send your data to us, then we translate and route it to all of your tools

But when I checked the one of the open sourced integration with CleverTap, It looks like the mobile application is sending the events to CleverTap directly, without going through Segment Servers. Here are code snippets.

https://github.com/CleverTap/clevertap-segment-android/blob/master/src/main/java/com/segment/analytics/android/integrations/clevertap/CleverTapIntegration.java

cl.pushEvent(event, properties);

Here cl is CleverTap API, which is also opensourced at

https://github.com/CleverTap/clevertap-android-sdk/blob/master/clevertap-android-sdk/src/main/java/com/clevertap/android/sdk/CleverTapAPI.java

Here eventually the pushed events are batched and send to Clevertap server.

https://github.com/CleverTap/clevertap-android-sdk/blob/master/clevertap-android-sdk/src/main/java/com/clevertap/android/sdk/CleverTapAPI.java#L2207

So, is there any role of Segment servers in this process or not at all? If segment servers are not involved then I guess the more integrations you add the more of your users internet data will be consumed. Is this right?

1

There are 1 best solutions below

2
Darshan Pania On

If you are using a bundled SDK like the CleverTap Segment SDK, then data is tracked by Segment and CleverTap. You can see in CleverTapIntegration.java that Segment methods are overriden. If you call any Segment function like identify() then internally data is also sent to CleverTap.