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

5.0.1 updates #2

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# Mapster

![Kibana Tag Cloud](sec_screenv1.gif)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/893661b4aa2f45378d96c21768b7ea8b)](https://www.codacy.com/app/xarkes/mapster)

Mapster is a real-time event map implemented as a [Kibana](https://github.com/elastic/kibana) [visualization](https://www.elastic.co/guide/en/kibana/current/visualize.html).

# How does it work
Mapster is not truely in real-time. It fetches the events from ElasticSearch using Kibana and replays the events in real
time with a lag corresponding to the Kibana refresh time.
Expand All @@ -15,18 +14,22 @@ To draw the 2D map, Mapster uses [d3js](https://d3js.org/) and it uses [threejs]

# Installation
## Requirements
- Kibana 4.5.0 (the only supported version for now)
- Kibana 5.2.2

## Instructions
Simply clone the repository into your Kibana plugins folder:
```sh
cd installedPlugins && git clone https://github.com/xarkes/mapster
```
mkdir kibana && cd kibana
git clone https://github.com/elastickent/mapster
cd ../
zip -r mapster.zip kibana
$KIBANA_HOME/bin/kibana-plugin install file:///`pwd`/mapster.zip
```

If you are using Kibana from git and starting it in `dev` mode, Kibana will automatically refresh its cache and the plugin
will be successfully loaded.
Otherwise you can force it by stopping kibana, deleting the cache and starting kibana again.
```sh
```
rm -r optimize/bundles
./bin/kibana
```
Expand Down Expand Up @@ -77,8 +80,3 @@ Then you can add any other aggregation if you need to filter your events using t
| Explosion delay (in ms) | The duration in ms of the gif. |
| Number of events in the logs | Number of lines in the event logs table. |
| | |


# Screenshots
![Mapster](/docs/mapster.png?raw=true "Mapster map")
![Mapster](/docs/globe.png?raw=true "Mapster globe")
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"name": "mapster",
"version": "0.0.0"
"version": "5.5.1"
}
3 changes: 1 addition & 2 deletions public/lib/mapster_controller.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var _ = require('lodash');
var geohash = require('plugins/mapster/lib/latlon-geohash.js');

import AggResponseTabifyTabifyProvider from 'ui/agg_response/tabify/tabify';
import { AggResponseTabifyTabifyProvider } from 'ui/agg_response/tabify/tabify';

var module = require('ui/modules').get('mapster');

Expand Down Expand Up @@ -115,4 +115,3 @@ module.controller('MapsterController', function ($scope, Private) {

});
});

19 changes: 13 additions & 6 deletions public/mapster.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,24 @@ require('plugins/mapster/lib/mapster_controller.js');
require('plugins/mapster/lib/mapster_directive.js');
require('plugins/mapster/mapster_params_editor.js');
import 'ui/visualize/visualize_legend';
import { VisTypesRegistryProvider } from 'ui/registry/vis_types';
import { VisSchemasProvider } from 'ui/vis/schemas';
import { TemplateVisTypeProvider } from 'ui/template_vis_type/template_vis_type';
import MapsterTemplate from 'plugins/mapster/mapster.html';
import MapsterParamsEditor from 'plugins/mapster/mapster_params_editor.html'

function mapsterProvider(Private) {
var TemplateVisType = Private(require('ui/template_vis_type/TemplateVisType'));
var Schemas = Private(require('ui/Vis/Schemas'));
// var TemplateVisType = Private(require('ui/template_vis_type/template_vis_type'));
// var Schemas = Private(require('ui/vis/schemas'));
const TemplateVisType = Private(TemplateVisTypeProvider);
const Schemas = Private(VisSchemasProvider);

return new TemplateVisType({
name: 'mapster',
title: 'Mapster',
description: 'MAPSTER MUCH PIEW MUCH WOW',
icon: 'fa-globe',
template: require('plugins/mapster/mapster.html'),
template: MapsterTemplate,
params: {
defaults: {
/* GENERAL */
Expand All @@ -40,7 +47,7 @@ function mapsterProvider(Private) {
ExplosionDelay: 2700,
maximumEvents: 10
},
editor: require('plugins/mapster/mapster_params_editor.html')
editor: MapsterParamsEditor
},
schemas: new Schemas([
{
Expand Down Expand Up @@ -105,5 +112,5 @@ function mapsterProvider(Private) {
});
}

require('ui/registry/vis_types').register(mapsterProvider);

VisTypesRegistryProvider.register(mapsterProvider);
// require('ui/registry/vis_types').register(mapsterProvider);
1 change: 0 additions & 1 deletion public/mapster.less
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
}

mapster {
border: 1px solid black;
width: 99%;
height: 99%;
}
Expand Down
Binary file added sec_screenv1.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.