Coder Social home page Coder Social logo

revmgo's People

Contributors

cryptix avatar drewwells avatar hura avatar jgraham909 avatar rauhs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

revmgo's Issues

Is this project alive?

revmgo seems to be a good idea but it also seems abandoned. Is anybody maintaining the code?

Revmgo can't connect the secondary

Hi, I use revel and mgo with revmgo to build a restful service.I think you did a good job!
It works fine for a single mongod instance, but when I connected my app to a replica set, the app can only read from the primary node.Here is what I had tried.

  • revmgo.dial = mongodb://172.0.15.22:27017, 172.20.135.23:27017, 172.20.135.24:27017
  • Using c.MongoSession.SetMode(mgo.Eventual, true)"to change mode in my controller
  • Visit api with ab2 tools,
  • Watch mongod in a primary node and a secondary node with mongotop,

then I can only see the operation in primary node,and none in the secondary.

I also tried to example in https://labix.org/mgo. It works well, and I can see operation in both primary and secondary node.And then I use pure mgo in revel, it goes the situation like revmgo.

Could you give me a hand with this issue?
:-)

Nil pointer error on startup revel.

On startup revel, nil pointer error occurred like below:


panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x0 pc=0x1b3436]

goroutine 1 [running]:
runtime.panic(0x418ce0, 0x9956b9)
/Users/myhome/.gvm/gos/go1.2/src/pkg/runtime/panic.c:266 +0xb6
github.com/revel/revel.(_MergedConfig).String(0x0, 0x4df490, 0xb, 0x0, 0x0, ...)
/Users/myhome/.gvm/pkgsets/go1.2/global/src/github.com/revel/revel/config.go:89 +0x36
github.com/revel/revel.(_MergedConfig).StringDefault(0x0, 0x4df490, 0xb, 0x4d9a30, 0x9, ...)
/Users/myhome/.gvm/pkgsets/go1.2/global/src/github.com/revel/revel/config.go:97 +0xa8
github.com/jgraham909/revmgo.AppInit()
/Users/myhome/.gvm/pkgsets/go1.2/global/src/github.com/jgraham909/revmgo/revmgo.go:39 +0x55
github.com/robfig/revel.runStartupHooks()
/Users/myhome/.gvm/pkgsets/go1.2/global/src/github.com/robfig/revel/server.go:119 +0x5e
github.com/robfig/revel.Run(0xde2d)
/Users/myhome/.gvm/pkgsets/go1.2/global/src/github.com/robfig/revel/server.go:93 +0x4ad
main.main()
/Users/myhome/.gvm/pkgsets/go1.2/global/src/myapp/app/tmp/main.go:109 +0xe05


The error is thrown in the line revel.Config.StringDefault("revmgo.dial", "localhost").
But my code below works well:


code in init.go
func testInit() {
fmt.Println(revel.Config.StringDefault("revmgo.dial", "localhost"))
}

func init() {
....
revel.OnAppStart(testInit)
}


Do you have any ideas?
Thanks in advance.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.