I set up 2 remote tc server. I made simple spring web application by modifying spring jmx sample. It works fine as a tomcat web applicaiton.
I made a simple test case using spring-mock. I tried to run that test case as "Terracotta DSO JUnit Test" from eclipse using terracotta eclipse plugin.
Terracotta eclipse plugin invoke local tc server, and my test case connect to local server instead of remove server even though I specified remote servers in my tc-config.xml.
I want followings:
1. I want my spring-mock test case connect remote tc server instead of connecting local tc server(which invoked by terracotta eclipse plugin).
2. I want tc eclipse plugin not to invoke local tc server.
Joined: 12/05/2006 10:22:37
Messages: 685
Location: Terracotta, Inc.
Offline
The plugin will always ensure that a local server is running, and it uses the first named server it finds in the config for that. I guess it may be wrong that it automatically does this and I'll remove it if the community agrees.
To accomplish your goal you should have your client get its config from the remote server. Start your remote servers with the config you currently have in your Eclipse project and then add -Dtc.config=server1-host:server1-dso-port,server2-host:server2-dso-port to your client's launch configuration VM arguments. You can find your launch configuration in the Debug... or Run... dialog under the Terracotta DSO JUnit Test section.
So, the local server will still be started, but the client will get its config from a remote server and connect to the servers listed there.
Since you have declared multiple servers I assume that you're trying out clustered servers in persistent mode with a shared data directory.