On 28/07/15 18:26, Christian Reis wrote:
> The code which sets up the role lives here:
>
> https://github.com/juju/juju/blame/8da94246468a4da71e62894f7a8a1bbbce112697/mongo/admin.go#L136
>
> The roles we are setting up are:
>
> Roles: []mgo.Role{
> mgo.RoleDBAdminAny,
> mgo.RoleUserAdminAny,
> mgo.RoleClusterAdmin,
> mgo.RoleReadWriteAny},
>
> Why do we need RoleClusterAdmin and RoleReadWriteAny (in particular,
> because they don't seem to be defined in the database)?
>
They are not in 2.4 but are in 2.6+. Some time back, Juju was ported to be
compatible with mongo 2.6+ as a pre-requisite to allowing upgrading to a more
recent mongo (there are bugs not fixed in 2.4). However, the effort to get Juju
on mongo 2.6 was then stalled because of the tokumx evaluation.
On 28/07/15 18:26, Christian Reis wrote: /github. com/juju/ juju/blame/ 8da94246468a4da 71e62894f7a8a1b bbce112697/ mongo/admin. go#L136 inAny, Admin, teAny},
> The code which sets up the role lives here:
>
> https:/
>
> The roles we are setting up are:
>
> Roles: []mgo.Role{
> mgo.RoleDBAdminAny,
> mgo.RoleUserAdm
> mgo.RoleCluster
> mgo.RoleReadWri
>
> Why do we need RoleClusterAdmin and RoleReadWriteAny (in particular,
> because they don't seem to be defined in the database)?
>
They are not in 2.4 but are in 2.6+. Some time back, Juju was ported to be
compatible with mongo 2.6+ as a pre-requisite to allowing upgrading to a more
recent mongo (there are bugs not fixed in 2.4). However, the effort to get Juju
on mongo 2.6 was then stalled because of the tokumx evaluation.