geenRoutine/

directory
v5.9.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 10, 2023 License: MIT

README

Vostok/geenRoutine example

To go back to Vostok: here.


Introduction

The code here is about creating routine within a Vostok/Geen server project.

This example illustrates several things:

  • the way 'routines' can be created and released
  • how logging from a routine affects the logs

Top


Building the project & starting the server

To build

go build -i -o $GOPATH/src/bitbucket.org/oscaroscar/vostok/examples/geenRoutine/bin/geenRoutine -v bitbucket.org/oscaroscar/vostok/examples/geenRoutine/go

To run:

cd $GOPATH/src/bitbucket.org/oscaroscar/vostok/examples/geenRoutine && ./bin/geenRoutine -config=conf/example.dev.localhost.json

One-liner for building and restarting right away (assuming the previous cd has been run):

go build -i -o bin/geenRoutine -v ./go && ./bin/geenRoutine -config=conf/example.dev.localhost.json

Top


To test

curl http://localhost:10101/routineexample/rest/output/read

Top


Let's see what's happening

  • Logs are created from routines, and the line prefixes reflect the scope that each routine represents
  • Some log lines are about the routine pool. But not all of them appear. They depend on the configure LogThreshold

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL