Avoid uploading complete runtime when running on remote host
I'm creating a simple Java application (for testing purposes) that connects to a server and performs some HTTP requests. The server works with an IP whitelist, so I cannot run the app from my own machine.
We have a dev server that is whitelisted on their system. I'm using a remote run target in IDEA that uploads the whole project over SSH. This works fine, but it appears to upload the whole JDK as well on every run. This is very slow. Is there a way to avoid this?
Thanks.
(Edit) I can think of some good reasons why the entire runtime is uploaded, but it seems overkill to reupload everything on every run. Usually, only one or two .class files are different. Maybe the question should be "how to upload only the modified resources on remote deploy"?
请先登录再写评论。
Hello,
Do you have JDK configured for you target in "Settings/Preferences | Build, Execution, Deployment | Run Targets"
Yes. It's the JDK on the remote machine that's automatically been detected.
Did you see any messages about copying JDK?
Does this have solution. I have the same problem, running jar like that is very slow and impossible to work
Runtime should not be uploaded unless it's a part of your project files configured for deployment.
When using a remote JDK configuration, IDE will only sync the target files you are running.
If it doesn't work as expected, please file a bug at https://youtrack.jetbrains.com/newIssue?project=IDEA with a sample project to reproduce and the detailed description of the environment / deployment settings.
Does it resolve now?
I have the same problem. When I set a JUnit test to run on remote server, it always upload the whole maven repositories after build. It take a lot of time to run just one JUnit test.
Sheju Please file a bug report at https://youtrack.jetbrains.com/newIssue?project=IDEA with a demo project where the issue is reproducible, and detailed description of the environment / deployment settings.