How do we define a service that collect stats and reports it to all users? If I define a bean in spring when I reload the page it looks like the bean is created for each user so double all of my values send to each user inside it. For example:
Say we have a class called OrderStats. This holds just numbers of total orders, total rejects etc. When we load the page with one user logged in it shows the correct stats, when we open the second browser window and login again we get the stats but they are doubled.