When start the jboss, find the bean is initialized 2 times.
When just publish, the bean is initialized 1 time only.
What do you mean by start and publish? Is start starting the server and publish right clicking the server in STS while it is running in debug and publishing changes to the server? If so what kind of changes are you publishing while its running? You cant make changes to annotations etc without restarting the server.
What do you mean by is initialized 2 times? Are you initializing the same XML twice in your web.xml? Are the beans defined multiple times in different web contexts? Do you have multiple component scanners scanning the same packages? Do you have @Configuration classes being picked up twice? In the end in most cases you will end up with a single spring bean but things like I have listed can cause multiple initializations.
That is about the most help I can give you without seeing more of your actual configuration. Also perhaps your start-up log showing the multiple initialization may help. Some times dropping the logging level down to debug for your Spring stuff can help you better debug whats happening on start-up.