Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

librariesio/depper

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

121 Commits
121 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

depper

A dapper consumer of ecosystem APIs.

Depper is an ingestor of package releases from multiple ecosystems (each ecosystem is found in ingestors/).

When new package releases are found, they are pushed to a shared redis queue for Libraries.io to process.

Ingestor interface

Ingestors must satisfy the ingestors.PollingIngestor interface. It is currently our only ingestor interface, and schedules ingestion of new versions at specific intervals (ingestor.Schedule()).

Throttling + the TTLer interface

By default a PackageVersion -- unique by Platform/Name/Version -- will be limited to one published event per "ttl", which defaults to 24 hours. This duration can be overridden by implementing the TTLer interface in the ingestor.

Ingestor Cursor Patterns

Depper has to know where to pick up once it restarts, so there are several methods for storing such a cursor:

  • ingestors.setBookmarkTime() + ingestor.getBookmarkTime() [RECOMMENDED] : reads/sets a time.Time to redis (persistent)
  • ingestors.setBookmark() + ingestor.getBookmark(): reads/sets an arbitrary string to redis (persistent)
  • LatestRun: reads/sets a time.Time on the ingestor instance (non-persistent)

Running Locally

go run main.go

Running Tests

go test -v ./...

Running the Linter

You'll need the same version of our linter as CI, so reference the ".circleci/config.yml" for the installation command.

golangci-lint run: this will run the linter.

golangci-lint run --fix: this will run the linter and autofix any autofix-able linter errors.

Deploying

  1. merge PR into main branch
  2. tl setenv libraries
  3. ./bin/deploy.sh

About

Consumer of ecosystem APIs.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 9

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.