Safe Haskell | None |
---|---|
Language | Haskell2010 |
Google Fusion Table upload of benchmark data.
This module must be used in conjunction with the main "hsbencher" package, e.g. "import HSBencher".
- defaultFusionPlugin :: FusionPlug
- data FusionConfig = FusionConfig {}
- stdRetry :: String -> OAuth2Client -> OAuth2Tokens -> IO a -> BenchM (Maybe a)
- getTableId :: OAuth2Client -> String -> BenchM (TableId, [String])
- fusionSchema :: [(String, CellType)]
- resultToTuple :: BenchmarkResult -> [(String, String)]
- uploadBenchResult :: BenchmarkResult -> BenchM ()
- data FusionPlug
- data FusionCmdLnFlag
The plugin itself, what you probably want
defaultFusionPlugin :: FusionPlug Source
A default plugin. This binding provides future-proof way to get a default instance of the plugin, in the eventuality that more configuration options are added in the future.
Details and configuration options.
data FusionConfig Source
Configuration options for Google Fusion Table uploading.
FusionConfig | |
|
stdRetry :: String -> OAuth2Client -> OAuth2Tokens -> IO a -> BenchM (Maybe a) Source
The standard retry behavior when receiving HTTP network errors. Note that this can retry for quite a long while so it is only to be usedfrom batch applications.
getTableId :: OAuth2Client -> String -> BenchM (TableId, [String]) Source
Get the table ID that has been cached on disk, or find the the table in the users Google Drive, or create a new table if needed.
In the case of a preexisting table, this function also performs sanity checking comparing the expected schema (including column ordering) to the sserver side one. It returns the permutation of columns found server side.
fusionSchema :: [(String, CellType)] Source
A representaton used for creating tables. Must be isomorphic to
BenchmarkResult
. This could perhaps be generated automatically
(e.g. from a Generic instance, or even by creating a default
benchmarkResult and feeding it to resultToTuple).
Note, order is important here, because this is the preferred order we'd like to have it in the Fusion table.
resultToTuple :: BenchmarkResult -> [(String, String)]
Convert the Haskell representation of a benchmark result into a tuple for upload to a typical database backend.
uploadBenchResult :: BenchmarkResult -> BenchM () Source
Upload the raw data, which had better be in the right format. uploadRawTuple :: [(String,String)] -> BenchM () uploadRawTuple tuple = do
Push the results from a single benchmark to the server.
data FusionPlug Source
The type of Fusion table plugins. Currently this is a singleton type; there is really only one fusion plugin.
Eq FusionPlug | |
Ord FusionPlug | |
Read FusionPlug | |
Show FusionPlug | |
Default FusionPlug | This is the same as defaultFusionPlugin |
Plugin FusionPlug | |
type PlugConf FusionPlug = FusionConfig | |
type PlugFlag FusionPlug = FusionCmdLnFlag |
data FusionCmdLnFlag Source
Parsed command line options provided by the user initiating benchmarking.