All Projects → moleculer-go → moleculer

moleculer-go / moleculer

Licence: MIT license
🚀 Progressive microservices framework for Go - based and compatible with https://github.com/moleculerjs/moleculer

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to moleculer

Moleculer
🚀 Progressive microservices framework for Node.js
Stars: ✭ 4,845 (+3488.89%)
Mutual labels:  microservice-framework, moleculer
garuda
Automagically Exposing Django ORM over gRPC for microservices written in any other languages
Stars: ✭ 22 (-83.7%)
Mutual labels:  microservice-framework
Goupaz.com
Community driven open source accelerator
Stars: ✭ 163 (+20.74%)
Mutual labels:  fun
Python Raytracer
A basic Ray Tracer that exploits numpy arrays and functions to work fast.
Stars: ✭ 204 (+51.11%)
Mutual labels:  fun
Hacksby
Description and unofficial implementation of Furby's audio protocol
Stars: ✭ 165 (+22.22%)
Mutual labels:  fun
Floating.js
Float a number of things up on a page (hearts, flowers, emojis, words ...)
Stars: ✭ 209 (+54.81%)
Mutual labels:  fun
Waifu Motivator Plugin
OSS Waifu Motivator Plugin for Jetbrains to help boost your motivation while coding!
Stars: ✭ 160 (+18.52%)
Mutual labels:  fun
dot-rest
a minimalist toolkit for building scalable, fault tolerant and eventually-consistent microservices
Stars: ✭ 46 (-65.93%)
Mutual labels:  microservice-framework
gooz
💨 Send the old sh*tty browsers away from your website as simple as a Gooz
Stars: ✭ 38 (-71.85%)
Mutual labels:  fun
Sudo Productivity
Boost your "productivity" to the max! A fun project made for slackers by slackers.
Stars: ✭ 190 (+40.74%)
Mutual labels:  fun
Libmoji
📚 Bitmoji's API made easy for everyone
Stars: ✭ 189 (+40%)
Mutual labels:  fun
Tinykaboom
A brief computer graphics / rendering course
Stars: ✭ 2,077 (+1438.52%)
Mutual labels:  fun
Oop
OOP in Elixir!
Stars: ✭ 233 (+72.59%)
Mutual labels:  fun
Hanabi
💥 Highlight any code, in a colorful way. (seriously 700 bytes)
Stars: ✭ 166 (+22.96%)
Mutual labels:  fun
Tsuyo
🤖 A light-weight and easy-to-use modular Discord bot built with DiscordJS.
Stars: ✭ 136 (+0.74%)
Mutual labels:  fun
Microjs.com
Fantastic Micro-Frameworks and Micro-Libraries for Fun and Profit!
Stars: ✭ 1,927 (+1327.41%)
Mutual labels:  fun
Red Discordbot
A multi-function Discord bot
Stars: ✭ 2,855 (+2014.81%)
Mutual labels:  fun
Memetastic
Meme Creator for Android - Simple & Ad-Free
Stars: ✭ 206 (+52.59%)
Mutual labels:  fun
go-zero
A cloud-native Go microservices framework with cli tool for productivity.
Stars: ✭ 23,294 (+17154.81%)
Mutual labels:  microservice-framework
devheart
Listen to Tux's heartbeat with this awesome Linux Kernel Module ❤️
Stars: ✭ 58 (-57.04%)
Mutual labels:  fun

Moleculer Go

🚀 Progressive microservices framework for Go Moleculer Gopher Gopher

Inspired and compatible with Moleculer JS

Simple, fast, light and fun to develop with. Also easy, very easy to test ;)

Gitter Drone.io Build Status Go Report Card Coverage -> Coveralls Coverage -> Codecov

Get Started

Example

package main

import (
	"fmt"

	"github.com/moleculer-go/moleculer"
	"github.com/moleculer-go/moleculer/broker"
)

type MathService struct {
}

func (s MathService) Name() string {
	return "math"
}

func (s *MathService) Add(params moleculer.Payload) int {
	return params.Get("a").Int() + params.Get("b").Int()
}

func (s *MathService) Sub(a int, b int) int {
	return a - b
}

func main() {
	var bkr = broker.New(&moleculer.Config{LogLevel: "error"})
	bkr.Publish(&MathService{})
	bkr.Start()
	result := <-bkr.Call("math.add", map[string]int{
		"a": 10,
		"b": 130,
	})
	fmt.Println("result: ", result.Int())
	//$ result: 140
	bkr.Stop()
}

Roadmap

v0.1.0 (MVP)

Contents:

  • Service Broker
  • Transit and Transport
  • Actions (request-reply)
  • Events
  • Mixins
  • Load balancing for actions and events (random round-robin)
  • Service registry & dynamic service discovery
  • Versioned services
  • Middlewares
  • NATS Streaming Transporter
  • JSON Serializer
  • Examples :)

v0.2.0 (Beta RC1)

  • Action validators
  • Support for streams
  • More Load balancing implementations (cpu-usage, latency)
  • Fault tolerance features (Circuit Breaker, Bulkhead, Retry, Timeout, Fallback)
  • Built-in caching solution (memory, Redis)
  • More transporters (gRPC, TCP, Redis, Kafka)
  • More serializers (Avro, MsgPack, Protocol Buffer, Thrift)

v0.3.0 (Beta)

  • Performance and Optimization
  • More DB Adaptors (Firebase, MySQL)
  • CLI for Project Seed Generation

v0.4.0 (Alpha)

  • Event Sourcing Mixins

v0.5.0 (Release)

Installation

$ go get github.com/moleculer-go/moleculer

Running examples

# simple moleculer db example with memory adaptor
$ go run github.com/moleculer-go/store/examples/users

# simple moleculer db example with Mongo adaptor
$ go run github.com/moleculer-go/store/examples/usersMongo

# simple moleculer db example with SQLite adaptor
$ go run github.com/moleculer-go/store/examples/usersSQLite

# complex moleculer db example with population of fields by other services
$ go run github.com/moleculer-go/store/examples/populates

Running tests

# integration tests require mongo, nats streaming and rabbitmq

# run mongo
docker run -d -p 27017:27017 mongo

# run nats-streaming
docker run -d -p 4222:4222 nats-streaming -mc 0


# run rabbitmq
docker run -d -p 5672:5672 rabbitmq

# running all tests
go test ./...
# or
ginkgo -r
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].