From the looks of it, you have two Application webservers that are currently hosting your CRM instance (or these are async plugins, in which case, you have two async servers servicing your CRM instance) Each server has it's own local version of MyPlugin.count
, which is why you're seeing the strange behavior.
App Domains in CRM are a little bit simpler for unsandboxed plugins, it's one per Crm Web Server. Sandboxed plugins are a bit trickier. Each registration step of the plugin, has its own unique domain. This requires the CRM Database (or something else external to CRM) in order to keep these values in sync.
I have created an auto-numbering solution that does do just that using the Version feature new in CRM 2015 that allows for optimistic updates. But unfortunetly, Microsoft has a bug where the Version # is null for sandboxed plugins, so it will only work in an on-prem environment, until the bug is resolved.
Update: The bug has been resolved.