Skip to content

Parse cluster not working properly #6894

Closed
@simonegiacco

Description

@simonegiacco

I'm trying to start parse server in a cluster of 3 instances (4 cores, so N - 1)

Setting the "cluster" parameter when creating new ParseServer() is not working
I tried with an app using parse-server@2.8.4 and with a clean installation of parse-server-example using latest parse-server without success;

var api = new ParseServer({
  databaseURI: databaseUri || 'mongodb://localhost:27017/dev',
  cloud: process.env.CLOUD_CODE_MAIN || __dirname + '/cloud/main.js',
  appId: process.env.APP_ID || 'myAppId',
  cluster: 3, //. <==== HERE! also tried cluster:true
  masterKey: process.env.MASTER_KEY || '',
  serverURL: process.env.SERVER_URL || 'http://localhost:1337/parse'  
});

Using this setting, ps -aux | grep node shows one node instance

I've tried with parse-server CLI and the clustering is working properly:

parse-server --appId X --masterKey X --databaseURI mongodb://localhost:27017/dev --publicServerURL http://localhost:1337/parse  --cluster=3

Using this command, ps -aux | grep node shows three node instances.

Is this a bug or am I doing something wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:questionSupport or code-level question

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions