Easily read and write Mozilla data
Перейти к файлу
Daniel Thorn 8a3d435704 Fix README code block (#13) 2018-10-31 14:17:46 -07:00
.circleci add python support for rdd apis 2018-10-17 10:44:09 -07:00
project implement scala api 2018-09-14 12:27:57 -07:00
python add python write_table api (#11) 2018-10-31 12:09:57 -07:00
src Implement describeTable in scala 2018-10-17 10:38:05 -07:00
.gitignore implement python sql api 2018-10-15 09:09:56 -07:00
.travis.yml implement scala api 2018-09-14 12:27:57 -07:00
LICENSE Initial commit 2018-06-08 09:50:42 -07:00
README.md Fix README code block (#13) 2018-10-31 14:17:46 -07:00
VERSION implement scala api 2018-09-14 12:27:57 -07:00
build.sbt implement scala api 2018-09-14 12:27:57 -07:00

README.md

Build Status codecov.io

MozData

A consistent API for accessing Mozilla data that reports usage to Mozilla

Using MozData in scala

In SBT:

resolvers += "S3 local maven snapshots" at "s3://net-mozaws-data-us-west-2-ops-mavenrepo/snapshots"
libraryDependencies += "com.mozilla.telemetry" %% "mozdata" % "0.1-SNAPSHOT"

Data Collection

This api sends usage data to telemetry when the env var TELEMETRY_URL is properly set.

On Mozilla servers TELEMETRY_URL should be set to https://incoming.telemetry.mozilla.org

To disable data collection in environment variables:

unset TELEMETRY_URL

or in scala:

import com.mozilla.telemetry.mozdata.MozData
val api: MozData = MozData(telemetryUrl=None)

To enable printing what you are or would be sending in log4j.properties (probably in src/main/resources or src/test/resources):

log4j.logger.com.mozilla.telemetry.mozdata.MozData=DEBUG

or in scala:

import org.apache.log4j.{Logger, Level}
Logger.getLogger(classOf[MozData]).setLevel(Level.DEBUG)

Development

Run tests with sbt

sbt test scalastyle test:scalastyle

License

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.