Tasks are as follows:
1) Create a process that in the background increases a certain number by one for a certain time interval.
2) Create a process that in the background will listen to a certain message (for example, we received a notification from the server, and we have to show it to the user) I read the article , but it did not help. Installing triggers is not what I need.
PS application runs on p2p architecture