Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What where? I am a bit lost. What is the current implementation #78

Closed
OriPekelman opened this issue Nov 12, 2013 · 2 comments
Closed
Milestone

Comments

@OriPekelman
Copy link

Hi,

I am a bit at a lost here... If I understand well there are:

  1. A repo for the SVG source (this one)
  2. A go implementation of a daemon
  3. A node.js implementation of a daemon;

Both implementations seem to try to manipulate the SVG file, in a bit of a weird way. Is there a reason this is not simply:

  1. Get params from CLI/URL (the url structure can contain all of the params for example: api.shields.io/travis/passing/darkgray/green.png?height=60 )
  2. If in cache serve cached (this would probably be even a front varnish or something, maybe use cloudfront or another cache)
  3. Get SVG template
  4. Fill template.
  5. Either serve SVG or transform to the content-type requested
  6. Fill cache

This should be performant enough even on Ruby. I mean you can expect a 99.9999 cache hit rate on this. Am I missing something?

@olivierlacan
Copy link
Member

Hi there @OriPekelman! It's nice to see you in these parts.

I understand you're confusion but as you'll read in #84 we're quite in flux at the moment.

We're in the process of switching from the Node.js implementation to the Go one in part for the reasons explained here and for speed. If you can improve the implementation, please submit pull requests to buckler or provide an alternative implementation that at least matches shielded's requirements.

I realize we may need to formalize these requirements in writing on the README to make things easier.

As for caching, some badges are easily cacheable, others not as much. This is something I think we can discuss at a point when we've nailed down more basic improvements we still have to provide.

@chadwhitacre
Copy link
Contributor

Get params from CLI/URL (the url structure can contain all of the params for example: api.shields.io/travis/passing/darkgray/green.png?height=60 )

Where does passing come from? That is variable, no?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants