add getTrackerServer

dev
chengdu 2019-07-14 20:30:10 +08:00
parent 9ee6e693fe
commit 086f4efc0f
3 changed files with 21 additions and 3 deletions

View File

@ -37,7 +37,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.5.1</version>
<!--<version>3.5.1</version>-->
<configuration>
<encoding>UTF-8</encoding>
<source>${jdk.version}</source>

View File

@ -28,6 +28,8 @@ public class StorageClient {
protected StorageServer storageServer;
protected byte errno;
/**
* constructor using global settings in class ClientGlobal
*/
@ -1760,6 +1762,22 @@ public class StorageClient {
trackerServer.close();
}
public TrackerServer getTrackerServer() {
return trackerServer;
}
public void setTrackerServer(TrackerServer trackerServer) {
this.trackerServer = trackerServer;
}
public StorageServer getStorageServer() {
return storageServer;
}
public void setStorageServer(StorageServer storageServer) {
this.storageServer = storageServer;
}
/**
* Upload file by file buff
*

View File

@ -39,9 +39,9 @@ public class FdfsTest {
@After
public void closeClient() {
LOGGER.info("close connection");
if(trackerServer != null){
if(storageClient != null){
try {
trackerServer.finalize();
storageClient.close();
}catch (Exception e){
e.printStackTrace();
}catch (Throwable e){