|
|
Re: Multiple instances found error.. [message #1739527 is a reply to message #1739336] |
Tue, 02 August 2016 16:52 |
|
Luka Cavic wrote on Fri, 29 July 2016 17:51solved it...
added @Order(1000) below service..
Great!
Apparently you had two beans with the same order in your application that implemented the same interface "ISqlService". The bean manager could not decide, which one to use, so it threw an exception. If you omit the order, your bean gets assigned the default order, which is 5000. So adding an @Order annotation with a lower number in your own projects to override default beans from Scout is the correct way to do it.
Regards,
Beat
|
|
|
|
Re: Multiple instances found error.. [message #1740271 is a reply to message #1739949] |
Thu, 11 August 2016 06:23 |
|
Luka Cavic wrote on Fri, 05 August 2016 16:24Hi, how to solve it by not adding order below service?
Now, I have many services, but only one service extends MainPostgreService(where is db connection methods) and has order below class name
When you don't add the @Order annotation, your bean gets assigned the default order of 5000. This is fine, as long as only one bean of a specific type exists. If more than one exists, you have to assign distinct orders to them. Alternatively, you can replace the bean from which you extend by adding the @Replace annotation.
See this section of the Scout documentation:
http://eclipsescout.github.io/6.0/technical-guide.html#bean-retrieval
Regards,
Beat
|
|
|
Powered by
FUDForum. Page generated in 0.04196 seconds