이창우씨,
As you use a URLConnection to send the data, and as you write that the problem doesn’t happen repeatedly, I assume this has been a network error.
I guess that urlTemp points to a BaseX server instance and that you use our REST API?
If you can, feel free to provide us with some self-contained Java code that we can try.
올림, Christian
The program is made in Java.
Some of the contents of reading and transmitting data are as follows.
URL url = new URL(urlTemp);
conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("PUT");
conn.setRequestProperty("Content-Type", "application/xml");
OutputStream out = conn.getOutputStream();
InputStream in = null;
in = new GZIPInputStream(new FileInputStream(filePath));
int len = 0;
byte[] readBuffer = new byte[1024];
while ((len = in.read(readBuffer)) > 0) {
out.write(readBuffer, 0, len);
}