Giter Site home page Giter Site logo

Synchronous mode about analytics-ruby HOT 12 CLOSED

segmentio avatar segmentio commented on July 23, 2024
Synchronous mode

from analytics-ruby.

Comments (12)

nozpheratu avatar nozpheratu commented on July 23, 2024 2

@drubin Be warned, I ran into some issues trying to build my own synchronous wrapper for event logging and then incorporating it into my existing queuing system. As I understand it segment uses some kind of strange batch on their servers to queue logging and for whatever reason it isn't first come first serve and if multiple events are logged at nearly the same time they won't be logged in guaranteed order.

Since I only needed the event logging for GA I ended up just using Staccato.

from analytics-ruby.

drubin avatar drubin commented on July 23, 2024 1

👍 Assuming how a server is setup and architectured for a "http lib" is generally a bad idea.

Servers that implement queues/background workers will do it much better than a simple in memory queue and servers that don't need a background queue system won't have one.

Sidekiq/delayed job/sucker punch/ all do queue'ing as their SINGLE job and even they have issues. You should make your docs/integration plan easier to use with external queue systems.

from analytics-ruby.

whatthewhat avatar whatthewhat commented on July 23, 2024 1

@nozpheratu thanks for the warning! I think the ordering issue could be solved in some cases by manually batching events using import.

We did end up starting a synchronous wrapper over at https://github.com/whatthewhat/simple_segment, but batching events is not implemented yet.

update: batching is merged and released to rubygems.

from analytics-ruby.

sperand-io avatar sperand-io commented on July 23, 2024 1

@whatthewhat FYI, we're linking to your library as an alternative from our docs. Big thank you for your contribution! :)

from analytics-ruby.

christophe-dufour avatar christophe-dufour commented on July 23, 2024

👍

from analytics-ruby.

erickreutz avatar erickreutz commented on July 23, 2024

👍

from analytics-ruby.

nozpheratu avatar nozpheratu commented on July 23, 2024

👍

from analytics-ruby.

whatthewhat avatar whatthewhat commented on July 23, 2024

A question for maintainers: Is this something that can be potentially added to this client?

This is currently painful enough, that I'm considering writing a separate simple synchronous API wrapper for our use case.

from analytics-ruby.

drubin avatar drubin commented on July 23, 2024

@whatthewhat I am also busy writing my own synchronous API wrapper.

Currently I have wrapped every method call in a

def track(params)
   analytics.track(params)
   analytics.flush
end

But honestly with the complexity of querying am more keen to have stable simplistic code. Since I already have a queuing system with proper workers/threaded pools.

from analytics-ruby.

drubin avatar drubin commented on July 23, 2024

@nozpheratu I have also given up on segment. Their staff are totally unresponsive. Their API's make bad design decisions and after much struggling trying to integrate it for more than a day (Legacy mixpanel data/formats trying to sync up their custom wrappers while still maintaining legacy events formats) I gave up.

I see the value segment.io adds in massive companies where marketing/customer service do not have control of production or can't write a line of code and switch out analytics frameworks every 2 weeks. But for engineers I see little value in a API proxy service they provide.

The fact not a single segment employee has responded on tickets in months is a clear indication their target markets aren't people that can use github.

from analytics-ruby.

nozpheratu avatar nozpheratu commented on July 23, 2024

@drubin Actually, I still use Analytics.js on the client for some things. Regarding their support, have you tried emailing them directly? I personally have had really helpful and prompt responses from both their developers and support staff despite being on the free plan using this page: https://segment.com/contact

from analytics-ruby.

whatthewhat avatar whatthewhat commented on July 23, 2024

Awesome, thanks!

from analytics-ruby.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.