Skip to content

When replication resumes _active_tasks still returns a 400 error #61

@jamesnocentini

Description

@jamesnocentini

When the app goes offline and returns online, the replication resumes and docs are replicated. But the _active_tasks endpoint on the listener still returns the error as shown below, as if the app was still offline. The _active_tasks endpoint is often used in apps built with the Listener API to display a connection status indicator. And the error property in the response can be used to show that sync is currently paused/offline.

This can be reproduced with liteserv-android (kick off continuous replication, check _active_tasks response, go offline or stop sync gateway, go back online, check _active_tasks and replication should resume).

$ curl 'http://localhost:5984/_active_tasks'
[
 {
  "source":"http://localhost:4984/sync_gateway",
  "task":"repl002",
  "status":"Idle",
  "progress":100,
  "continuous":true,
  "target":"cblite-test",
  "error":
    [
      400,
      "org.apache.http.conn.HttpHostConnectException: Connection to http://localhost:4984 refused"
    ],
    "type":"Replication"
  }
]

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions