REST: Node and item manipulation using REST API - JSON - #4728

Test duration: 8.920s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.078s
2020-05-25 23:04:53 |

2020-05-25 23:04:53 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:53 | ------------------------------------

2020-05-25 23:04:53 | [Mutex] waiting for: [configured:node:node-d40bc137-4d34-4e56-874f-e728a1bccae1:node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902]

2020-05-25 23:04:53 | [Mutex] received everything.

2020-05-25 23:04:53 | [Mutex] isItemNotified: configured:node:node-d40bc137-4d34-4e56-874f-e728a1bccae1:node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902 :: true

2020-05-25 23:04:54 | [Mutex] waiting for: [received:nodes:56d229aa-27c2-4478-b152-614a3c637c09:localhost]

2020-05-25 23:04:54 | [Mutex] received everything.

2020-05-25 23:04:54 | [Mutex] isItemNotified: received:node:56d229aa-27c2-4478-b152-614a3c637c09:localhost:node-d40bc137-4d34-4e56-874f-e728a1bccae1:Node d40bc137-4d34-4e56-874f-e728a1bccae1 :: true

2020-05-25 23:04:54 | [Mutex] waiting for: [received:nodes:6f976f08-3a42-4c27-bf0b-6a01359ded78:localhost]

2020-05-25 23:04:54 | [Mutex] received everything.

2020-05-25 23:04:54 | [Mutex] isItemNotified: received:node:6f976f08-3a42-4c27-bf0b-6a01359ded78:localhost:node-d40bc137-4d34-4e56-874f-e728a1bccae1:Node d40bc137-4d34-4e56-874f-e728a1bccae1 :: false

createNodes 1.712s
2020-05-25 23:04:50 |

2020-05-25 23:04:50 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:50 | ------------------------------------

2020-05-25 23:04:51 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "pubsub#title": "Node d40bc137-4d34-4e56-874f-e728a1bccae1"
}

2020-05-25 23:04:51 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-05-25 23:04:52 | [Mutex] waiting for: [received:nodes:c7fe263a-2189-4bb9-b649-03bb2163f046:localhost]

2020-05-25 23:04:52 | [Mutex] received everything.

2020-05-25 23:04:52 | [Mutex] isItemNotified: received:node:c7fe263a-2189-4bb9-b649-03bb2163f046:localhost:node-d40bc137-4d34-4e56-874f-e728a1bccae1:Node d40bc137-4d34-4e56-874f-e728a1bccae1 :: true

createSubnodes 1.022s
2020-05-25 23:04:52 |

2020-05-25 23:04:52 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:52 | ------------------------------------

2020-05-25 23:04:52 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902",
    "pubsub#title": "Node b9eb3fe0-0f62-46d7-815e-9d0c471bd902"
}

2020-05-25 23:04:52 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-05-25 23:04:53 | [Mutex] waiting for: [received:nodes:d2a2319e-d3d6-45e4-8dae-87c9ef5f3a78:localhost]

2020-05-25 23:04:53 | [Mutex] received everything.

2020-05-25 23:04:53 | [Mutex] isItemNotified: received:node:d2a2319e-d3d6-45e4-8dae-87c9ef5f3a78:localhost:node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902:Node b9eb3fe0-0f62-46d7-815e-9d0c471bd902 :: true

deleteNodes 1.018s
2020-05-25 23:04:57 |

2020-05-25 23:04:57 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:57 | ------------------------------------

2020-05-25 23:04:57 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902"
}

2020-05-25 23:04:57 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-05-25 23:04:58 | [Mutex] waiting for: [received:nodes:7e564c60-79a3-424a-af03-6403bf8f1f1e:localhost]

2020-05-25 23:04:58 | [Mutex] received everything.

2020-05-25 23:04:58 | [Mutex] isItemNotified: received:node:7e564c60-79a3-424a-af03-6403bf8f1f1e:localhost:node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902:Node b9eb3fe0-0f62-46d7-815e-9d0c471bd902 :: false

deleteSubnodes 1.026s
2020-05-25 23:04:56 |

2020-05-25 23:04:56 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:56 | ------------------------------------

2020-05-25 23:04:56 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1"
}

2020-05-25 23:04:56 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-05-25 23:04:57 | [Mutex] waiting for: [received:nodes:32e655c9-e988-4e17-b7be-6b38833eeb1e:localhost]

2020-05-25 23:04:57 | [Mutex] received everything.

2020-05-25 23:04:57 | [Mutex] isItemNotified: received:node:32e655c9-e988-4e17-b7be-6b38833eeb1e:localhost:node-d40bc137-4d34-4e56-874f-e728a1bccae1:Node d40bc137-4d34-4e56-874f-e728a1bccae1 :: false

2020-05-25 23:04:57 | [Mutex] waiting for: [received:nodes:538c1d81-a567-40f1-9fff-01aa515c4cba:localhost]

2020-05-25 23:04:57 | [Mutex] received everything.

2020-05-25 23:04:57 | [Mutex] isItemNotified: received:node:538c1d81-a567-40f1-9fff-01aa515c4cba:localhost:node-d40bc137-4d34-4e56-874f-e728a1bccae1:Node d40bc137-4d34-4e56-874f-e728a1bccae1 :: false

publishItemsToNodes 0.042s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "entry": "<test>item-14300508-90e2-4e5b-a28c-5c85b20a35d5</test>",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5"
}

2020-05-25 23:04:55 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5"
}

2020-05-25 23:04:55 | [Mutex] waiting for: [published:item:notifieditem-14300508-90e2-4e5b-a28c-5c85b20a35d5:admin@localhost]

2020-05-25 23:04:55 | [Mutex] received everything.

2020-05-25 23:04:55 | [Mutex] isItemNotified: published:item:notifieditem-14300508-90e2-4e5b-a28c-5c85b20a35d5:admin@localhost :: true

retractItemsFromNodes 0.060s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5"
}

2020-05-25 23:04:55 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5"
}

2020-05-25 23:04:55 | [Mutex] received everything.

2020-05-25 23:04:55 | [Mutex] isItemNotified: retracted:item:notifieditem-14300508-90e2-4e5b-a28c-5c85b20a35d5:admin@localhost :: true

retrieveItemsFromNodes 0.053s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5"
}

2020-05-25 23:04:55 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "item-id": "item-14300508-90e2-4e5b-a28c-5c85b20a35d5",
    "item": [
        "<item id=\"item-14300508-90e2-4e5b-a28c-5c85b20a35d5\"><test>item-14300508-90e2-4e5b-a28c-5c85b20a35d5</test></item>"
    ]
}

2020-05-25 23:04:55 | [Mutex] notify: [retrieved:item:item-14300508-90e2-4e5b-a28c-5c85b20a35d5:payload-matches:true:localhost]

2020-05-25 23:04:55 | [Mutex] received everything.

2020-05-25 23:04:55 | [Mutex] isItemNotified: retrieved:item:item-14300508-90e2-4e5b-a28c-5c85b20a35d5:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.051s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost"
}

2020-05-25 23:04:55 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-b9eb3fe0-0f62-46d7-815e-9d0c471bd902",
        "node-d40bc137-4d34-4e56-874f-e728a1bccae1"
    ]
}

retrieveUserSubscriptionsWithRegex 0.048s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-d40bc137-4d34-4e56-874f-e728a1bccae1)"
}

2020-05-25 23:04:55 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
       
    ]
}

subscribeNodes 1.008s
2020-05-25 23:04:54 |

2020-05-25 23:04:54 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:54 | ------------------------------------

2020-05-25 23:04:54 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "jids": [
        "admin@localhost"
    ]
}

2020-05-25 23:04:54 | from localhost for action subscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}

unsubscribeNodes 1.063s
2020-05-25 23:04:55 |

2020-05-25 23:04:55 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-05-25 23:04:55 | ------------------------------------

2020-05-25 23:04:55 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-d40bc137-4d34-4e56-874f-e728a1bccae1",
    "jids": [
        "admin@localhost"
    ]
}

2020-05-25 23:04:55 | from localhost for action unsubscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}