Existence of discovery rule not checked when running discovery rule via proxy and if the rule on server gets deleted meanwhile being run on proxy.
How to reproduce:
1. Zabbix Server 2.2.3, Zabbix Proxy
2. Configuration -> Discovery -> Create discovery rule
3. Set the rule to be monitored via Proxy
4. Set IP range, delay, and select check type like "ICMP ping"
5. Wait for rule to run on proxy, check it in Monitoring -> Discovery
6. When some hosts start to appear, stop Zabbix server Server must be stopped before the discovery on proxy is finished
7. With the server stopped, delete the newly created discovery rule
8. Start Zabbix server
In this scenario Zabbix proxy does not check for existence of discovery rule after server restart and continues to send in discovery data to non-existing rule.
That makes Zabbix server log to show the following line repeatedly: