github.com/erocheleau/uabot
go get github.com/erocheleau/uabot

github.com/erocheleau/uabot

Bot to generate data for Usage Analytics

by coveooss

v0.4.6 (see all)License:Apache-2.0
go get github.com/erocheleau/uabot
Readme

uabot Build Status Go Report Card license

Bot to send "intelligent" random usage analytics to simulate visits, queries and clicks on a site. Works with a configuration file using json format. Check the /scenarios_examples folder for examples.

How to use:

  1. Download executable.
  2. Set Environment variables (refer to the section below).
  3. Build your scenarios (How to build scenarios).
  4. Execute the bot.

Tracing

You can use the argument -trace to get more logs when debugging your scenarios.

Examples of scenarios


Usage documentation

Code documentation

Supports

  • Search events
  • Click events
  • Custom events
  • Facet events
  • View events
  • TabChange events

Environment variables

Needs 3 environment variables to function :

VariableUsage
SEARCHTOKENAPI key to search
UATOKENAPI key to send events to UA
SCENARIOSURLUrl to the scenario JSON file to randomize
LOCALtrue for local (default false)

On windows

set SEARCHTOKEN=value
set UATOKEN=value
set SCENARIOSURL=value
set LOCAL=true #if scenariosurl is a local path

On MAC

export SEARCHTOKEN = value
export UATOKEN = value
export SCENARIOSURL = value
export LOCAL=true #if scenariosurl is a local path

Developper section


To build an executable

# Install the dependencies
1. go get
# Build an executable -o sets the output name
2. go build -o myexecutable
3. Run the executable

To trigger a Docker rebuild, push with latest tag

1. Commit your changes
# We need to use the -f option here because tag latest already exists
2. git tag -f -a latest -m "Rebuild reason here"
# Push changes to branch + push changes to tag, you will need to supply credentials twice.
3. git push && git push -f --tags

To release a newer version of the bot, with Travis automated builds

# Create a new tag with the version number to use.
1. git tag -a [v0.9.9] -m "Release comment here"
# Push tag.
2. git push --tags origin master
# It takes a little bit of time for Travis to generate the artefacts
3. Visit https://github.com/coveooss/uabot/releases to view the releases to ensure your new release is visible.

forthebadge

GitHub Stars

12

LAST COMMIT

1yr ago

MAINTAINERS

0

CONTRIBUTORS

23

OPEN ISSUES

2

OPEN PRs

1
VersionTagPublished
v0.4.7-0.20210428185047-7a3428603504
1yr ago
v0.4.2
1yr ago
v0.2.0
1yr ago
v0.3.1
1yr ago
No alternatives found
No tutorials found
Add a tutorial