update .gitignore

web_backend_develope
wu ming 9 years ago
parent 57a2cd17af
commit e1e273fb1c

@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="test"/>
<classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.eclipse.jst.server.tomcat.runtimeTarget/Apache Tomcat v7.0">
<attributes>
<attribute name="owner.project.facets" value="jst.web"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/Java"/>
<classpathentry kind="output" path="build/classes"/>
</classpath>

3
.gitignore vendored

@ -1,5 +1,6 @@
/target /target
/build /build
.classpath .classpath
.settings
.metadata
/bin/ /bin/

@ -1,14 +0,0 @@
!SESSION 2016-09-13 08:39:40.662 -----------------------------------------------
eclipse.buildId=4.3.0.I20130605-2000
java.version=1.8.0_91
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=zh_CN
Framework arguments: -product org.eclipse.epp.package.jee.product
Command-line arguments: -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.jee.product
!ENTRY org.eclipse.egit.ui 2 0 2016-09-13 08:40:07.850
!MESSAGE Warning: The environment variable HOME is not set. The following directory will be used to store the Git
user global configuration and to define the default location to store repositories: 'C:\Users\wuming'. If this is
not correct please set the HOME environment variable and restart Eclipse. Otherwise Git for Windows and
EGit might behave differently since they see different configuration options.
This warning can be switched off on the Team > Git > Confirmations and Warnings preference page.

@ -1,2 +0,0 @@
GitRepositoriesView.GitDirectories=C\:\\Users\\wuming\\workspace\\data_manager_backend\\.git;
eclipse.preferences.version=1

@ -1,14 +0,0 @@
content_assist_proposals_background=255,255,255
content_assist_proposals_foreground=0,0,0
eclipse.preferences.version=1
fontPropagated=true
org.eclipse.jdt.internal.ui.navigator.layout=2
org.eclipse.jdt.ui.editor.tab.width=
org.eclipse.jdt.ui.formatterprofiles.version=12
org.eclipse.jdt.ui.javadoclocations.migrated=true
org.eclipse.jface.textfont=1|Courier New|10.0|0|WINDOWS|1|0|0|0|0|0|0|0|0|1|0|0|0|0|Courier New;
proposalOrderMigrated=true
spelling_locale_initialized=true
tabWidthPropagated=true
useAnnotationsPrefPage=true
useQuickDiffPrefPage=true

@ -1,2 +0,0 @@
eclipse.preferences.version=1
org.eclipse.m2e.discovery.pref.projects=

@ -1,2 +0,0 @@
eclipse.preferences.version=1
mylyn.attention.migrated=true

@ -1,2 +0,0 @@
eclipse.preferences.version=1
org.eclipse.mylyn.monitor.activity.tracking.enabled.checked=true

@ -1,3 +0,0 @@
eclipse.preferences.version=1
org.eclipse.mylyn.tasks.ui.filters.nonmatching=true
org.eclipse.mylyn.tasks.ui.filters.nonmatching.encouraged=true

@ -1,3 +0,0 @@
activeuserprofiles=DESKTOP-65KJ4BV;Team
eclipse.preferences.version=1
org.eclipse.rse.systemtype.local.systemType.defaultUserId=wuming

@ -1,2 +0,0 @@
eclipse.preferences.version=1
org.eclipse.rse.preferences.order.connections=DESKTOP-65KJ4BV.Local

@ -1,2 +0,0 @@
eclipse.preferences.version=1
pref_first_startup=false

@ -1,2 +0,0 @@
eclipse.preferences.version=1
org.eclipse.team.ui.first_time=false

@ -1,2 +0,0 @@
browsers=<?xml version\="1.0" encoding\="UTF-8"?>\r\n<web-browsers current\="0">\r\n<system/>\r\n<external location\="C\:\\Program Files\\Internet Explorer\\iexplore.exe" name\="Internet Explorer"/>\r\n</web-browsers>
eclipse.preferences.version=1

@ -1,5 +0,0 @@
PROBLEMS_FILTERS_MIGRATE=true
eclipse.preferences.version=1
platformState=1470357608478
quickStart=false
tipsAndTricks=true

@ -1,2 +0,0 @@
eclipse.preferences.version=1
showIntro=false

@ -1,4 +0,0 @@
//org.eclipse.ui.commands/state/org.eclipse.wst.xml.views.XPathView.processor.xpathprocessor/org.eclipse.ui.commands.radioState=xpath10
ENABLED_DECORATORS=org.eclipse.jst.ws.jaxws.dom.integration.navigator.WebServiceDecorator\:true,org.eclipse.m2e.core.mavenVersionDecorator\:false,org.eclipse.wst.server.ui.decorator\:false,org.eclipse.datatools.connectivity.sqm.core.internal.ui.explorer.DependencyDecoration\:true,org.eclipse.datatools.connectivity.sqm.core.internal.ui.explorer.ColumnDecoration\:true,org.eclipse.datatools.connectivity.sqm.core.internal.ui.explorer.ForeignKeyDecoration\:true,org.eclipse.datatools.connectivity.sqm.core.internal.ui.explorer.IndexTriggerDecoration\:true,org.eclipse.datatools.connectivity.internal.core.ui.bookmarkDecoration\:true,org.eclipse.datatools.connectivity.internal.core.ui.FilterNodeDecoration\:true,org.eclipse.datatools.connectivity.ui.decorator.contentextension\:false,org.eclipse.datatools.enablement.ingres.ui.providers.decorators.SynonymDecorationService\:true,org.eclipse.datatools.enablement.ingres.internal.ui.providers.decorators.ParameterDecorationService\:true,org.eclipse.datatools.enablement.sybase.asa.proxytabledecorator\:true,org.eclipse.datatools.enablement.sybase.ase.webservicetabledecorator\:true,org.eclipse.datatools.enablement.sybase.systemtabledecorator\:true,org.eclipse.egit.ui.internal.decorators.GitLightweightDecorator\:true,org.eclipse.jdt.ui.override.decorator\:true,org.eclipse.jdt.ui.interface.decorator\:false,org.eclipse.jdt.ui.buildpath.decorator\:true,org.eclipse.jst.j2ee.internal.ui.util.AnnotationIconDecorator_ejb\:true,org.eclipse.jst.j2ee.navigator.internal.J2EEProjectDecorator\:true,org.eclipse.jst.jee.ui.internal.navigator.ejb.BeanDecorator\:true,org.eclipse.jst.jee.navigator.internal.JEEProjectDecorator\:true,org.eclipse.jst.j2ee.internal.ui.util.AnnotationIconDecorator_servlet\:true,org.eclipse.m2e.core.maven2decorator\:true,org.eclipse.mylyn.context.ui.decorator.interest\:true,org.eclipse.mylyn.tasks.ui.decorators.task\:true,org.eclipse.mylyn.team.ui.changeset.decorator\:true,org.eclipse.pde.ui.binaryProjectDecorator\:false,org.eclipse.rse.core.virtualobject.decorator\:true,org.eclipse.rse.core.binary.executable.decorator\:true,org.eclipse.rse.core.script.executable.decorator\:true,org.eclipse.rse.core.java.executable.decorator\:true,org.eclipse.rse.core.library.decorator\:true,org.eclipse.rse.core.link.decorator\:true,org.eclipse.rse.subsystems.error.decorator\:true,org.eclipse.team.cvs.ui.decorator\:true,org.eclipse.ui.LinkedResourceDecorator\:true,org.eclipse.ui.SymlinkDecorator\:true,org.eclipse.ui.VirtualResourceDecorator\:true,org.eclipse.ui.ContentTypeDecorator\:true,org.eclipse.ui.ResourceFilterDecorator\:false,org.eclipse.wst.jsdt.ui.override.decorator\:true,org.eclipse.wst.server.ui.navigatorDecorator\:true,
PLUGINS_NOT_ACTIVATED_ON_STARTUP=org.eclipse.m2e.discovery;
eclipse.preferences.version=1

File diff suppressed because it is too large Load Diff

@ -1,2 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<typeInfoHistroy/>

@ -1,2 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<qualifiedTypeNameHistroy/>

@ -1,10 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<section name="Workbench">
<section name="org.eclipse.jdt.internal.ui.packageview.PackageExplorerPart">
<item value="2" key="layout"/>
<item value="true" key="group_libraries"/>
<item value="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;&#x0D;&#x0A;&lt;packageExplorer group_libraries=&quot;1&quot; layout=&quot;2&quot; linkWithEditor=&quot;0&quot; rootMode=&quot;1&quot; workingSetName=&quot;&quot;&gt;&#x0D;&#x0A;&lt;customFilters userDefinedPatternsEnabled=&quot;false&quot;&gt;&#x0D;&#x0A;&lt;xmlDefinedFilters&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.StaticsFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer_patternFilterId_RemoteSystemsConnections&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.mylyn.java.ui.MembersFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.NonSharedProjectsFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.internal.ui.PackageExplorer.EmptyInnerPackageFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.m2e.MavenModuleFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.ClosedProjectsFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.EmptyLibraryContainerFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.PackageDeclarationFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.pde.ui.BinaryProjectFilter1&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.LocalTypesFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.pde.ui.ExternalPluginLibrariesFilter1&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.FieldsFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer_patternFilterId_RemoteSystemsTempFiles&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.NonJavaProjectsFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer_patternFilterId_.*&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.SyntheticMembersFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.ContainedLibraryFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.internal.ui.PackageExplorer.HideInnerClassFilesFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.ImportDeclarationFilter&quot; isEnabled=&quot;true&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.NonJavaElementFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.LibraryFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.CuAndClassFileFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.internal.ui.PackageExplorer.EmptyPackageFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;child filterId=&quot;org.eclipse.jdt.ui.PackageExplorer.NonPublicFilter&quot; isEnabled=&quot;false&quot;/&gt;&#x0D;&#x0A;&lt;/xmlDefinedFilters&gt;&#x0D;&#x0A;&lt;/customFilters&gt;&#x0D;&#x0A;&lt;/packageExplorer&gt;" key="memento"/>
<item value="1" key="rootMode"/>
<item value="false" key="linkWithEditor"/>
</section>
</section>

@ -1,41 +0,0 @@
<configuration scan="true">
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>%date [%thread] %-5level %logger{35} - %msg%n</pattern>
</encoder>
<filter class="org.eclipse.m2e.logback.appender.ConsoleAppenderFilter"/>
</appender>
<appender name="FILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
<File>${org.eclipse.m2e.log.dir}/0.log</File>
<rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
<FileNamePattern>${org.eclipse.m2e.log.dir}/%i.log</FileNamePattern>
<MinIndex>1</MinIndex>
<MaxIndex>10</MaxIndex>
</rollingPolicy>
<triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
<MaxFileSize>100MB</MaxFileSize>
</triggeringPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<pattern>%date [%thread] %-5level %logger{35} - %msg%n</pattern>
</encoder>
</appender>
<appender name="EclipseLog" class="org.eclipse.m2e.logback.appender.EclipseLogAppender">
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
<level>WARN</level>
</filter>
</appender>
<appender name="MavenConsoleLog" class="org.eclipse.m2e.logback.appender.MavenConsoleAppender">
</appender>
<root level="INFO">
<appender-ref ref="FILE" />
<appender-ref ref="STDOUT" />
<appender-ref ref="EclipseLog" />
<appender-ref ref="MavenConsoleLog" />
</root>
<logger name="com.ning.http.client" level="INFO" />
</configuration>

@ -1,57 +0,0 @@
# RSE DOM Node
00-name=DESKTOP-65KJ4BV\:local.files
01-type=FilterPool
03-attr.default=true
03-attr.deletable=true
03-attr.id=local.files
03-attr.nonRenamable=false
03-attr.owningParentName=null
03-attr.release=200
03-attr.singleFilterStringOnly=false
03-attr.singleFilterStringOnlyESet=false
03-attr.stringsCaseSensitive=true
03-attr.supportsDuplicateFilterStrings=false
03-attr.supportsNestedFilters=true
03-attr.type=default
06-child.00000.00-name=My Home
06-child.00000.01-type=Filter
06-child.00000.03-attr.default=false
06-child.00000.03-attr.filterType=default
06-child.00000.03-attr.id=My Home
06-child.00000.03-attr.nonChangable=false
06-child.00000.03-attr.nonDeletable=false
06-child.00000.03-attr.nonRenamable=false
06-child.00000.03-attr.promptable=false
06-child.00000.03-attr.relativeOrder=0
06-child.00000.03-attr.release=200
06-child.00000.03-attr.singleFilterStringOnly=false
06-child.00000.03-attr.stringsCaseSensitive=false
06-child.00000.03-attr.stringsNonChangable=false
06-child.00000.03-attr.supportsDuplicateFilterStrings=false
06-child.00000.03-attr.supportsNestedFilters=true
06-child.00000.06-child.00000.00-name=C\:\\Users\\wuming\\*
06-child.00000.06-child.00000.01-type=FilterString
06-child.00000.06-child.00000.03-attr.default=false
06-child.00000.06-child.00000.03-attr.string=C\:\\Users\\wuming\\*
06-child.00000.06-child.00000.03-attr.type=default
06-child.00001.00-name=Drives
06-child.00001.01-type=Filter
06-child.00001.03-attr.default=false
06-child.00001.03-attr.filterType=default
06-child.00001.03-attr.id=Drives
06-child.00001.03-attr.nonChangable=false
06-child.00001.03-attr.nonDeletable=false
06-child.00001.03-attr.nonRenamable=false
06-child.00001.03-attr.promptable=false
06-child.00001.03-attr.relativeOrder=0
06-child.00001.03-attr.release=200
06-child.00001.03-attr.singleFilterStringOnly=false
06-child.00001.03-attr.stringsCaseSensitive=false
06-child.00001.03-attr.stringsNonChangable=false
06-child.00001.03-attr.supportsDuplicateFilterStrings=false
06-child.00001.03-attr.supportsNestedFilters=true
06-child.00001.06-child.00000.00-name=*
06-child.00001.06-child.00000.01-type=FilterString
06-child.00001.06-child.00000.03-attr.default=false
06-child.00001.06-child.00000.03-attr.string=*
06-child.00001.06-child.00000.03-attr.type=default

@ -1,25 +0,0 @@
# RSE DOM Node
00-name=Local
01-type=Host
03-attr.description=
03-attr.hostname=LOCALHOST
03-attr.offline=false
03-attr.promptable=false
03-attr.systemType=org.eclipse.rse.systemtype.local
03-attr.type=Local
06-child.00000.00-name=Local Connector Service
06-child.00000.01-type=ConnectorService
06-child.00000.03-attr.group=Local Connector Service
06-child.00000.03-attr.port=0
06-child.00000.03-attr.useSSL=false
06-child.00000.06-child.00000.00-name=Local Files
06-child.00000.06-child.00000.01-type=SubSystem
06-child.00000.06-child.00000.03-attr.hidden=false
06-child.00000.06-child.00000.03-attr.type=local.files
06-child.00000.06-child.00000.06-child.00000.00-name=DESKTOP-65KJ4BV___DESKTOP-65KJ4BV\:local.files
06-child.00000.06-child.00000.06-child.00000.01-type=FilterPoolReference
06-child.00000.06-child.00000.06-child.00000.03-attr.refID=local.files
06-child.00000.06-child.00001.00-name=Local Shells
06-child.00000.06-child.00001.01-type=SubSystem
06-child.00000.06-child.00001.03-attr.hidden=false
06-child.00000.06-child.00001.03-attr.type=local.shells

@ -1,7 +0,0 @@
# RSE DOM Node
00-name=DESKTOP-65KJ4BV
01-type=Profile
03-attr.defaultPrivate=true
03-attr.isActive=true
05-ref.00000=FP.local.files_0
05-ref.00001=H.local_16

@ -1,28 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<section name="Workbench">
<section name="org.eclipse.ui.internal.QuickAccess">
<item value="759" key="dialogHeight"/>
<item value="1440" key="dialogWidth"/>
<list key="textEntries">
</list>
<list key="orderedElements">
</list>
<list key="orderedProviders">
</list>
<list key="textArray">
</list>
</section>
<section name="ShowViewDialog">
<item value="345" key="DIALOG_WIDTH"/>
<item value="1|Microsoft YaHei UI|9.0|0|WINDOWS|1|-12|0|0|0|400|0|0|0|1|0|0|0|0|Microsoft YaHei UI" key="DIALOG_FONT_NAME"/>
<item value="org.eclipse.jdt.ui.PackageExplorer" key="ShowViewDialog.STORE_SELECTED_VIEW_ID"/>
<item value="452" key="DIALOG_HEIGHT"/>
<item value="796" key="DIALOG_X_ORIGIN"/>
<item value="227" key="DIALOG_Y_ORIGIN"/>
<list key="ShowViewDialog.STORE_EXPANDED_CATEGORIES_ID">
<item value="org.eclipse.jdt.ui.java"/>
</list>
</section>
<section name="ImportExportAction">
</section>
</section>

@ -1 +0,0 @@
org.eclipse.core.runtime=1

@ -1,12 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="WebContent"/>
<classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.WebProject">
<attributes>
<attribute name="hide" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.wst.jsdt.launching.baseBrowserLibrary"/>
<classpathentry kind="output" path=""/>
</classpath>

@ -1,3 +0,0 @@
eclipse.preferences.version=1
performed.operation.correct.unbound.jre=1.0
performed.operation.resolve.unknown.runtime=1.0

@ -1,10 +0,0 @@
eclipse.preferences.version=1
encoding//WebContent/WEB-INF/config/config.properties=UTF-8
<<<<<<< HEAD
encoding//src/com/platform/controller/DataModelController.java=UTF-8
encoding/<project>=UTF-8
=======
encoding//src/com/platform/utils/GanymedSSH.java=UTF-8
encoding/<project>=UTF-8
separateDerivedEncodings=true
>>>>>>> ef099fd1aed73bcc4ef4c8d62aaba6cc6ec2dabf

@ -1,101 +0,0 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled
org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning
org.eclipse.jdt.core.compiler.problem.deadCode=warning
org.eclipse.jdt.core.compiler.problem.deprecation=warning
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore
org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore
org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning
org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore
org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error
org.eclipse.jdt.core.compiler.problem.nullReference=warning
org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore
org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore
org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore
org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore
org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore
org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled
org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled
org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning
org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedImport=warning
org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
org.eclipse.jdt.core.compiler.source=1.7

@ -1,3 +0,0 @@
eclipse.preferences.version=1
org.eclipse.jpt.core.platform=generic2_1
org.eclipse.jpt.jpa.core.discoverAnnotatedClasses=false

@ -1,4 +0,0 @@
activeProfiles=
eclipse.preferences.version=1
resolveWorkspaceProjects=true
version=1

@ -1,9 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
<wb-module deploy-name="data_manager_backend">
<wb-resource deploy-path="/" source-path="/WebContent" tag="defaultRootSource"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src"/>
<wb-resource deploy-path="/WEB-INF/classes" source-path="/test"/>
<property name="java-output-path" value="/data_manager_backend/build/classes"/>
<property name="context-root" value="/"/>
</wb-module>
</project-modules>

@ -1,7 +0,0 @@
<root>
<facet id="jpt.jpa">
<node name="libprov">
<attribute name="provider-id" value="jpa-no-op-library-provider"/>
</node>
</facet>
</root>

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<faceted-project>
<runtime name="MyEclipse Tomcat v7.0"/>
<fixed facet="java"/>
<fixed facet="wst.jsdt.web"/>
<fixed facet="jst.web"/>
<installed facet="java" version="1.7"/>
<installed facet="jst.web" version="3.0"/>
<installed facet="wst.jsdt.web" version="1.0"/>
<installed facet="jpt.jpa" version="2.1"/>
</faceted-project>

@ -1 +0,0 @@
org.eclipse.wst.jsdt.launching.baseBrowserLibrary

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<persistence version="2.1" xmlns="http://xmlns.jcp.org/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd"> <persistence version="2.1" xmlns="http://xmlns.jcp.org/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd">
<persistence-unit name="aggregation-platform"> <persistence-unit name="aggregation-platform">
</persistence-unit> </persistence-unit>
</persistence> </persistence>

@ -1,65 +1,65 @@
/** /**
* BaseController.java * BaseController.java
* : XX * : XX
* : <> * : <>
* 201697 * 201697
* <> * <>
*/ */
package com.base; package com.base;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.springframework.web.bind.annotation.ExceptionHandler; import org.springframework.web.bind.annotation.ExceptionHandler;
import com.platform.utils.Configs; import com.platform.utils.Configs;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201697] * @version [201697]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class BaseController { public class BaseController {
/** log4j */ /** log4j */
public static Logger log = Logger.getRootLogger(); public static Logger log = Logger.getRootLogger();
/** /**
* <> @ExceptionHandler---- * <> @ExceptionHandler----
* <> * <>
* @param request * @param request
* @param ex * @param ex
* @return * @return
* @see [##] * @see [##]
*/ */
@ExceptionHandler @ExceptionHandler
public Object exp(HttpServletRequest request, HttpServletResponse response,Exception ex) { public Object exp(HttpServletRequest request, HttpServletResponse response,Exception ex) {
System.out.println("URI"+request.getRequestURI()); System.out.println("URI"+request.getRequestURI());
request.setAttribute("ex", ex); request.setAttribute("ex", ex);
System.err.println("BaseController --exp "); System.err.println("BaseController --exp ");
// 根据不同错误转向不同页面 // 根据不同错误转向不同页面
if(ex instanceof CustomException) { if(ex instanceof CustomException) {
CustomException cuse = (CustomException) ex; CustomException cuse = (CustomException) ex;
Map<String, String> errmsg = new HashMap<>(); Map<String, String> errmsg = new HashMap<>();
errmsg.put("code", cuse.getCode()); errmsg.put("code", cuse.getCode());
errmsg.put("msg", cuse.getMsg()); errmsg.put("msg", cuse.getMsg());
log.error(cuse.getCode()); log.error(cuse.getCode());
response.setStatus(500); response.setStatus(500);
return response; return response;
} else { } else {
//其他错误则 调到指定页面 //其他错误则 调到指定页面
log.error(Configs.GLOBAL_EXP_NOT_CUSTOM, ex); log.error(Configs.GLOBAL_EXP_NOT_CUSTOM, ex);
response.setStatus(500); response.setStatus(500);
return response; return response;
} }
} }
} }

@ -1,23 +1,23 @@
package com.base; package com.base;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class Constant { public class Constant {
/** 国际话配置文件文件-i18n.properties */ /** 国际话配置文件文件-i18n.properties */
public static String I18N_PROPERTIES_FIEL_PATH = "/com/base/i18n.properties"; public static String I18N_PROPERTIES_FIEL_PATH = "/com/base/i18n.properties";
/** WritefileThread-线程睡眠时间--3000 */ /** WritefileThread-线程睡眠时间--3000 */
public final static long THREAD_SLEEP_WRITEFILETHREAD = 3000; public final static long THREAD_SLEEP_WRITEFILETHREAD = 3000;
/** CustomException记录报异常的对象的对象个数--10 */ /** CustomException记录报异常的对象的对象个数--10 */
public final static int CustomException_log_object_size = 10; public final static int CustomException_log_object_size = 10;
} }

@ -1,29 +1,29 @@
package com.base; package com.base;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class Custom4exception { public class Custom4exception {
//3003001001 : 第一位:标识异常, 第二到第四位:标识模块,第五道第七位:标识类别,第八道第十位标识具体异常 //3003001001 : 第一位:标识异常, 第二到第四位:标识模块,第五道第七位:标识类别,第八道第十位标识具体异常
/**eg /**eg
* 3 * 3
* 003 * 003
* 001 * 001
* 001 * 001
*/ */
/** /**
* ThreadVolume volume * ThreadVolume volume
*/ */
public final static String threadVolume_class_Except = "3001001001"; public final static String threadVolume_class_Except = "3001001001";
/** /**
* ThreadVolume线 * ThreadVolume线
*/ */
public final static String threadVolume_Thread_Except = "3001001002"; public final static String threadVolume_Thread_Except = "3001001002";
} }

@ -1,127 +1,127 @@
package com.base; package com.base;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
@SuppressWarnings("serial") @SuppressWarnings("serial")
public class CustomException extends Exception { public class CustomException extends Exception {
/** log4j */ /** log4j */
public static Logger log = Logger.getRootLogger(); public static Logger log = Logger.getRootLogger();
/** 自定义异常信息-错误信息 */ /** 自定义异常信息-错误信息 */
private String msg; private String msg;
/** 自定义异常信息-错误代码 */ /** 自定义异常信息-错误代码 */
private String code; private String code;
/** 操作对象 */ /** 操作对象 */
private Object[] objArray; private Object[] objArray;
/** 异常 */ /** 异常 */
private Throwable cause; private Throwable cause;
public CustomException() { public CustomException() {
super(); super();
} }
/** /**
* @ * @
* @param code * @param code
* @param msg * @param msg
* @param e * @param e
* @param obj * @param obj
*/ */
public CustomException(String code,Exception e,Object... obj) { public CustomException(String code,Exception e,Object... obj) {
super(code); super(code);
StringBuffer sbuf= new StringBuffer(); StringBuffer sbuf= new StringBuffer();
sbuf.append(msg); sbuf.append(msg);
this.code = code; this.code = code;
sbuf.append(code); sbuf.append(code);
sbuf.append("\r\n"); sbuf.append("\r\n");
msg = Resource.getProperties().get(code); msg = Resource.getProperties().get(code);
// 记录自定义的 异常 // 记录自定义的 异常
if (null != msg) { if (null != msg) {
sbuf.append(msg); sbuf.append(msg);
sbuf.append("\r\n"); sbuf.append("\r\n");
} }
// 记录原始的异常 // 记录原始的异常
if (null != e) { if (null != e) {
StackTraceElement[] array = e.getStackTrace(); StackTraceElement[] array = e.getStackTrace();
cause = e.getCause(); cause = e.getCause();
for (StackTraceElement stackTraceElement : array) { for (StackTraceElement stackTraceElement : array) {
sbuf.append(stackTraceElement.toString()); sbuf.append(stackTraceElement.toString());
sbuf.append("\r\n"); sbuf.append("\r\n");
} }
} }
//记录 出现异常时 当前的对象 //记录 出现异常时 当前的对象
if (null != obj) { if (null != obj) {
Object[] array = obj; Object[] array = obj;
sbuf.append("Object[] size : "); sbuf.append("Object[] size : ");
sbuf.append(array.length); sbuf.append(array.length);
int forSize = 0; int forSize = 0;
if (Constant.CustomException_log_object_size < array.length) { if (Constant.CustomException_log_object_size < array.length) {
forSize = Constant.CustomException_log_object_size; forSize = Constant.CustomException_log_object_size;
} }
else { else {
forSize = array.length; forSize = array.length;
} }
for (int i = 0; i < forSize; i++) { for (int i = 0; i < forSize; i++) {
sbuf.append(array[i]); sbuf.append(array[i]);
sbuf.append("\r\n"); sbuf.append("\r\n");
} }
sbuf.append("......"); sbuf.append("......");
sbuf.append("\r\n"); sbuf.append("\r\n");
} }
else { else {
sbuf.append("null"); sbuf.append("null");
sbuf.append("\r\n"); sbuf.append("\r\n");
} }
sbuf.append("\r\n"); sbuf.append("\r\n");
// 是否 写入 文件 // 是否 写入 文件
log.error(sbuf.toString()); log.error(sbuf.toString());
} }
/** /**
* @ msg * @ msg
* @return msg * @return msg
*/ */
public String getMsg() { public String getMsg() {
return msg; return msg;
} }
/** /**
* @return the code * @return the code
*/ */
public String getCode() { public String getCode() {
return code; return code;
} }
/** /**
* @ objArray * @ objArray
* @return objArray * @return objArray
*/ */
public Object[] getObjArray() { public Object[] getObjArray() {
return objArray; return objArray;
} }
/** /**
* @ cause * @ cause
* @return cause * @return cause
*/ */
public Throwable getCause() { public Throwable getCause() {
return cause; return cause;
} }
} }

@ -1,79 +1,79 @@
package com.base; package com.base;
import java.io.BufferedInputStream; import java.io.BufferedInputStream;
import java.io.BufferedReader; import java.io.BufferedReader;
import java.io.FileInputStream; import java.io.FileInputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.Map; import java.util.Map;
import java.util.Properties; import java.util.Properties;
import com.base.Constant; import com.base.Constant;
public class Resource { public class Resource {
private static Map<String, String> properties = new HashMap<>(); private static Map<String, String> properties = new HashMap<>();
static{ static{
// 读取 properties文件 // 读取 properties文件
// readPropertiesFile(Constant.SYSTEM_PROPERTIES_FIEL_PATH); // readPropertiesFile(Constant.SYSTEM_PROPERTIES_FIEL_PATH);
readPropertiesFile4Chinese(Constant.I18N_PROPERTIES_FIEL_PATH); readPropertiesFile4Chinese(Constant.I18N_PROPERTIES_FIEL_PATH);
} }
/** /**
* @ * @
* @param filename "/com/utils/exception/i18n.properties" * @param filename "/com/utils/exception/i18n.properties"
*/ */
public static void readPropertiesFile4Chinese(String filename) { public static void readPropertiesFile4Chinese(String filename) {
Properties pro = new Properties(); Properties pro = new Properties();
try { try {
// 读取属性文件 XXXX.propertiesReader。writer解决中文乱码 // 读取属性文件 XXXX.propertiesReader。writer解决中文乱码
// InputStreamReader in= new InputStreamReader(Resource.class.getClassLoader().getResourceAsStream(filename), "UTF-8"); // InputStreamReader in= new InputStreamReader(Resource.class.getClassLoader().getResourceAsStream(filename), "UTF-8");
InputStreamReader in= new InputStreamReader(Resource.class.getResourceAsStream(filename), "UTF-8"); InputStreamReader in= new InputStreamReader(Resource.class.getResourceAsStream(filename), "UTF-8");
BufferedReader bf = new BufferedReader(in); BufferedReader bf = new BufferedReader(in);
// InputStreamReader in = new BufferedInputStream(new FileInputStream(filename)); // InputStreamReader in = new BufferedInputStream(new FileInputStream(filename));
pro.load(bf); // /加载属性列表 pro.load(bf); // /加载属性列表
Iterator<String> it = pro.stringPropertyNames().iterator(); Iterator<String> it = pro.stringPropertyNames().iterator();
while (it.hasNext()) { while (it.hasNext()) {
String key = it.next(); String key = it.next();
properties.put(key, pro.getProperty(key)); properties.put(key, pro.getProperty(key));
} }
in.close(); in.close();
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
} }
/** /**
* @ properties * @ properties
* @return properties * @return properties
*/ */
public static Map<String, String> getProperties() { public static Map<String, String> getProperties() {
return properties; return properties;
} }
/** /**
* @ * @
* @param filename * @param filename
*/ */
public static void readPropertiesFile(String filename) { public static void readPropertiesFile(String filename) {
Properties pro = new Properties(); Properties pro = new Properties();
try { try {
// 读取属性文件 XXXX.properties 中文会 乱码) // 读取属性文件 XXXX.properties 中文会 乱码)
BufferedInputStream bf = new BufferedInputStream(new FileInputStream(filename)); BufferedInputStream bf = new BufferedInputStream(new FileInputStream(filename));
pro.load(bf); // /加载属性列表 pro.load(bf); // /加载属性列表
Iterator<String> it = pro.stringPropertyNames().iterator(); Iterator<String> it = pro.stringPropertyNames().iterator();
while (it.hasNext()) { while (it.hasNext()) {
String key = it.next(); String key = it.next();
properties.put(key, pro.getProperty(key)); properties.put(key, pro.getProperty(key));
} }
bf.close(); bf.close();
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); e.printStackTrace();
} }
} }
} }

@ -1,42 +1,42 @@
<?xml version="1.0" encoding="UTF-8" ?> <?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper <!DOCTYPE mapper
PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN" PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
"http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd"> "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
<mapper namespace="com.platform.dao.IRegionalismCodeDao"> <mapper namespace="com.platform.dao.IRegionalismCodeDao">
<resultMap id="getEntityByText" type="com.platform.entities.RegionalismEntity"> <resultMap id="getEntityByText" type="com.platform.entities.RegionalismEntity">
<id property="code" column="code" jdbcType="VARCHAR" /> <id property="code" column="code" jdbcType="VARCHAR" />
<result property="cityName" column="city_name" jdbcType="VARCHAR" /> <result property="cityName" column="city_name" jdbcType="VARCHAR" />
<result property="districtName" column="district_name" jdbcType="VARCHAR" /> <result property="districtName" column="district_name" jdbcType="VARCHAR" />
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
code,city_name,district_name code,city_name,district_name
</sql> </sql>
<!-- 获取数据全部记录信息 --> <!-- 获取数据全部记录信息 -->
<select id="findAllRegionalism" resultMap="getEntityByText"> <select id="findAllRegionalism" resultMap="getEntityByText">
SELECT SELECT
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
FROM regionalism_info FROM regionalism_info
order by code order by code
</select> </select>
<select id="findSubRegionalism" parameterType="com.platform.entities.RegionalismEntity" resultMap="getEntityByText"> <select id="findSubRegionalism" parameterType="com.platform.entities.RegionalismEntity" resultMap="getEntityByText">
SELECT SELECT
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
FROM regionalism_info FROM regionalism_info
<where> <where>
<if test="code != null and code != ''"> <if test="code != null and code != ''">
AND code LIKE CONCAT(CONCAT('%', #{code}), '%') AND code LIKE CONCAT(CONCAT('%', #{code}), '%')
</if> </if>
<if test="cityName != null and cityName != ''"> <if test="cityName != null and cityName != ''">
AND city_name LIKE CONCAT(CONCAT('%', #{cityName}), '%') AND city_name LIKE CONCAT(CONCAT('%', #{cityName}), '%')
</if> </if>
<if test="districtName != null and districtName != ''"> <if test="districtName != null and districtName != ''">
AND district_name LIKE CONCAT(CONCAT('%', #{districtName}), '%') AND district_name LIKE CONCAT(CONCAT('%', #{districtName}), '%')
</if> </if>
</where> </where>
order by code order by code
</select> </select>
</mapper> </mapper>

@ -1,42 +1,42 @@
<?xml version="1.0" encoding="UTF-8" ?> <?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper <!DOCTYPE mapper
PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN" PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
"http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd"> "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
<mapper namespace="com.platform.dao.ISystemCodeDao"> <mapper namespace="com.platform.dao.ISystemCodeDao">
<resultMap id="getEntityByText" type="com.platform.entities.SystemEntity"> <resultMap id="getEntityByText" type="com.platform.entities.SystemEntity">
<id property="code" column="code" jdbcType="INTEGER" /> <id property="code" column="code" jdbcType="INTEGER" />
<result property="systemName" column="system_name" jdbcType="VARCHAR" /> <result property="systemName" column="system_name" jdbcType="VARCHAR" />
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
code,system_name code,system_name
</sql> </sql>
<!-- 获取数据全部记录信息 --> <!-- 获取数据全部记录信息 -->
<select id="findAllSystem" resultMap="getEntityByText"> <select id="findAllSystem" resultMap="getEntityByText">
SELECT SELECT
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
FROM system_info FROM system_info
order by code order by code
</select> </select>
<select id="findSubSystem" parameterType="com.platform.entities.SystemEntity" resultMap="getEntityByText"> <select id="findSubSystem" parameterType="com.platform.entities.SystemEntity" resultMap="getEntityByText">
SELECT SELECT
<include refid="Base_Column_List" /> <include refid="Base_Column_List" />
FROM system_info FROM system_info
<where> <where>
<if test="code > 0"> <if test="code > 0">
AND code = #{code} AND code = #{code}
</if> </if>
<if test="cityName != null and cityName != ''"> <if test="cityName != null and cityName != ''">
AND city_name LIKE CONCAT(CONCAT('%', #{cityName}), '%') AND city_name LIKE CONCAT(CONCAT('%', #{cityName}), '%')
</if> </if>
<if test="districtName != null and districtName != ''"> <if test="districtName != null and districtName != ''">
AND district_name LIKE CONCAT(CONCAT('%', #{districtName}), '%') AND district_name LIKE CONCAT(CONCAT('%', #{districtName}), '%')
</if> </if>
</where> </where>
order by code order by code
</select> </select>
</mapper> </mapper>

@ -1,146 +1,146 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper <!DOCTYPE mapper
PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN" PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
"http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd"> "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
<mapper namespace="com.platform.dao.GatherOracleDao"> <mapper namespace="com.platform.dao.GatherOracleDao">
<resultMap type="com.platform.entities.GatherOracleInfo" id="getEntityBytext"> <resultMap type="com.platform.entities.GatherOracleInfo" id="getEntityBytext">
<id property="id" column="id" javaType="int" jdbcType="INTEGER" /> <id property="id" column="id" javaType="int" jdbcType="INTEGER" />
<result property="port" column="service_port" javaType="int" jdbcType="INTEGER"/> <result property="port" column="service_port" javaType="int" jdbcType="INTEGER"/>
<result property="ip" column="service_ip" javaType="string" jdbcType="VARCHAR"/> <result property="ip" column="service_ip" javaType="string" jdbcType="VARCHAR"/>
<result property="name" column="service_name" javaType="string" jdbcType="VARCHAR"/> <result property="name" column="service_name" javaType="string" jdbcType="VARCHAR"/>
<result property="user" column="service_user" javaType="string" jdbcType="VARCHAR"/> <result property="user" column="service_user" javaType="string" jdbcType="VARCHAR"/>
<result property="password" column="service_password" javaType="string" jdbcType="VARCHAR"/> <result property="password" column="service_password" javaType="string" jdbcType="VARCHAR"/>
<result property="databaseName" column="service_database" javaType="string" jdbcType="VARCHAR"/> <result property="databaseName" column="service_database" javaType="string" jdbcType="VARCHAR"/>
<result property="tableName" column="service_table" javaType="string" jdbcType="VARCHAR"/> <result property="tableName" column="service_table" javaType="string" jdbcType="VARCHAR"/>
<result property="suffix" column="service_suffix" javaType="string" jdbcType="VARCHAR"/> <result property="suffix" column="service_suffix" javaType="string" jdbcType="VARCHAR"/>
<result property="status" column="service_status" javaType="string" jdbcType="VARCHAR"/> <result property="status" column="service_status" javaType="string" jdbcType="VARCHAR"/>
<result property="remove" column="remove" jdbcType="CHAR"/> <result property="remove" column="remove" jdbcType="CHAR"/>
</resultMap> </resultMap>
<sql id="baseOracleInfo"> <sql id="baseOracleInfo">
id id, service_port port, service_ip ip, service_name name, service_user user, service_password password, service_database databaseName, service_table tableName, service_suffix suffix, service_status status id id, service_port port, service_ip ip, service_name name, service_user user, service_password password, service_database databaseName, service_table tableName, service_suffix suffix, service_status status
</sql> </sql>
<select id="selectAllOracle" resultType="com.platform.entities.GatherOracleInfo"> <select id="selectAllOracle" resultType="com.platform.entities.GatherOracleInfo">
SELECT SELECT
<include refid="baseOracleInfo" /> <include refid="baseOracleInfo" />
FROM services_info FROM services_info
WHERE remove = "0" WHERE remove = "0"
</select> </select>
<insert id="insertOracle" parameterType="com.platform.entities.GatherOracleInfo"> <insert id="insertOracle" parameterType="com.platform.entities.GatherOracleInfo">
INSERT INTO INSERT INTO
services_info( services_info(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="port > 0"> <if test="port > 0">
service_port, service_port,
</if> </if>
<if test="ip != null and ip != ''"> <if test="ip != null and ip != ''">
service_ip, service_ip,
</if> </if>
<if test="name != null and name != ''"> <if test="name != null and name != ''">
service_name, service_name,
</if> </if>
<if test="user != null and user != ''"> <if test="user != null and user != ''">
service_user, service_user,
</if> </if>
<if test="password != null and password != ''"> <if test="password != null and password != ''">
service_password, service_password,
</if> </if>
<if test="databaseName != null and databaseName != ''"> <if test="databaseName != null and databaseName != ''">
service_database, service_database,
</if> </if>
<if test="tableName != null and tableName != ''"> <if test="tableName != null and tableName != ''">
service_table, service_table,
</if> </if>
<if test="suffix != null and suffix != ''"> <if test="suffix != null and suffix != ''">
service_suffix, service_suffix,
</if> </if>
<if test="status != null and status != ''"> <if test="status != null and status != ''">
service_status, service_status,
</if> </if>
</trim> </trim>
) )
VALUES( VALUES(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="port > 0"> <if test="port > 0">
#{port}, #{port},
</if> </if>
<if test="ip != null and ip != ''"> <if test="ip != null and ip != ''">
#{ip}, #{ip},
</if> </if>
<if test="name != null and name != ''"> <if test="name != null and name != ''">
#{name}, #{name},
</if> </if>
<if test="user != null and user != ''"> <if test="user != null and user != ''">
#{user}, #{user},
</if> </if>
<if test="password != null and password != ''"> <if test="password != null and password != ''">
#{password}, #{password},
</if> </if>
<if test="databaseName != null and databaseName != ''"> <if test="databaseName != null and databaseName != ''">
#{databaseName}, #{databaseName},
</if> </if>
<if test="tableName != null and tableName != ''"> <if test="tableName != null and tableName != ''">
#{tableName}, #{tableName},
</if> </if>
<if test="suffix != null and suffix != ''"> <if test="suffix != null and suffix != ''">
#{suffix}, #{suffix},
</if> </if>
<if test="status != null and status != ''"> <if test="status != null and status != ''">
#{status}, #{status},
</if> </if>
</trim> </trim>
) )
</insert> </insert>
<delete id="deleteOracleById" parameterType="java.lang.Integer"> <delete id="deleteOracleById" parameterType="java.lang.Integer">
DELETE FROM services_info DELETE FROM services_info
<where> <where>
id =#{id} id =#{id}
</where> </where>
</delete> </delete>
<update id="updateOracleById" parameterType="com.platform.entities.GatherOracleInfo"> <update id="updateOracleById" parameterType="com.platform.entities.GatherOracleInfo">
UPDATE UPDATE
services_info services_info
<set > <set >
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="name != null and name != ''"> <if test="name != null and name != ''">
service_name = #{name}, service_name = #{name},
</if> </if>
<if test="ip != null and ip != ''"> <if test="ip != null and ip != ''">
service_ip = #{ip}, service_ip = #{ip},
</if> </if>
<if test="port > 0"> <if test="port > 0">
service_port= #{port}, service_port= #{port},
</if> </if>
<if test="user != null and user != ''"> <if test="user != null and user != ''">
service_user= #{user}, service_user= #{user},
</if> </if>
<if test="password != null and password != ''"> <if test="password != null and password != ''">
service_password= #{password}, service_password= #{password},
</if> </if>
<if test="databaseName != null and databaseName != ''"> <if test="databaseName != null and databaseName != ''">
service_database= #{databaseName}, service_database= #{databaseName},
</if> </if>
<if test="tableName != null and tableName != ''"> <if test="tableName != null and tableName != ''">
service_table= #{tableName}, service_table= #{tableName},
</if> </if>
<if test="suffix != null and suffix != ''"> <if test="suffix != null and suffix != ''">
service_suffix= #{suffix}, service_suffix= #{suffix},
</if> </if>
<if test="status != null and status != ''"> <if test="status != null and status != ''">
service_status= #{status}, service_status= #{status},
</if> </if>
<if test="remove != null and remove != ''"> <if test="remove != null and remove != ''">
remove= #{remove}, remove= #{remove},
</if> </if>
</trim> </trim>
</set> </set>
<where> <where>
id = #{id} id = #{id}
</where> </where>
</update> </update>
</mapper> </mapper>

@ -1,249 +1,249 @@
<?xml version="1.0" encoding="UTF-8" ?> <?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper <!DOCTYPE mapper
PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN" PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
"http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd"> "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
<mapper namespace="com.platform.dao.DataInfoDao"> <mapper namespace="com.platform.dao.DataInfoDao">
<resultMap id="getEntityByText" type="com.platform.entities.DataInfoEntity"> <resultMap id="getEntityByText" type="com.platform.entities.DataInfoEntity">
<id property="id" column="id" javaType="int" jdbcType="INTEGER" /> <id property="id" column="id" javaType="int" jdbcType="INTEGER" />
<result property="regionalismCode" column="regionalism_code" <result property="regionalismCode" column="regionalism_code"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="cityName" column="city_name" javaType="string" <result property="cityName" column="city_name" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="districtName" column="district_name" <result property="districtName" column="district_name"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="systemCode" column="system_code" javaType="int" <result property="systemCode" column="system_code" javaType="int"
jdbcType="INTEGER" /> jdbcType="INTEGER" />
<result property="systemName" column="system_name" javaType="string" <result property="systemName" column="system_name" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="dataType" column="data_type" javaType="string" <result property="dataType" column="data_type" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="dataVersion" column="data_version" javaType="int" <result property="dataVersion" column="data_version" javaType="int"
jdbcType="INTEGER" /> jdbcType="INTEGER" />
<result property="submittedBatch" column="submitted_batch" <result property="submittedBatch" column="submitted_batch"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="dataPath" column="data_path" javaType="string" <result property="dataPath" column="data_path" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="charset" column="data_charset" javaType="string" <result property="charset" column="data_charset" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="collectingTime" column="collection_time" <result property="collectingTime" column="collection_time"
javaType="string" jdbcType="DATE" /> javaType="string" jdbcType="DATE" />
<result property="collectorContacts" column="collector_contacts" <result property="collectorContacts" column="collector_contacts"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="collectorName" column="collector_name" <result property="collectorName" column="collector_name"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="extractStatus" column="extract_status" jdbcType="INTEGER" /> <result property="extractStatus" column="extract_status" jdbcType="INTEGER" />
<result property="year" column="data_year" javaType="string" <result property="year" column="data_year" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="startYear" column="start_year" javaType="string" <result property="startYear" column="start_year" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="endYear" column="end_year" javaType="string" <result property="endYear" column="end_year" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="volumeIp" column="volume_ip" javaType="string" <result property="volumeIp" column="volume_ip" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="volumePath" column="volume_path" javaType="string" <result property="volumePath" column="volume_path" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
</resultMap> </resultMap>
<sql id="conditionsFilters"> <sql id="conditionsFilters">
<if test="dataType!=null"> <if test="dataType!=null">
AND data_details.data_type=#{dataType} AND data_details.data_type=#{dataType}
</if> </if>
<if test="submittedBatch!=null"> <if test="submittedBatch!=null">
AND AND
data_details.submitted_batch=#{submittedBatch} data_details.submitted_batch=#{submittedBatch}
</if> </if>
<if test="cityName!=null"> <if test="cityName!=null">
AND data_details.city_name=#{cityName} AND data_details.city_name=#{cityName}
</if> </if>
<if test="districtName!=null"> <if test="districtName!=null">
AND AND
data_details.district_name=#{districtName} data_details.district_name=#{districtName}
</if> </if>
<if test="dataVersion !=null"> <if test="dataVersion !=null">
AND data_details.data_version=#{dataVersion} AND data_details.data_version=#{dataVersion}
</if> </if>
<if test="systemName !=null"> <if test="systemName !=null">
AND data_details.system_name=#{systemName} AND data_details.system_name=#{systemName}
</if> </if>
<if test="dataYear !=null"> <if test="dataYear !=null">
AND data_details.data_year=#{dataYear} AND data_details.data_year=#{dataYear}
</if> </if>
<if test="array !=null and array.length > 0"> <if test="array !=null and array.length > 0">
<foreach collection="array" item="item" index="index"> <foreach collection="array" item="item" index="index">
AND CONCAT(regionalism_code,system_code,city_name,district_name,system_name) LIKE CONCAT('%',CONCAT(#{item},'%')) AND CONCAT(regionalism_code,system_code,city_name,district_name,system_name) LIKE CONCAT('%',CONCAT(#{item},'%'))
</foreach> </foreach>
</if> </if>
</sql> </sql>
<!-- 获取数据符合筛选条件的全部记录信息 --> <!-- 获取数据符合筛选条件的全部记录信息 -->
<select id="getLimitedDataInfoEntities" parameterType="com.platform.entities.PagerOptions" <select id="getLimitedDataInfoEntities" parameterType="com.platform.entities.PagerOptions"
resultMap="getEntityByText"> resultMap="getEntityByText">
SELECT SELECT
id,regionalism_code,city_name,district_name,system_code,system_name,data_type,data_version,submitted_batch,data_path,data_charset,collection_time,collector_name,collector_contacts,extract_status,data_year,start_year,end_year,volume_ip,volume_path id,regionalism_code,city_name,district_name,system_code,system_name,data_type,data_version,submitted_batch,data_path,data_charset,collection_time,collector_name,collector_contacts,extract_status,data_year,start_year,end_year,volume_ip,volume_path
FROM data_details FROM data_details
<where> <where>
<include refid="conditionsFilters" /> <include refid="conditionsFilters" />
<choose> <choose>
<when test="offset > 0"> <when test="offset > 0">
and data_details.id>= #{offset} and data_details.id>= #{offset}
</when> </when>
<otherwise> <otherwise>
and data_details.id>=0 and data_details.id>=0
</otherwise> </otherwise>
</choose> </choose>
</where> </where>
ORDER BY data_details.id ORDER BY data_details.id
<if test="limit > 0"> <if test="limit > 0">
LIMIT #{limit} LIMIT #{limit}
</if> </if>
</select> </select>
<!-- 获取数据符合筛选条件的总记录条数 --> <!-- 获取数据符合筛选条件的总记录条数 -->
<select id="getLimitedDataCount" resultType="java.lang.Integer" <select id="getLimitedDataCount" resultType="java.lang.Integer"
parameterType="com.platform.entities.PagerOptions"> parameterType="com.platform.entities.PagerOptions">
SELECT COUNT(id) FROM data_details SELECT COUNT(id) FROM data_details
<where> <where>
<include refid="conditionsFilters" /> <include refid="conditionsFilters" />
</where> </where>
</select> </select>
<!-- 获取数据查询的起始di --> <!-- 获取数据查询的起始di -->
<select id="getLimitedBeginId" resultType="java.lang.Integer" <select id="getLimitedBeginId" resultType="java.lang.Integer"
parameterType="com.platform.entities.PagerOptions"> parameterType="com.platform.entities.PagerOptions">
SELECT MAX(idx) FROM (SELECT id idx FROM data_details SELECT MAX(idx) FROM (SELECT id idx FROM data_details
ORDER BY id LIMIT 0,#{totalLimit}) AS TEMP ORDER BY id LIMIT 0,#{totalLimit}) AS TEMP
</select> </select>
<insert id="save" parameterType="com.platform.entities.DataInfoEntity"> <insert id="save" parameterType="com.platform.entities.DataInfoEntity">
INSERT INTO INSERT INTO
data_info( data_info(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="regionalismCode != null and regionalismCode != ''"> <if test="regionalismCode != null and regionalismCode != ''">
regionalism_code, regionalism_code,
</if> </if>
<if test="systemCode != null"> <if test="systemCode != null">
system_code, system_code,
</if> </if>
<if test="dataType != null and dataType != ''"> <if test="dataType != null and dataType != ''">
data_type, data_type,
</if> </if>
<if test="dataVersion != null"> <if test="dataVersion != null">
data_version, data_version,
</if> </if>
<if test="submittedBatch != null and submittedBatch != ''"> <if test="submittedBatch != null and submittedBatch != ''">
submitted_batch, submitted_batch,
</if> </if>
<if test="dataPath != null and dataPath != ''"> <if test="dataPath != null and dataPath != ''">
data_path, data_path,
</if> </if>
<if test="collectingTime != null"> <if test="collectingTime != null">
collection_time, collection_time,
</if> </if>
<if test="collectorName != null and collectorName != ''"> <if test="collectorName != null and collectorName != ''">
collector_name, collector_name,
</if> </if>
<if test="collectorContacts != null and collectorContacts != ''"> <if test="collectorContacts != null and collectorContacts != ''">
collector_contacts, collector_contacts,
</if> </if>
<if test="charset != null and charset != ''"> <if test="charset != null and charset != ''">
data_charset, data_charset,
</if> </if>
<if test="year != null and year != ''"> <if test="year != null and year != ''">
data_year, data_year,
</if> </if>
<if test="startYear != null and startYear != ''"> <if test="startYear != null and startYear != ''">
start_year, start_year,
</if> </if>
<if test="endYear != null and endYear != ''"> <if test="endYear != null and endYear != ''">
end_year, end_year,
</if> </if>
<if test="volumeIp != null and volumeIp != ''"> <if test="volumeIp != null and volumeIp != ''">
volume_ip, volume_ip,
</if> </if>
<if test="volumePath != null and volumePath != ''"> <if test="volumePath != null and volumePath != ''">
volume_path, volume_path,
</if> </if>
<if test="extractStatus > 0"> <if test="extractStatus > 0">
extract_status, extract_status,
</if> </if>
</trim> </trim>
) )
VALUES( VALUES(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="regionalismCode != null and regionalismCode != ''"> <if test="regionalismCode != null and regionalismCode != ''">
#{regionalismCode}, #{regionalismCode},
</if> </if>
<if test="systemCode != null"> <if test="systemCode != null">
#{systemCode}, #{systemCode},
</if> </if>
<if test="dataType != null and dataType != ''"> <if test="dataType != null and dataType != ''">
#{dataType}, #{dataType},
</if> </if>
<if test="dataVersion != null"> <if test="dataVersion != null">
#{dataVersion}, #{dataVersion},
</if> </if>
<if test="submittedBatch != null and submittedBatch != ''"> <if test="submittedBatch != null and submittedBatch != ''">
#{submittedBatch}, #{submittedBatch},
</if> </if>
<if test="dataPath != null and dataPath != ''"> <if test="dataPath != null and dataPath != ''">
#{dataPath}, #{dataPath},
</if> </if>
<if test="collectingTime != null"> <if test="collectingTime != null">
#{collectingTime}, #{collectingTime},
</if> </if>
<if test="collectorName != null and collectorName != ''"> <if test="collectorName != null and collectorName != ''">
#{collectorName}, #{collectorName},
</if> </if>
<if test="collectorContacts != null and collectorContacts != ''"> <if test="collectorContacts != null and collectorContacts != ''">
#{collectorContacts}, #{collectorContacts},
</if> </if>
<if test="charset != null and charset != ''"> <if test="charset != null and charset != ''">
#{charset}, #{charset},
</if> </if>
<if test="year != null and year != ''"> <if test="year != null and year != ''">
#{year}, #{year},
</if> </if>
<if test="startYear != null and startYear != ''"> <if test="startYear != null and startYear != ''">
#{start_year}, #{start_year},
</if> </if>
<if test="endYear != null and endYear != ''"> <if test="endYear != null and endYear != ''">
#{end_year}, #{end_year},
</if> </if>
<if test="volumeIp != null and volumeIp != ''"> <if test="volumeIp != null and volumeIp != ''">
#{volumeIp}, #{volumeIp},
</if> </if>
<if test="volumePath != null and volumePath != ''"> <if test="volumePath != null and volumePath != ''">
#{volumePath}, #{volumePath},
</if> </if>
<if test="extractStatus > 0"> <if test="extractStatus > 0">
#{extractStatus}, #{extractStatus},
</if> </if>
</trim> </trim>
) )
</insert> </insert>
<select id="getIdIsExist" parameterType="java.util.List" resultType="java.lang.String"> <select id="getIdIsExist" parameterType="java.util.List" resultType="java.lang.String">
select data_path select data_path
from data_info from data_info
where id in where id in
<foreach item="item" index="index" collection="list" open="(" separator="," close=")"> <foreach item="item" index="index" collection="list" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
and remove ='0' and remove ='0'
</select> </select>
<update id="removes" parameterType="java.util.List"> <update id="removes" parameterType="java.util.List">
UPDATE UPDATE
data_info data_info
set remove = '1' set remove = '1'
where id in where id in
<foreach item="item" index="index" collection="list" open="(" separator="," close=")"> <foreach item="item" index="index" collection="list" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
and remove ='0' and remove ='0'
</update> </update>
</mapper> </mapper>

@ -1,189 +1,189 @@
<?xml version="1.0" encoding="UTF-8" ?> <?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper <!DOCTYPE mapper
PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN" PUBLIC "-//ibatis.apache.org//DTD Mapper 3.0//EN"
"http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd"> "http://ibatis.apache.org/dtd/ibatis-3-mapper.dtd">
<mapper namespace="com.platform.dao.DataInfoMoveTmpDao"> <mapper namespace="com.platform.dao.DataInfoMoveTmpDao">
<resultMap id="getEntityByText" type="com.platform.entities.DataInfoEntityMoveTmp"> <resultMap id="getEntityByText" type="com.platform.entities.DataInfoEntityMoveTmp">
<id property="id" column="id" javaType="int" jdbcType="INTEGER" /> <id property="id" column="id" javaType="int" jdbcType="INTEGER" />
<result property="regionalismCode" column="regionalism_code" <result property="regionalismCode" column="regionalism_code"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="cityName" column="city_name" javaType="string" <result property="cityName" column="city_name" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="districtName" column="district_name" <result property="districtName" column="district_name"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="systemCode" column="system_code" javaType="int" <result property="systemCode" column="system_code" javaType="int"
jdbcType="INTEGER" /> jdbcType="INTEGER" />
<result property="systemName" column="system_name" javaType="string" <result property="systemName" column="system_name" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="dataType" column="data_type" javaType="string" <result property="dataType" column="data_type" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="dataVersion" column="data_version" javaType="int" <result property="dataVersion" column="data_version" javaType="int"
jdbcType="INTEGER" /> jdbcType="INTEGER" />
<result property="submittedBatch" column="submitted_batch" <result property="submittedBatch" column="submitted_batch"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="dataPath" column="data_path" javaType="string" <result property="dataPath" column="data_path" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="charset" column="data_charset" javaType="string" <result property="charset" column="data_charset" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="collectingTime" column="collection_time" <result property="collectingTime" column="collection_time"
javaType="string" jdbcType="DATE" /> javaType="string" jdbcType="DATE" />
<result property="collectorContacts" column="collector_contacts" <result property="collectorContacts" column="collector_contacts"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="collectorName" column="collector_name" <result property="collectorName" column="collector_name"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="year" column="data_year" javaType="string" <result property="year" column="data_year" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="dstPath" column="dst_path" javaType="string" <result property="dstPath" column="dst_path" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="completeStatus" column="complete_status" javaType="string" <result property="completeStatus" column="complete_status" javaType="string"
jdbcType="VARCHAR" /> jdbcType="VARCHAR" />
<result property="rate" column="rate" javaType="int" <result property="rate" column="rate" javaType="int"
jdbcType="INTEGER" /> jdbcType="INTEGER" />
<result property="lastTime" column="lasttime" <result property="lastTime" column="lasttime"
javaType="string" jdbcType="VARCHAR" /> javaType="string" jdbcType="VARCHAR" />
<result property="fkid" column="fkid" javaType="int" jdbcType="INTEGER" /> <result property="fkid" column="fkid" javaType="int" jdbcType="INTEGER" />
<result property="dstVolumeIp" column="dst_volume_ip" jdbcType="VARCHAR" /> <result property="dstVolumeIp" column="dst_volume_ip" jdbcType="VARCHAR" />
<result property="dstVolumePath" column="dst_volume_ip" jdbcType="VARCHAR" /> <result property="dstVolumePath" column="dst_volume_ip" jdbcType="VARCHAR" />
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
regionalism_code,system_code,dst_path,lasttime,fkid regionalism_code,system_code,dst_path,lasttime,fkid
</sql> </sql>
<!-- 获取数据全部记录信息 --> <!-- 获取数据全部记录信息 -->
<select id="findAll" resultType="com.platform.entities.DataInfoEntityMoveTmp"> <select id="findAll" resultType="com.platform.entities.DataInfoEntityMoveTmp">
SELECT SELECT
a.id id,a.regionalism_code regionalismCode,a.dst_path dstPath,a.complete_status completeStatus, a.id id,a.regionalism_code regionalismCode,a.dst_path dstPath,a.complete_status completeStatus,
a.rate rate, a.lasttime lastTime, a.system_code systemCode,a.dst_volume_ip dstVolumeIp,a.dst_volume_path dstVolumePath, a.rate rate, a.lasttime lastTime, a.system_code systemCode,a.dst_volume_ip dstVolumeIp,a.dst_volume_path dstVolumePath,
b.city_name cityName,b.district_name districtName,b.system_name systemName,b.data_type dataType, b.city_name cityName,b.district_name districtName,b.system_name systemName,b.data_type dataType,
b.data_version dataVersion,b.submitted_batch submittedBatch,b.data_path dataPath,b.data_charset charset, b.data_version dataVersion,b.submitted_batch submittedBatch,b.data_path dataPath,b.data_charset charset,
b.collection_time collectingTime,b.collector_name collectorName,b.collector_contacts collectorContacts, b.collection_time collectingTime,b.collector_name collectorName,b.collector_contacts collectorContacts,
b.data_year year,b.extract_status extractStatus,b.start_year startYear,b.end_year endYear, b.data_year year,b.extract_status extractStatus,b.start_year startYear,b.end_year endYear,
b.volume_ip volumeIp,b.volume_path volumePath b.volume_ip volumeIp,b.volume_path volumePath
FROM FROM
move_data_tmp a LEFT JOIN data_details b move_data_tmp a LEFT JOIN data_details b
ON a.system_code = b.system_code AND a.regionalism_code = b.regionalism_code AND a.fkid = b.id ON a.system_code = b.system_code AND a.regionalism_code = b.regionalism_code AND a.fkid = b.id
ORDER BY a.id ORDER BY a.id
</select> </select>
<update id="update" parameterType="com.platform.entities.DataInfoEntityMoveTmp"> <update id="update" parameterType="com.platform.entities.DataInfoEntityMoveTmp">
UPDATE UPDATE
move_data_tmp move_data_tmp
<set > <set >
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="dstPath != null and dstPath != ''"> <if test="dstPath != null and dstPath != ''">
dst_path= #{dstPath}, dst_path= #{dstPath},
</if> </if>
<if test="completeStatus != null and completeStatus != ''"> <if test="completeStatus != null and completeStatus != ''">
complete_status= #{completeStatus}, complete_status= #{completeStatus},
</if> </if>
<if test="rate > 0"> <if test="rate > 0">
rate= #{rate}, rate= #{rate},
</if> </if>
<if test="lastTime != null and lastTime != ''"> <if test="lastTime != null and lastTime != ''">
lasttime= #{lastTime}, lasttime= #{lastTime},
</if> </if>
</trim> </trim>
</set> </set>
<where> <where>
id = #{id} id = #{id}
</where> </where>
</update> </update>
<insert id="save" parameterType="com.platform.entities.DataInfoEntityMoveTmp"> <insert id="save" parameterType="com.platform.entities.DataInfoEntityMoveTmp">
INSERT INTO INSERT INTO
move_data_tmp( move_data_tmp(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="id > 0"> <if test="id > 0">
id, id,
</if> </if>
<if test="regionalismCode != null and regionalismCode != ''"> <if test="regionalismCode != null and regionalismCode != ''">
regionalism_code, regionalism_code,
</if> </if>
<if test="systemCode != null"> <if test="systemCode != null">
system_code, system_code,
</if> </if>
<if test="dstPath != null and dstPath != ''"> <if test="dstPath != null and dstPath != ''">
dst_path, dst_path,
</if> </if>
<if test="completeStatus != null and completeStatus != ''"> <if test="completeStatus != null and completeStatus != ''">
complete_status, complete_status,
</if> </if>
<if test="rate > 0"> <if test="rate > 0">
rate, rate,
</if> </if>
<if test="lastTime != null and lastTime != ''"> <if test="lastTime != null and lastTime != ''">
lasttime, lasttime,
</if> </if>
<if test="fkid > 0 "> <if test="fkid > 0 ">
fkid, fkid,
</if> </if>
</trim> </trim>
) )
VALUES( VALUES(
<trim suffixOverrides=","> <trim suffixOverrides=",">
<if test="id > 0"> <if test="id > 0">
id, id,
</if> </if>
<if test="regionalismCode != null and regionalismCode != ''"> <if test="regionalismCode != null and regionalismCode != ''">
#{regionalismCode}, #{regionalismCode},
</if> </if>
<if test="systemCode != null and systemCode != ''"> <if test="systemCode != null and systemCode != ''">
#{systemCode}, #{systemCode},
</if> </if>
<if test="dstPath != null and dstPath != ''"> <if test="dstPath != null and dstPath != ''">
#{dstPath}, #{dstPath},
</if> </if>
<if test="completeStatus != null and completeStatus != ''"> <if test="completeStatus != null and completeStatus != ''">
#{completeStatus}, #{completeStatus},
</if> </if>
<if test="rate > 0"> <if test="rate > 0">
#{rate} #{rate}
</if> </if>
<if test="lastTime != null and lastTime != ''"> <if test="lastTime != null and lastTime != ''">
#{lastTime}, #{lastTime},
</if> </if>
<if test="fkid > 0 "> <if test="fkid > 0 ">
#{fkid), #{fkid),
</if> </if>
</trim> </trim>
) )
</insert> </insert>
<select id="insertBatch" parameterType="java.util.List"> <select id="insertBatch" parameterType="java.util.List">
INSERT INTO move_data_tmp ( <include refid="Base_Column_List" /> ) INSERT INTO move_data_tmp ( <include refid="Base_Column_List" /> )
VALUES VALUES
<foreach collection="list" item="item" index="index" separator=","> <foreach collection="list" item="item" index="index" separator=",">
(#{item.regionalismCode,jdbcType=VARCHAR},#{item.systemCode,jdbcType=INTEGER},#{item.dstPath,jdbcType=VARCHAR},#{item.lastTime,jdbcType=VARCHAR},#{item.fkid}) (#{item.regionalismCode,jdbcType=VARCHAR},#{item.systemCode,jdbcType=INTEGER},#{item.dstPath,jdbcType=VARCHAR},#{item.lastTime,jdbcType=VARCHAR},#{item.fkid})
</foreach> </foreach>
</select> </select>
<delete id="remove" parameterType="java.lang.Integer"> <delete id="remove" parameterType="java.lang.Integer">
DELETE FROM DELETE FROM
move_data_tmp move_data_tmp
WHERE WHERE
id = #{id} id = #{id}
</delete> </delete>
<!-- 获取数据符合筛选条件的总记录条数 --> <!-- 获取数据符合筛选条件的总记录条数 -->
<!-- <!--
<select id="getLimitedDataCount" resultType="java.lang.Integer" <select id="getLimitedDataCount" resultType="java.lang.Integer"
parameterType="PagerOptions"> parameterType="PagerOptions">
SELECT COUNT(id) FROM move_data_tmp SELECT COUNT(id) FROM move_data_tmp
<if test="PagerOptions!=null"> <if test="PagerOptions!=null">
<where> <where>
<include refid="conditionsFilters" /> <include refid="conditionsFilters" />
</where> </where>
</if> </if>
</select> </select>
获取数据查询的起始di 获取数据查询的起始di
<select id="getLimitedBeginId" resultType="java.lang.Integer" <select id="getLimitedBeginId" resultType="java.lang.Integer"
parameterType="PagerOptions"> parameterType="PagerOptions">
SELECT MAX(idx) FROM (SELECT id idx FROM move_data_tmp SELECT MAX(idx) FROM (SELECT id idx FROM move_data_tmp
ORDER BY id LIMIT 0,#{PagerOptions.totalLimit}) AS TEMP ORDER BY id LIMIT 0,#{PagerOptions.totalLimit}) AS TEMP
</select> --> </select> -->
</mapper> </mapper>

@ -1,32 +1,32 @@
package com.platform.controller; package com.platform.controller;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap; import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView; import org.springframework.web.servlet.ModelAndView;
import com.platform.utils.Configs; import com.platform.utils.Configs;
@Controller @Controller
public class DefaultController { public class DefaultController {
@RequestMapping("/") @RequestMapping("/")
public ModelAndView defaultHandler(HttpServletRequest req, HttpServletResponse res){ public ModelAndView defaultHandler(HttpServletRequest req, HttpServletResponse res){
//处理不匹配的请求 //处理不匹配的请求
System.out.println("index"); System.out.println("index");
return new ModelAndView("index"); return new ModelAndView("index");
} }
@RequestMapping("/test") @RequestMapping("/test")
public ModelMap test(HttpServletRequest req, HttpServletResponse res){ public ModelMap test(HttpServletRequest req, HttpServletResponse res){
//System.out.println(Class.class.getClass().getResource("/").getPath()); //System.out.println(Class.class.getClass().getResource("/").getPath());
System.out.println(Configs.EXTRACT_LOG_LOCALTION); System.out.println(Configs.EXTRACT_LOG_LOCALTION);
return new ModelMap(); return new ModelMap();
} }
} }

@ -1,114 +1,114 @@
package com.platform.controller; package com.platform.controller;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
import javax.annotation.Resource; import javax.annotation.Resource;
import oracle.sql.DATE; import oracle.sql.DATE;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestMethod;
import com.base.BaseController; import com.base.BaseController;
import com.base.CustomException; import com.base.CustomException;
import com.platform.entities.GfsFolderEntity; import com.platform.entities.GfsFolderEntity;
import com.platform.entities.VolumeEntity; import com.platform.entities.VolumeEntity;
import com.platform.glusterfs.VolumeInfo; import com.platform.glusterfs.VolumeInfo;
import com.platform.entities.VolumeEntity; import com.platform.entities.VolumeEntity;
import com.platform.glusterfs.VolumeInfo; import com.platform.glusterfs.VolumeInfo;
import com.platform.service.IGfsService; import com.platform.service.IGfsService;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
@Controller @Controller
@RequestMapping("") @RequestMapping("")
public class FolderController extends BaseController { public class FolderController extends BaseController {
@Resource(name = "gfsService") @Resource(name = "gfsService")
private IGfsService gfsService; private IGfsService gfsService;
@RequestMapping(value="/getAllSubPathByPath", method= RequestMethod.POST) @RequestMapping(value="/getAllSubPathByPath", method= RequestMethod.POST)
public Object getAllSubPathByPath(String path) throws Exception { public Object getAllSubPathByPath(String path) throws Exception {
System.out.println(path); System.out.println(path);
Object result = null; Object result = null;
if (null != path && !"".equals(path)) { if (null != path && !"".equals(path)) {
System.out.println(path); System.out.println(path);
result = gfsService.getFolder(path); result = gfsService.getFolder(path);
} }
return result; return result;
} }
@RequestMapping("/copyFolder") @RequestMapping("/copyFolder")
public Object copyFolder(String srcpath, String dstPath, String name) throws Exception { public Object copyFolder(String srcpath, String dstPath, String name) throws Exception {
// -1 :error; -2: the filename is not exists ;-3 :destFolderName ; 1: right // -1 :error; -2: the filename is not exists ;-3 :destFolderName ; 1: right
int result = 0; int result = 0;
// int result = gfsService.copyFolder(srcpath, dstPath, name); // int result = gfsService.copyFolder(srcpath, dstPath, name);
System.out.println(srcpath); System.out.println(srcpath);
System.out.println(dstPath); System.out.println(dstPath);
String obj = "right"; String obj = "right";
if (1 != result) { if (1 != result) {
obj = "err"; obj = "err";
} }
return obj; return obj;
} }
// /** // /**
// * <一句话功能简述> 查询集群中所有的 volume 及其 信息 // * <一句话功能简述> 查询集群中所有的 volume 及其 信息
// * <功能详细描述> // * <功能详细描述>
// * @return // * @return
// * @throws Exception // * @throws Exception
// * @see [类、类#方法、类#成员] // * @see [类、类#方法、类#成员]
// */ // */
// @RequestMapping(value="/volume/list", method= RequestMethod.POST) // @RequestMapping(value="/volume/list", method= RequestMethod.POST)
// public Object getVolums() throws Exception{ // public Object getVolums() throws Exception{
// System.out.println("----------------------------------"); // System.out.println("----------------------------------");
// long a = new Date().getTime(); // long a = new Date().getTime();
// List<VolumeEntity> result = gfsService.getAllVolumes(); // List<VolumeEntity> result = gfsService.getAllVolumes();
// System.out.println("----------------------------------"); // System.out.println("----------------------------------");
// System.out.println(new Date().getTime()-a); // System.out.println(new Date().getTime()-a);
// return result; // return result;
// } // }
// //
/** /**
* <> volume * <> volume
* <> * <>
* @param volumeName "/home/gfs_ftp_point" "/home/v1_point" * @param volumeName "/home/gfs_ftp_point" "/home/v1_point"
* @return * @return
* @throws Exception * @throws Exception
* @see [##] * @see [##]
*/ */
@RequestMapping(value="/volume/findByName", method= RequestMethod.POST) @RequestMapping(value="/volume/findByName", method= RequestMethod.POST)
public Object getVolumByName(String volumeName) throws Exception{ public Object getVolumByName(String volumeName) throws Exception{
VolumeEntity result = gfsService.getOneVolume(volumeName); VolumeEntity result = gfsService.getOneVolume(volumeName);
return result; return result;
} }
} }

@ -1,52 +1,52 @@
/** /**
* : SetGlusterfs.java * : SetGlusterfs.java
* : </> * : </>
* : <> * : <>
* @author liliy * @author liliy
* : <> * : <>
* 201698 * 201698
* <> * <>
*/ */
package com.platform.controller; package com.platform.controller;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
/** /**
* <> * <>
* <> * <>
* <> * <>
* @author liliy * @author liliy
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
@Controller @Controller
public class SetGlusterfsController { public class SetGlusterfsController {
@RequestMapping("/tes") @RequestMapping("/tes")
public Object defaultHandler(HttpServletRequest req, HttpServletResponse request) { public Object defaultHandler(HttpServletRequest req, HttpServletResponse request) {
//<2F><><EFBFBD><><C6A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> //<2F><><EFBFBD><><C6A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
try { try {
System.out.println("fsdfds"); System.out.println("fsdfds");
return "listAll"; return "listAll";
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
return "result"; return "result";
} }
} }
} }

@ -1,50 +1,50 @@
/** /**
* : ShowGlusterfsController.java * : ShowGlusterfsController.java
* : </> * : </>
* : <> * : <>
* @author liliy * @author liliy
* : <> * : <>
* 201698 * 201698
* <> * <>
*/ */
package com.platform.controller; package com.platform.controller;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import com.platform.glusterfs.ClusterInfo; import com.platform.glusterfs.ClusterInfo;
import com.platform.glusterfs.VolumeInfo; import com.platform.glusterfs.VolumeInfo;
/** /**
* <> * <>
* <> * <>
* @author liliy * @author liliy
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
@Controller @Controller
public class ShowGlusterfsController { public class ShowGlusterfsController {
/** /**
* <> * <>
* <> * <>
* @return * @return
* @see [##] * @see [##]
*/ */
@RequestMapping("/showPeerStatus") @RequestMapping("/showPeerStatus")
public Map<String,String> showPeerStatus(){ public Map<String,String> showPeerStatus(){
Map<String, String> peer_status=new ClusterInfo().showClusterInfo(); Map<String, String> peer_status=new ClusterInfo().showClusterInfo();
return peer_status; return peer_status;
} }
} }

@ -1,27 +1,27 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.DataInfoEntity; import com.platform.entities.DataInfoEntity;
import com.platform.entities.PagerOptions; import com.platform.entities.PagerOptions;
@Repository(value = "dataInfoDao") @Repository(value = "dataInfoDao")
public interface DataInfoDao { public interface DataInfoDao {
int getLimitedDataCount(PagerOptions pagerOptions); int getLimitedDataCount(PagerOptions pagerOptions);
int getLimitedBeginId(PagerOptions pagerOptions); int getLimitedBeginId(PagerOptions pagerOptions);
List<DataInfoEntity> getLimitedDataInfoEntities(PagerOptions pagerOptions); List<DataInfoEntity> getLimitedDataInfoEntities(PagerOptions pagerOptions);
List<String> getIdIsExist(List<Integer> list)throws Exception; List<String> getIdIsExist(List<Integer> list)throws Exception;
int removes(List<Integer> list)throws Exception; int removes(List<Integer> list)throws Exception;
int save(DataInfoEntity data) throws Exception; int save(DataInfoEntity data) throws Exception;
} }

@ -1,29 +1,29 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.DataInfoEntityMoveTmp; import com.platform.entities.DataInfoEntityMoveTmp;
/** /**
* @author chen * @author chen
* *
*/ */
@Repository(value = "dataInfoMoveTmpDao") @Repository(value = "dataInfoMoveTmpDao")
public interface DataInfoMoveTmpDao { public interface DataInfoMoveTmpDao {
/** /**
* @return * @return
* @throws Exception * @throws Exception
*/ */
List<DataInfoEntityMoveTmp> findAll() throws Exception; List<DataInfoEntityMoveTmp> findAll() throws Exception;
int update(DataInfoEntityMoveTmp data) throws Exception; int update(DataInfoEntityMoveTmp data) throws Exception;
int save(DataInfoEntityMoveTmp data) throws Exception; int save(DataInfoEntityMoveTmp data) throws Exception;
void insertBatch(List<DataInfoEntityMoveTmp> list) throws Exception; void insertBatch(List<DataInfoEntityMoveTmp> list) throws Exception;
int remove(int id) throws Exception; int remove(int id) throws Exception;
} }

@ -1,99 +1,99 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import org.apache.ibatis.annotations.Delete; import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert; import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select; import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update; import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.EncodedInfoEntity; import com.platform.entities.EncodedInfoEntity;
/** /**
* : * :
* *
* @author wuming * @author wuming
* *
*/ */
@Repository(value = "encodeInfoDao") @Repository(value = "encodeInfoDao")
public interface EncodeInfoDao { public interface EncodeInfoDao {
/** /**
* / * /
* *
* @param tableName * @param tableName
* *
* @return : * @return :
*/ */
@Select("SELECT code, name FROM ${tableName}") @Select("SELECT code, name FROM ${tableName}")
public List<EncodedInfoEntity> getAllEntityInfo( public List<EncodedInfoEntity> getAllEntityInfo(
@Param("tableName") String tableName); @Param("tableName") String tableName);
/** /**
* / * /
* *
* @param code * @param code
* *
* @param tableName * @param tableName
* *
* @return * @return
*/ */
@Select("SELECT name FROM ${tableName} WHERE code = #{code}") @Select("SELECT name FROM ${tableName} WHERE code = #{code}")
public String getEncodeNameByCode(@Param("code") String code, public String getEncodeNameByCode(@Param("code") String code,
@Param("tableName") String tableName); @Param("tableName") String tableName);
/** /**
* / * /
* *
* @param name * @param name
* *
* @param tableName * @param tableName
* *
* @return * @return
*/ */
@Select("SELECT code FROM ${tableName} WHERE name = #{name}") @Select("SELECT code FROM ${tableName} WHERE name = #{name}")
public List<String> getEncodeCodeByName(@Param("name") String name, public List<String> getEncodeCodeByName(@Param("name") String name,
@Param("tableName") String tableName); @Param("tableName") String tableName);
/** /**
* / * /
* *
* @param code * @param code
* *
* @param tableName * @param tableName
* *
* @return * @return
*/ */
@Update("UPDATE ${tableName} SET name = #{name} WHERE code = #{code}") @Update("UPDATE ${tableName} SET name = #{name} WHERE code = #{code}")
public int updateEncodeNameByCode(@Param("code") String code, public int updateEncodeNameByCode(@Param("code") String code,
@Param("name") String name, @Param("tableName") String tableName); @Param("name") String name, @Param("tableName") String tableName);
/** /**
* / * /
* *
* @param efe * @param efe
* *
* @param tableName * @param tableName
* *
* @return * @return
*/ */
@Insert("INSERT INTO ${tableName} (code, name) VALUES (#{efe.code}, #{efe.name})") @Insert("INSERT INTO ${tableName} (code, name) VALUES (#{efe.code}, #{efe.name})")
public int insertEncodeEntity(@Param("efe") EncodedInfoEntity efe, public int insertEncodeEntity(@Param("efe") EncodedInfoEntity efe,
@Param("tableName") String tableName); @Param("tableName") String tableName);
/** /**
* / * /
* *
* @param code * @param code
* *
* @param tableName * @param tableName
* *
* @return * @return
*/ */
@Delete("DELETE FROM ${tableName} WHERE code = #{code}") @Delete("DELETE FROM ${tableName} WHERE code = #{code}")
public int deleteEncodeByCode(@Param("code") String code, public int deleteEncodeByCode(@Param("code") String code,
@Param("tableName") String tableName); @Param("tableName") String tableName);
} }

@ -1,39 +1,39 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.GatherOracleInfo; import com.platform.entities.GatherOracleInfo;
@Repository(value = "gatherOracleDao") @Repository(value = "gatherOracleDao")
public interface GatherOracleDao { public interface GatherOracleDao {
/** /**
* @return oracle * @return oracle
* @throws Exception * @throws Exception
*/ */
public List<GatherOracleInfo> selectAllOracle() throws Exception; public List<GatherOracleInfo> selectAllOracle() throws Exception;
/** /**
* @param id * @param id
* @return * @return
* @throws Exception * @throws Exception
*/ */
public int deleteOracleById(int id) throws Exception; public int deleteOracleById(int id) throws Exception;
/** /**
* @param oracle * @param oracle
* @return * @return
* @throws Exception * @throws Exception
*/ */
public int insertOracle(GatherOracleInfo oracle) throws Exception; public int insertOracle(GatherOracleInfo oracle) throws Exception;
/** /**
* @param oracle * @param oracle
* @return * @return
* @throws Exception * @throws Exception
*/ */
public int updateOracleById(GatherOracleInfo oracle) throws Exception; public int updateOracleById(GatherOracleInfo oracle) throws Exception;
} }

@ -1,28 +1,28 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.DataInfoEntity; import com.platform.entities.DataInfoEntity;
import com.platform.entities.DataInfoEntityMoveTmp; import com.platform.entities.DataInfoEntityMoveTmp;
import com.platform.entities.PagerOptions; import com.platform.entities.PagerOptions;
import com.platform.entities.RegionalismEntity; import com.platform.entities.RegionalismEntity;
/** /**
* @author chen * @author chen
* *
*/ */
@Repository(value = "regionalismCodeDao") @Repository(value = "regionalismCodeDao")
public interface IRegionalismCodeDao { public interface IRegionalismCodeDao {
/** /**
* @return * @return
* @throws Exception * @throws Exception
*/ */
List<RegionalismEntity> findAllRegionalism() throws Exception; List<RegionalismEntity> findAllRegionalism() throws Exception;
List<RegionalismEntity> findSubRegionalism(RegionalismEntity region) throws Exception; List<RegionalismEntity> findSubRegionalism(RegionalismEntity region) throws Exception;
} }

@ -1,28 +1,28 @@
package com.platform.dao; package com.platform.dao;
import java.util.List; import java.util.List;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import com.platform.entities.DataInfoEntity; import com.platform.entities.DataInfoEntity;
import com.platform.entities.DataInfoEntityMoveTmp; import com.platform.entities.DataInfoEntityMoveTmp;
import com.platform.entities.PagerOptions; import com.platform.entities.PagerOptions;
import com.platform.entities.RegionalismEntity; import com.platform.entities.RegionalismEntity;
import com.platform.entities.SystemEntity; import com.platform.entities.SystemEntity;
/** /**
* @author chen * @author chen
* *
*/ */
@Repository(value = "systemCodeDao") @Repository(value = "systemCodeDao")
public interface ISystemCodeDao { public interface ISystemCodeDao {
/** /**
* @return * @return
* @throws Exception * @throws Exception
*/ */
List<SystemEntity> findAllSystem() throws Exception; List<SystemEntity> findAllSystem() throws Exception;
List<SystemEntity> findSubSystem(SystemEntity system) throws Exception; List<SystemEntity> findSubSystem(SystemEntity system) throws Exception;
} }

@ -1,48 +1,48 @@
package com.platform.entities; package com.platform.entities;
import java.util.Date; import java.util.Date;
public enum BasedType { public enum BasedType {
STRING("java.lang.String", String.class), INTEGER("java.lang.Integer", STRING("java.lang.String", String.class), INTEGER("java.lang.Integer",
Integer.class), SHORT("java.lang.Short", Short.class), LONG( Integer.class), SHORT("java.lang.Short", Short.class), LONG(
"java.lang.Long", Long.class), DATE("java.util.Date", Date.class); "java.lang.Long", Long.class), DATE("java.util.Date", Date.class);
private String type; private String type;
private Class<?> clazz; private Class<?> clazz;
private BasedType(String type, Class<?> clazz) { private BasedType(String type, Class<?> clazz) {
this.type = type; this.type = type;
this.clazz = clazz; this.clazz = clazz;
} }
public static Class<?> getTypeClass(String type) { public static Class<?> getTypeClass(String type) {
for (BasedType bt : BasedType.values()) { for (BasedType bt : BasedType.values()) {
if (bt.equals(type)) if (bt.equals(type))
return bt.clazz; return bt.clazz;
} }
return null; return null;
} }
public String getType() { public String getType() {
return type; return type;
} }
public void setType(String type) { public void setType(String type) {
this.type = type; this.type = type;
} }
public Class<?> getClazz() { public Class<?> getClazz() {
return clazz; return clazz;
} }
public void setClazz(Class<?> clazz) { public void setClazz(Class<?> clazz) {
this.clazz = clazz; this.clazz = clazz;
} }
@Override @Override
public String toString() { public String toString() {
return this.type; return this.type;
} }
} }

@ -1,269 +1,269 @@
package com.platform.entities; package com.platform.entities;
/** /**
* *
* *
* @author wuming * @author wuming
* *
*/ */
public class DataInfoEntity { public class DataInfoEntity {
private int id; private int id;
private String regionalismCode; // 行政区划编码 private String regionalismCode; // 行政区划编码
private String cityName; // 市 private String cityName; // 市
private String districtName; // 区县 private String districtName; // 区县
private int systemCode; // 系统编码 private int systemCode; // 系统编码
private String systemName; // 系统名称 private String systemName; // 系统名称
private String dataType; // 数据类型:财政\社保\... private String dataType; // 数据类型:财政\社保\...
private int dataVersion; // 数据版本 private int dataVersion; // 数据版本
private String submittedBatch; // 上报批次 private String submittedBatch; // 上报批次
private String dataPath; // 数据路径 private String dataPath; // 数据路径
private String collectingTime; // 采集时间 private String collectingTime; // 采集时间
private String collectorContacts; // 采集人的联系 private String collectorContacts; // 采集人的联系
private String charset; // 数据的字符编码 private String charset; // 数据的字符编码
private String collectorName; // 采集人姓名 private String collectorName; // 采集人姓名
private String year; // 数据年度 private String year; // 数据年度
/** 是否抽取 */ /** 是否抽取 */
private int extractStatus; private int extractStatus;
/** 数据年度起始 */ /** 数据年度起始 */
private String startYear; private String startYear;
/** 数据年度结束 */ /** 数据年度结束 */
private String endYear; private String endYear;
/** volume的ip */ /** volume的ip */
private String volumeIp; private String volumeIp;
/** volume的path */ /** volume的path */
private String volumePath; private String volumePath;
public DataInfoEntity() { public DataInfoEntity() {
} }
public DataInfoEntity(int id, String regionalismCode, String cityName, public DataInfoEntity(int id, String regionalismCode, String cityName,
String districtName, int systemCode, String systemName, String districtName, int systemCode, String systemName,
String dataType, int dataVersion, String submittedBatch, String dataType, int dataVersion, String submittedBatch,
String dataPath, String collectingTime, String collectorContacts, String dataPath, String collectingTime, String collectorContacts,
String charset, String collectorName, String year) { String charset, String collectorName, String year) {
super(); super();
this.id = id; this.id = id;
this.regionalismCode = regionalismCode; this.regionalismCode = regionalismCode;
this.cityName = cityName; this.cityName = cityName;
this.districtName = districtName; this.districtName = districtName;
this.systemCode = systemCode; this.systemCode = systemCode;
this.systemName = systemName; this.systemName = systemName;
this.dataType = dataType; this.dataType = dataType;
this.dataVersion = dataVersion; this.dataVersion = dataVersion;
this.submittedBatch = submittedBatch; this.submittedBatch = submittedBatch;
this.dataPath = dataPath; this.dataPath = dataPath;
this.collectingTime = collectingTime; this.collectingTime = collectingTime;
this.collectorContacts = collectorContacts; this.collectorContacts = collectorContacts;
this.charset = charset; this.charset = charset;
this.collectorName = collectorName; this.collectorName = collectorName;
this.year = year; this.year = year;
} }
public int getId() { public int getId() {
return id; return id;
} }
public void setId(int id) { public void setId(int id) {
this.id = id; this.id = id;
} }
public String getRegionalismCode() { public String getRegionalismCode() {
return regionalismCode; return regionalismCode;
} }
public void setRegionalismCode(String regionalismCode) { public void setRegionalismCode(String regionalismCode) {
this.regionalismCode = regionalismCode; this.regionalismCode = regionalismCode;
} }
public String getCityName() { public String getCityName() {
return cityName; return cityName;
} }
public void setCityName(String cityName) { public void setCityName(String cityName) {
this.cityName = cityName; this.cityName = cityName;
} }
public String getDistrictName() { public String getDistrictName() {
return districtName; return districtName;
} }
public void setDistrictName(String districtName) { public void setDistrictName(String districtName) {
this.districtName = districtName; this.districtName = districtName;
} }
public int getSystemCode() { public int getSystemCode() {
return systemCode; return systemCode;
} }
public void setSystemCode(int systemCode) { public void setSystemCode(int systemCode) {
this.systemCode = systemCode; this.systemCode = systemCode;
} }
public String getSystemName() { public String getSystemName() {
return systemName; return systemName;
} }
public void setSystemName(String systemName) { public void setSystemName(String systemName) {
this.systemName = systemName; this.systemName = systemName;
} }
public String getDataType() { public String getDataType() {
return dataType; return dataType;
} }
public void setDataType(String dataType) { public void setDataType(String dataType) {
this.dataType = dataType; this.dataType = dataType;
} }
public int getDataVersion() { public int getDataVersion() {
return dataVersion; return dataVersion;
} }
public void setDataVersion(int dataVersion) { public void setDataVersion(int dataVersion) {
this.dataVersion = dataVersion; this.dataVersion = dataVersion;
} }
public String getSubmittedBatch() { public String getSubmittedBatch() {
return submittedBatch; return submittedBatch;
} }
public void setSubmittedBatch(String submittedBatch) { public void setSubmittedBatch(String submittedBatch) {
this.submittedBatch = submittedBatch; this.submittedBatch = submittedBatch;
} }
public String getDataPath() { public String getDataPath() {
return dataPath; return dataPath;
} }
public void setDataPath(String dataPath) { public void setDataPath(String dataPath) {
this.dataPath = dataPath; this.dataPath = dataPath;
} }
public String getCollectingTime() { public String getCollectingTime() {
return collectingTime; return collectingTime;
} }
public void setCollectingTime(String collectingTime) { public void setCollectingTime(String collectingTime) {
this.collectingTime = collectingTime; this.collectingTime = collectingTime;
} }
public String getCollectorContacts() { public String getCollectorContacts() {
return collectorContacts; return collectorContacts;
} }
public void setCollectorContacts(String collectorContacts) { public void setCollectorContacts(String collectorContacts) {
this.collectorContacts = collectorContacts; this.collectorContacts = collectorContacts;
} }
public String getCharset() { public String getCharset() {
return charset; return charset;
} }
public void setCharset(String charset) { public void setCharset(String charset) {
this.charset = charset; this.charset = charset;
} }
public String getCollectorName() { public String getCollectorName() {
return collectorName; return collectorName;
} }
public void setCollectorName(String collectorName) { public void setCollectorName(String collectorName) {
this.collectorName = collectorName; this.collectorName = collectorName;
} }
public String getYear() { public String getYear() {
return year; return year;
} }
public void setYear(String year) { public void setYear(String year) {
this.year = year; this.year = year;
} }
/** /**
* @return the startYear * @return the startYear
*/ */
public String getStartYear() { public String getStartYear() {
return startYear; return startYear;
} }
/** /**
* @param startYear the startYear to set * @param startYear the startYear to set
*/ */
public void setStartYear(String startYear) { public void setStartYear(String startYear) {
this.startYear = startYear; this.startYear = startYear;
} }
/** /**
* @return the endYear * @return the endYear
*/ */
public String getEndYear() { public String getEndYear() {
return endYear; return endYear;
} }
/** /**
* @param endYear the endYear to set * @param endYear the endYear to set
*/ */
public void setEndYear(String endYear) { public void setEndYear(String endYear) {
this.endYear = endYear; this.endYear = endYear;
} }
/** /**
* @return the extractStatus * @return the extractStatus
*/ */
public int getExtractStatus() { public int getExtractStatus() {
return extractStatus; return extractStatus;
} }
/** /**
* @param extractStatus the extractStatus to set * @param extractStatus the extractStatus to set
*/ */
public void setExtractStatus(int extractStatus) { public void setExtractStatus(int extractStatus) {
this.extractStatus = extractStatus; this.extractStatus = extractStatus;
} }
/** /**
* @return the volumeIp * @return the volumeIp
*/ */
public String getVolumeIp() { public String getVolumeIp() {
return volumeIp; return volumeIp;
} }
/** /**
* @param volumeIp the volumeIp to set * @param volumeIp the volumeIp to set
*/ */
public void setVolumeIp(String volumeIp) { public void setVolumeIp(String volumeIp) {
this.volumeIp = volumeIp; this.volumeIp = volumeIp;
} }
/** /**
* @return the volumePath * @return the volumePath
*/ */
public String getVolumePath() { public String getVolumePath() {
return volumePath; return volumePath;
} }
/** /**
* @param volumePath the volumePath to set * @param volumePath the volumePath to set
*/ */
public void setVolumePath(String volumePath) { public void setVolumePath(String volumePath) {
this.volumePath = volumePath; this.volumePath = volumePath;
} }
@Override @Override
public String toString() { public String toString() {
return "id=" + this.id + " ,regionalismCode=" + this.regionalismCode return "id=" + this.id + " ,regionalismCode=" + this.regionalismCode
+ " ,cityName=" + this.cityName + " ,districtName=" + " ,cityName=" + this.cityName + " ,districtName="
+ this.districtName + " ,systemCode=" + this.systemCode + this.districtName + " ,systemCode=" + this.systemCode
+ " ,systemName" + this.systemName + " ,dataType=" + " ,systemName" + this.systemName + " ,dataType="
+ this.dataType + " ,dataVersion=" + this.dataVersion + this.dataType + " ,dataVersion=" + this.dataVersion
+ " ,submittedBatch=" + this.submittedBatch + " ,dataPath=" + " ,submittedBatch=" + this.submittedBatch + " ,dataPath="
+ this.dataPath + " ,collectingTime=" + this.collectingTime + this.dataPath + " ,collectingTime=" + this.collectingTime
+ " ,collectorContacts=" + this.collectorContacts + " ,collectorContacts=" + this.collectorContacts
+ " ,charset=" + this.charset + " ,collectorName=" + " ,charset=" + this.charset + " ,collectorName="
+ this.collectorName + " ,year=" + this.year + " startYear=" + this.collectorName + " ,year=" + this.year + " startYear="
+this.startYear +" endYear="+this.endYear; +this.startYear +" endYear="+this.endYear;
} }
} }

@ -1,124 +1,124 @@
package com.platform.entities; package com.platform.entities;
public class DataInfoEntityMoveTmp extends DataInfoEntity { public class DataInfoEntityMoveTmp extends DataInfoEntity {
private String dstPath; private String dstPath;
private String completeStatus; private String completeStatus;
private int rate; private int rate;
/** /**
* *
*/ */
private String lastTime; private String lastTime;
private String dstVolumeIp; private String dstVolumeIp;
private String dstVolumePath; private String dstVolumePath;
private int fkid; private int fkid;
public DataInfoEntityMoveTmp() { public DataInfoEntityMoveTmp() {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
/** /**
* @return the dstPath * @return the dstPath
*/ */
public String getDstPath() { public String getDstPath() {
return dstPath; return dstPath;
} }
/** /**
* @param dstPath the dstPath to set * @param dstPath the dstPath to set
*/ */
public void setDstPath(String dstPath) { public void setDstPath(String dstPath) {
this.dstPath = dstPath; this.dstPath = dstPath;
} }
/** /**
* @return the completeStatus * @return the completeStatus
*/ */
public String getCompleteStatus() { public String getCompleteStatus() {
return completeStatus; return completeStatus;
} }
/** /**
* @param completeStatus the completeStatus to set * @param completeStatus the completeStatus to set
*/ */
public void setCompleteStatus(String completeStatus) { public void setCompleteStatus(String completeStatus) {
this.completeStatus = completeStatus; this.completeStatus = completeStatus;
} }
/** /**
* @return the rate * @return the rate
*/ */
public int getRate() { public int getRate() {
return rate; return rate;
} }
/** /**
* @param rate the rate to set * @param rate the rate to set
*/ */
public void setRate(int rate) { public void setRate(int rate) {
this.rate = rate; this.rate = rate;
} }
/** /**
* @return the lastTime * @return the lastTime
*/ */
public String getLastTime() { public String getLastTime() {
return lastTime; return lastTime;
} }
/** /**
* @param lastTime the lastTime to set * @param lastTime the lastTime to set
*/ */
public void setLastTime(String lastTime) { public void setLastTime(String lastTime) {
this.lastTime = lastTime; this.lastTime = lastTime;
} }
/** /**
* @return the fkid * @return the fkid
*/ */
public int getFkid() { public int getFkid() {
return fkid; return fkid;
} }
/** /**
* @param fkid the fkid to set * @param fkid the fkid to set
*/ */
public void setFkid(int fkid) { public void setFkid(int fkid) {
this.fkid = fkid; this.fkid = fkid;
} }
/** /**
* @return the dstVolumeIp * @return the dstVolumeIp
*/ */
public String getDstVolumeIp() { public String getDstVolumeIp() {
return dstVolumeIp; return dstVolumeIp;
} }
/** /**
* @param dstVolumeIp the dstVolumeIp to set * @param dstVolumeIp the dstVolumeIp to set
*/ */
public void setDstVolumeIp(String dstVolumeIp) { public void setDstVolumeIp(String dstVolumeIp) {
this.dstVolumeIp = dstVolumeIp; this.dstVolumeIp = dstVolumeIp;
} }
/** /**
* @return the dstVolumePath * @return the dstVolumePath
*/ */
public String getDstVolumePath() { public String getDstVolumePath() {
return dstVolumePath; return dstVolumePath;
} }
/** /**
* @param dstVolumePath the dstVolumePath to set * @param dstVolumePath the dstVolumePath to set
*/ */
public void setDstVolumePath(String dstVolumePath) { public void setDstVolumePath(String dstVolumePath) {
this.dstVolumePath = dstVolumePath; this.dstVolumePath = dstVolumePath;
} }
} }

@ -1,41 +1,41 @@
package com.platform.entities; package com.platform.entities;
/** /**
* *
* *
* / * /
* @author wuming * @author wuming
* *
*/ */
public class EncodedInfoEntity { public class EncodedInfoEntity {
private String name; //名称 private String name; //名称
private String code; //编码 private String code; //编码
public EncodedInfoEntity() {} public EncodedInfoEntity() {}
public EncodedInfoEntity(String name, String code) { public EncodedInfoEntity(String name, String code) {
this.name = name; this.name = name;
this.code = code; this.code = code;
} }
public String getName() { public String getName() {
return name; return name;
} }
public void setName(String name) { public void setName(String name) {
this.name = name; this.name = name;
} }
public String getCode() { public String getCode() {
return code; return code;
} }
public void setCode(String code) { public void setCode(String code) {
this.code = code; this.code = code;
} }
@Override @Override
public String toString(){ public String toString(){
return "code=" + this.code + ", name=" + this.name; return "code=" + this.code + ", name=" + this.name;
} }
} }

@ -1,65 +1,65 @@
package com.platform.entities; package com.platform.entities;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
public class FolderNode { public class FolderNode {
private String name; private String name;
private int isFolder; // 1 is file and other integer is folder show children number private int isFolder; // 1 is file and other integer is folder show children number
private String path; private String path;
private List<FolderNode> childNodes = new ArrayList<FolderNode>(); private List<FolderNode> childNodes = new ArrayList<FolderNode>();
public FolderNode() { public FolderNode() {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
public FolderNode(String name) { public FolderNode(String name) {
this.name = name; this.name = name;
} }
public FolderNode(String name, int isFolder) { public FolderNode(String name, int isFolder) {
this.name = name; this.name = name;
this.isFolder = isFolder; this.isFolder = isFolder;
} }
public String getName() { public String getName() {
return name; return name;
} }
public void setName(String name) { public void setName(String name) {
this.name = name; this.name = name;
} }
/** /**
* @return the isFolder * @return the isFolder
*/ */
public int getIsFolder() { public int getIsFolder() {
return isFolder; return isFolder;
} }
/** /**
* @param isFolder the isFolder to set * @param isFolder the isFolder to set
*/ */
public void setIsFolder(int isFolder) { public void setIsFolder(int isFolder) {
this.isFolder = isFolder; this.isFolder = isFolder;
} }
public String getPath() { public String getPath() {
return path; return path;
} }
public void setPath(String path) { public void setPath(String path) {
this.path = path; this.path = path;
} }
public List<FolderNode> getChildNodes() { public List<FolderNode> getChildNodes() {
return childNodes; return childNodes;
} }
public void setChildNodes(List<FolderNode> childNodes) { public void setChildNodes(List<FolderNode> childNodes) {
this.childNodes = childNodes; this.childNodes = childNodes;
} }
} }

@ -1,82 +1,82 @@
package com.platform.entities; package com.platform.entities;
import com.platform.entities.OracleConnectorParams; import com.platform.entities.OracleConnectorParams;
public class GatherOracleInfo extends OracleConnectorParams { public class GatherOracleInfo extends OracleConnectorParams {
private String tableName; private String tableName;
private String suffix; private String suffix;
private int id; private int id;
private String remove; private String remove;
/** /**
* 0: 1 2使 3 * 0: 1 2使 3
*/ */
private int status; private int status;
public GatherOracleInfo() { public GatherOracleInfo() {
super(); super();
} }
public GatherOracleInfo(String port, String ip, String name, String user, public GatherOracleInfo(String port, String ip, String name, String user,
String password, String database) { String password, String database) {
super(port, ip, name, user, password, database); super(port, ip, name, user, password, database);
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
public GatherOracleInfo(String port, String ip, String name, String user, public GatherOracleInfo(String port, String ip, String name, String user,
String password, String database, int _id, String tableName, String suffix, int status) { String password, String database, int _id, String tableName, String suffix, int status) {
super(port, ip, name, user, password, database); super(port, ip, name, user, password, database);
this.tableName = tableName; this.tableName = tableName;
this.suffix = suffix; this.suffix = suffix;
this.id=_id; this.id=_id;
this.status = status; this.status = status;
} }
public String getTableName() { public String getTableName() {
return tableName; return tableName;
} }
public void setTableName(String tableName) { public void setTableName(String tableName) {
this.tableName = tableName; this.tableName = tableName;
} }
public String getSuffix() { public String getSuffix() {
return suffix; return suffix;
} }
public void setSuffix(String suffix) { public void setSuffix(String suffix) {
this.suffix = suffix; this.suffix = suffix;
} }
public int getId() { public int getId() {
return id; return id;
} }
public void setId(int id) { public void setId(int id) {
this.id = id; this.id = id;
} }
public int getStatus() { public int getStatus() {
return status; return status;
} }
public void setStatus(int status) { public void setStatus(int status) {
this.status = status; this.status = status;
} }
public String getRemove() { public String getRemove() {
return remove; return remove;
} }
public void setRemove(String remove) { public void setRemove(String remove) {
this.remove = remove; this.remove = remove;
} }
} }

@ -1,77 +1,77 @@
/** /**
* : GfsPathModel.java * : GfsPathModel.java
* : </> * : </>
* : <> * : <>
* @author chen * @author chen
* : <> * : <>
* 201698 * 201698
* <> * <>
*/ */
package com.platform.entities; package com.platform.entities;
import java.util.List; import java.util.List;
/** /**
* <> * <>
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class GfsFolderEntity { public class GfsFolderEntity {
/** 当前路径 */ /** 当前路径 */
private String path; private String path;
/** 当前路径 */ /** 当前路径 */
private String name; private String name;
/** 子目录 */ /** 子目录 */
private List<GfsFolderEntity> children; private List<GfsFolderEntity> children;
/** /**
* @return the path * @return the path
*/ */
public String getPath() { public String getPath() {
return path; return path;
} }
/** /**
* @param path the path to set * @param path the path to set
*/ */
public void setPath(String path) { public void setPath(String path) {
this.path = path; this.path = path;
} }
/** /**
* @return the name * @return the name
*/ */
public String getName() { public String getName() {
return name; return name;
} }
/** /**
* @param name the name to set * @param name the name to set
*/ */
public void setName(String name) { public void setName(String name) {
this.name = name; this.name = name;
} }
/** /**
* @return the children * @return the children
*/ */
public List<GfsFolderEntity> getChildren() { public List<GfsFolderEntity> getChildren() {
return children; return children;
} }
/** /**
* @param children the children to set * @param children the children to set
*/ */
public void setChildren(List<GfsFolderEntity> children) { public void setChildren(List<GfsFolderEntity> children) {
this.children = children; this.children = children;
} }
} }

@ -1,158 +1,158 @@
package com.platform.entities; package com.platform.entities;
import java.util.List; import java.util.List;
public class PagerOptions { public class PagerOptions {
private Integer currentPageNum; //当前页码 private Integer currentPageNum; //当前页码
private String dataType; //数据类型 private String dataType; //数据类型
private String submittedBatch; //数据批次 private String submittedBatch; //数据批次
private String cityName; //城市名称 private String cityName; //城市名称
private String districtName; //区县名 private String districtName; //区县名
private Integer dataVersion; //数据版本 private Integer dataVersion; //数据版本
private String systemName; //系统名称 private String systemName; //系统名称
private String dataYear; // 数据年度 private String dataYear; // 数据年度
private Integer limit; //一次查询返回记录条数 private Integer limit; //一次查询返回记录条数
private Integer offset; // 查询偏移量起始id private Integer offset; // 查询偏移量起始id
private Integer totalLimit; //当前页前面已有多少条数据 private Integer totalLimit; //当前页前面已有多少条数据
private Integer priorTableSize; //前一次操作一页显示的数据条数 private Integer priorTableSize; //前一次操作一页显示的数据条数
private String keyQuery; private String keyQuery;
private String[] array; private String[] array;
public Integer getCurrentPageNum() { public Integer getCurrentPageNum() {
return currentPageNum; return currentPageNum;
} }
public void setCurrentPageNum(Integer currentPageNum) { public void setCurrentPageNum(Integer currentPageNum) {
this.currentPageNum = currentPageNum; this.currentPageNum = currentPageNum;
} }
public String getDataType() { public String getDataType() {
return dataType; return dataType;
} }
public void setDataType(String dataType) { public void setDataType(String dataType) {
this.dataType = dataType; this.dataType = dataType;
} }
public String getSubmittedBatch() { public String getSubmittedBatch() {
return submittedBatch; return submittedBatch;
} }
public void setSubmittedBatch(String submittedBatch) { public void setSubmittedBatch(String submittedBatch) {
this.submittedBatch = submittedBatch; this.submittedBatch = submittedBatch;
} }
public String getCityName() { public String getCityName() {
return cityName; return cityName;
} }
public void setCityName(String cityName) { public void setCityName(String cityName) {
this.cityName = cityName; this.cityName = cityName;
} }
public String getDistrictName() { public String getDistrictName() {
return districtName; return districtName;
} }
public void setDistrictName(String districtName) { public void setDistrictName(String districtName) {
this.districtName = districtName; this.districtName = districtName;
} }
public Integer getDataVersion() { public Integer getDataVersion() {
return dataVersion; return dataVersion;
} }
public void setDataVersion(Integer dataVersion) { public void setDataVersion(Integer dataVersion) {
this.dataVersion = dataVersion; this.dataVersion = dataVersion;
} }
public String getSystemName() { public String getSystemName() {
return systemName; return systemName;
} }
public void setSystemName(String systemName) { public void setSystemName(String systemName) {
this.systemName = systemName; this.systemName = systemName;
} }
public String getDataYear() { public String getDataYear() {
return dataYear; return dataYear;
} }
public void setDataYear(String dataYear) { public void setDataYear(String dataYear) {
this.dataYear = dataYear; this.dataYear = dataYear;
} }
public Integer getLimit() { public Integer getLimit() {
return limit; return limit;
} }
public void setLimit(Integer limit) { public void setLimit(Integer limit) {
this.limit = limit; this.limit = limit;
} }
public Integer getOffset() { public Integer getOffset() {
return offset; return offset;
} }
public void setOffset(Integer offset) { public void setOffset(Integer offset) {
this.offset = offset; this.offset = offset;
} }
public Integer getTotalLimit() { public Integer getTotalLimit() {
return totalLimit; return totalLimit;
} }
public void setTotalLimit(Integer totalLimit) { public void setTotalLimit(Integer totalLimit) {
this.totalLimit = totalLimit; this.totalLimit = totalLimit;
} }
public Integer getPriorTableSize() { public Integer getPriorTableSize() {
return priorTableSize; return priorTableSize;
} }
public void setPriorTableSize(Integer priorTableSize) { public void setPriorTableSize(Integer priorTableSize) {
this.priorTableSize = priorTableSize; this.priorTableSize = priorTableSize;
} }
/** /**
* @return the keyQuery * @return the keyQuery
*/ */
public String getKeyQuery() { public String getKeyQuery() {
return keyQuery; return keyQuery;
} }
/** /**
* @param keyQuery the keyQuery to set * @param keyQuery the keyQuery to set
*/ */
public void setKeyQuery(String keyQuery) { public void setKeyQuery(String keyQuery) {
this.keyQuery = keyQuery; this.keyQuery = keyQuery;
} }
/** /**
* @return the array * @return the array
*/ */
public String[] getArray() { public String[] getArray() {
return array; return array;
} }
/** /**
* @param array the array to set * @param array the array to set
*/ */
public void setArray(String[] array) { public void setArray(String[] array) {
this.array = array; this.array = array;
} }
} }

@ -1,53 +1,53 @@
package com.platform.entities; package com.platform.entities;
public class RegionalismEntity { public class RegionalismEntity {
private String code; private String code;
private String cityName; private String cityName;
private String districtName; private String districtName;
/** /**
* @return the code * @return the code
*/ */
public String getCode() { public String getCode() {
return code; return code;
} }
/** /**
* @param code the code to set * @param code the code to set
*/ */
public void setCode(String code) { public void setCode(String code) {
this.code = code; this.code = code;
} }
/** /**
* @return the cityName * @return the cityName
*/ */
public String getCityName() { public String getCityName() {
return cityName; return cityName;
} }
/** /**
* @param cityName the cityName to set * @param cityName the cityName to set
*/ */
public void setCityName(String cityName) { public void setCityName(String cityName) {
this.cityName = cityName; this.cityName = cityName;
} }
/** /**
* @return the districtName * @return the districtName
*/ */
public String getDistrictName() { public String getDistrictName() {
return districtName; return districtName;
} }
/** /**
* @param districtName the districtName to set * @param districtName the districtName to set
*/ */
public void setDistrictName(String districtName) { public void setDistrictName(String districtName) {
this.districtName = districtName; this.districtName = districtName;
} }
} }

@ -1,44 +1,44 @@
package com.platform.entities; package com.platform.entities;
public class SimpleConfigParamsBean { public class SimpleConfigParamsBean {
private String masterUrl; private String masterUrl;
private String oracleUserName; private String oracleUserName;
private String oraclePassword; private String oraclePassword;
private String oracleDBName; private String oracleDBName;
public String getMasterUrl() { public String getMasterUrl() {
return masterUrl; return masterUrl;
} }
public void setMasterUrl(String masterUrl) { public void setMasterUrl(String masterUrl) {
this.masterUrl = masterUrl; this.masterUrl = masterUrl;
} }
public String getOracleUserName() { public String getOracleUserName() {
return oracleUserName; return oracleUserName;
} }
public void setOracleUserName(String oracleUserName) { public void setOracleUserName(String oracleUserName) {
this.oracleUserName = oracleUserName; this.oracleUserName = oracleUserName;
} }
public String getOraclePassword() { public String getOraclePassword() {
return oraclePassword; return oraclePassword;
} }
public void setOraclePassword(String oraclePassword) { public void setOraclePassword(String oraclePassword) {
this.oraclePassword = oraclePassword; this.oraclePassword = oraclePassword;
} }
public String getOracleDBName() { public String getOracleDBName() {
return oracleDBName; return oracleDBName;
} }
public void setOracleDBName(String oracleDBName) { public void setOracleDBName(String oracleDBName) {
this.oracleDBName = oracleDBName; this.oracleDBName = oracleDBName;
} }
} }

@ -1,37 +1,37 @@
package com.platform.entities; package com.platform.entities;
public class SystemEntity { public class SystemEntity {
private int code; private int code;
private String systemName; private String systemName;
/** /**
* @return the code * @return the code
*/ */
public int getCode() { public int getCode() {
return code; return code;
} }
/** /**
* @param code the code to set * @param code the code to set
*/ */
public void setCode(int code) { public void setCode(int code) {
this.code = code; this.code = code;
} }
/** /**
* @return the systemName * @return the systemName
*/ */
public String getSystemName() { public String getSystemName() {
return systemName; return systemName;
} }
/** /**
* @param systemName the systemName to set * @param systemName the systemName to set
*/ */
public void setSystemName(String systemName) { public void setSystemName(String systemName) {
this.systemName = systemName; this.systemName = systemName;
} }
} }

@ -1,162 +1,162 @@
/** /**
* : VolumeEntity.java * : VolumeEntity.java
* : </> * : </>
* : <> * : <>
* @author chen * @author chen
* : <> * : <>
* 201699 * 201699
* <> * <>
*/ */
package com.platform.entities; package com.platform.entities;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
/** /**
* <> gfs volume * <> gfs volume
* <> * <>
* @author chen * @author chen
* @version [201699] * @version [201699]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class VolumeEntity { public class VolumeEntity {
/** volume总大小 */ /** volume总大小 */
private double allSize; private double allSize;
/** volume已使用大小 */ /** volume已使用大小 */
private double usedSize; private double usedSize;
/** volume名称 */ /** volume名称 */
private String name; private String name;
/** 挂载点 */ /** 挂载点 */
private String path; private String path;
/** * exist正常返回状态Started,Stopped,Created */ /** * exist正常返回状态Started,Stopped,Created */
private String status; private String status;
private String type; private String type;
/** volume树形目录 */ /** volume树形目录 */
private List<FolderNode> folder = new ArrayList<FolderNode>(); private List<FolderNode> folder = new ArrayList<FolderNode>();
/** volume的 块 */ /** volume的 块 */
private List<Brick> brick = new ArrayList<Brick>(); private List<Brick> brick = new ArrayList<Brick>();
/** /**
* @return the allSize * @return the allSize
*/ */
public double getAllSize() { public double getAllSize() {
return allSize; return allSize;
} }
/** /**
* @param allSize the allSize to set * @param allSize the allSize to set
*/ */
public void setAllSize(double allSize) { public void setAllSize(double allSize) {
this.allSize = allSize; this.allSize = allSize;
} }
/** /**
* @return the usedSize * @return the usedSize
*/ */
public double getUsedSize() { public double getUsedSize() {
return usedSize; return usedSize;
} }
/** /**
* @param usedSize the usedSize to set * @param usedSize the usedSize to set
*/ */
public void setUsedSize(double usedSize) { public void setUsedSize(double usedSize) {
this.usedSize = usedSize; this.usedSize = usedSize;
} }
/** /**
* @return the name * @return the name
*/ */
public String getName() { public String getName() {
return name; return name;
} }
/** /**
* @param name the name to set * @param name the name to set
*/ */
public void setName(String name) { public void setName(String name) {
this.name = name; this.name = name;
} }
/** /**
* @return the path * @return the path
*/ */
public String getPath() { public String getPath() {
return path; return path;
} }
/** /**
* @param path the path to set * @param path the path to set
*/ */
public void setPath(String path) { public void setPath(String path) {
this.path = path; this.path = path;
} }
/** /**
* @return the status * @return the status
*/ */
public String getStatus() { public String getStatus() {
return status; return status;
} }
/** /**
* @param status the status to set * @param status the status to set
*/ */
public void setStatus(String status) { public void setStatus(String status) {
this.status = status; this.status = status;
} }
/** /**
* @return the type * @return the type
*/ */
public String getType() { public String getType() {
return type; return type;
} }
/** /**
* @param type the type to set * @param type the type to set
*/ */
public void setType(String type) { public void setType(String type) {
this.type = type; this.type = type;
} }
/** /**
* @return the folder * @return the folder
*/ */
public List<FolderNode> getFolder() { public List<FolderNode> getFolder() {
return folder; return folder;
} }
/** /**
* @param folder the folder to set * @param folder the folder to set
*/ */
public void setFolder(List<FolderNode> folder) { public void setFolder(List<FolderNode> folder) {
this.folder = folder; this.folder = folder;
} }
/** /**
* @return the brick * @return the brick
*/ */
public List<Brick> getBrick() { public List<Brick> getBrick() {
return brick; return brick;
} }
/** /**
* @param brick the brick to set * @param brick the brick to set
*/ */
public void setBrick(List<Brick> brick) { public void setBrick(List<Brick> brick) {
this.brick = brick; this.brick = brick;
} }
} }

@ -1,106 +1,106 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.aspectj.weaver.ast.And; import org.aspectj.weaver.ast.And;
import com.mysql.jdbc.log.Log; import com.mysql.jdbc.log.Log;
import com.platform.utils.Constant; import com.platform.utils.Constant;
public class CheckoutMD5 { public class CheckoutMD5 {
public static Logger log = Logger.getLogger(CheckoutMD5.class); public static Logger log = Logger.getLogger(CheckoutMD5.class);
String sourcePath; String sourcePath;
String destPath; String destPath;
String dataName; String dataName;
// String cmd_crateSourceMD5File="find "+sourcePath+dataName+"/app/ -type f // String cmd_crateSourceMD5File="find "+sourcePath+dataName+"/app/ -type f
// -print0 | xargs -0 md5sum | sort >"+deskPath+dataName+"_md5.txt"; // -print0 | xargs -0 md5sum | sort >"+deskPath+dataName+"_md5.txt";
String cmd_getSourceMD5File; String cmd_getSourceMD5File;
// String cmd_crateDestMD5File="find "+destPath+dataName+"/app/ -type f // String cmd_crateDestMD5File="find "+destPath+dataName+"/app/ -type f
// -print0 | xargs -0 md5sum | sort >"+deskPath+dataName+"_md5.txt"; // -print0 | xargs -0 md5sum | sort >"+deskPath+dataName+"_md5.txt";
String cmd_getDestMD5File; String cmd_getDestMD5File;
Map<String, String> source_md5 = new HashMap<String, String>(); Map<String, String> source_md5 = new HashMap<String, String>();
Map<String, String> dest_md5 = new HashMap<String, String>(); Map<String, String> dest_md5 = new HashMap<String, String>();
public CheckoutMD5() { public CheckoutMD5() {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
public CheckoutMD5(String sourcePath, String destPath, String dataName) { public CheckoutMD5(String sourcePath, String destPath, String dataName) {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
this.sourcePath = sourcePath; this.sourcePath = sourcePath;
this.destPath = destPath; this.destPath = destPath;
this.dataName = dataName; this.dataName = dataName;
cmd_getSourceMD5File = "find " + sourcePath + dataName + "/app/ -type f -print0 | xargs -0 md5sum | sort "; cmd_getSourceMD5File = "find " + sourcePath + dataName + "/app/ -type f -print0 | xargs -0 md5sum | sort ";
cmd_getDestMD5File = "find " + destPath + dataName + "/app/ -type f -print0 | xargs -0 md5sum | sort "; cmd_getDestMD5File = "find " + destPath + dataName + "/app/ -type f -print0 | xargs -0 md5sum | sort ";
} }
/** /**
* sourcePathdestPath1 * sourcePathdestPath1
* 0MD5-1-2-3 * 0MD5-1-2-3
* *
* @param sourcePath * @param sourcePath
* @param destPath * @param destPath
* @return * @return
* @see [##] * @see [##]
*/ */
public int checkoutMD5Folder(String sourcePath, String destPath) { public int checkoutMD5Folder(String sourcePath, String destPath) {
log.info("start checkout md5 "+sourcePath+" and "+ destPath); log.info("start checkout md5 "+sourcePath+" and "+ destPath);
List<String> wrong_files = new ArrayList<String>(); List<String> wrong_files = new ArrayList<String>();
String source_cmd = "find " + sourcePath + " -type f -print0 | xargs -0 md5sum"; String source_cmd = "find " + sourcePath + " -type f -print0 | xargs -0 md5sum";
String dest_cmd = "find " + destPath + " -type f -print0 | xargs -0 md5sum"; String dest_cmd = "find " + destPath + " -type f -print0 | xargs -0 md5sum";
List<String> sourceReStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(source_cmd); List<String> sourceReStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(source_cmd);
if (sourceReStrings == null || sourceReStrings.size() == 0) { if (sourceReStrings == null || sourceReStrings.size() == 0) {
log.error("get " + sourcePath + " MD5 error!"); log.error("get " + sourcePath + " MD5 error!");
return -1; return -1;
} }
if(sourceReStrings.get(0).contains(Constant.noSuchFile)){ if(sourceReStrings.get(0).contains(Constant.noSuchFile)){
log.error(sourcePath+" is not exist!"); log.error(sourcePath+" is not exist!");
return -2; return -2;
} }
List<String> destReStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(dest_cmd); List<String> destReStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(dest_cmd);
if (destReStrings == null || destReStrings.size() == 0) { if (destReStrings == null || destReStrings.size() == 0) {
log.error("get " + destReStrings + " MD5 error!"); log.error("get " + destReStrings + " MD5 error!");
return -1; return -1;
} }
if(destReStrings.get(0).contains(Constant.noSuchFile)){ if(destReStrings.get(0).contains(Constant.noSuchFile)){
log.error(destPath+" is not exist!"); log.error(destPath+" is not exist!");
return -3; return -3;
} }
Map<String, String> source_md5 = new HashMap<String, String>(); Map<String, String> source_md5 = new HashMap<String, String>();
Map<String, String> dest_md5 = new HashMap<String, String>(); Map<String, String> dest_md5 = new HashMap<String, String>();
for (String line : sourceReStrings) { for (String line : sourceReStrings) {
String[] lines = line.split(" "); String[] lines = line.split(" ");
String key = lines[1].replace(sourcePath, "").trim(); String key = lines[1].replace(sourcePath, "").trim();
String value = lines[0].trim(); String value = lines[0].trim();
source_md5.put(key, value); source_md5.put(key, value);
} }
for (String line : destReStrings) { for (String line : destReStrings) {
String[] lines = line.split(" "); String[] lines = line.split(" ");
String key = lines[1].replace(destPath, "").trim(); String key = lines[1].replace(destPath, "").trim();
String value = lines[0].trim(); String value = lines[0].trim();
dest_md5.put(key, value); dest_md5.put(key, value);
} }
for (Map.Entry<String, String> mapEntry : source_md5.entrySet()) { for (Map.Entry<String, String> mapEntry : source_md5.entrySet()) {
if (!(dest_md5.containsKey(mapEntry.getKey()) if (!(dest_md5.containsKey(mapEntry.getKey())
&& dest_md5.get(mapEntry.getKey()).equals(mapEntry.getValue()))) { && dest_md5.get(mapEntry.getKey()).equals(mapEntry.getValue()))) {
log.info(sourcePath + " and " + destPath + " is not same!"); log.info(sourcePath + " and " + destPath + " is not same!");
return 0; return 0;
// System.out.println(mapEntry.getKey()); // System.out.println(mapEntry.getKey());
} }
} }
log.info(sourcePath + " and " + destPath + " is same!"); log.info(sourcePath + " and " + destPath + " is same!");
return 1; return 1;
} }
public static void main(String[] args) { public static void main(String[] args) {
CheckoutMD5 checkoutMD5 = new CheckoutMD5(); CheckoutMD5 checkoutMD5 = new CheckoutMD5();
System.out.println(checkoutMD5.checkoutMD5Folder("/home/v1_copy","/home/ubuntu")); System.out.println(checkoutMD5.checkoutMD5Folder("/home/v1_copy","/home/ubuntu"));
} }
} }

@ -1,124 +1,124 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.io.File; import java.io.File;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator; import org.apache.log4j.PropertyConfigurator;
import com.platform.utils.Constant; import com.platform.utils.Constant;
/** /**
* *
* @author liliy * @author liliy
* @version [2016912] * @version [2016912]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class ClusterInfo { public class ClusterInfo {
public static Logger log = Logger.getLogger(ClusterInfo.class); public static Logger log = Logger.getLogger(ClusterInfo.class);
/** /**
* *
* nullmapipip * nullmapipip
* ipPeerinCluster(Connected) * ipPeerinCluster(Connected)
* ipPeerinCluster(Disconnected) * ipPeerinCluster(Disconnected)
* @return * @return
* @see [##] * @see [##]
*/ */
public Map<String, String> showClusterInfo() { public Map<String, String> showClusterInfo() {
log.info("get cluster info"); log.info("get cluster info");
Map<String, String> peerIps = new HashMap<String, String>(); Map<String, String> peerIps = new HashMap<String, String>();
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(Constant.glusterPeerStatus); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(Constant.glusterPeerStatus);
if (reStrings == null) { if (reStrings == null) {
log.error("1101 command get result is null"); log.error("1101 command get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1102 command get result is nothing"); log.error("1102 command get result is nothing");
return null; return null;
} }
if (!(reStrings.get(0).split(":")[0].contains("Number of Peers"))) { if (!(reStrings.get(0).split(":")[0].contains("Number of Peers"))) {
log.error("1103 get result string wrong"); log.error("1103 get result string wrong");
return null; return null;
} }
// System.out.print(reStrings.get(0)); // System.out.print(reStrings.get(0));
int flag = 0; int flag = 0;
String ipString = ""; String ipString = "";
String state = ""; String state = "";
for (Iterator it2 = reStrings.iterator(); it2.hasNext();) { for (Iterator it2 = reStrings.iterator(); it2.hasNext();) {
String line = (String) it2.next(); String line = (String) it2.next();
line=line.replaceAll(" +", " "); line=line.replaceAll(" +", " ");
String keyValue[] = line.split(":"); String keyValue[] = line.split(":");
if (keyValue[0].equals("Hostname")) { if (keyValue[0].equals("Hostname")) {
if (keyValue.length < 2) { if (keyValue.length < 2) {
log.error("1105 command get result is wrong"); log.error("1105 command get result is wrong");
continue; continue;
} }
ipString = keyValue[1].replaceAll(" ", ""); ipString = keyValue[1].replaceAll(" ", "");
flag = 1; flag = 1;
} else if (flag == 1 && keyValue[0].equals("State")) { } else if (flag == 1 && keyValue[0].equals("State")) {
if (keyValue.length < 2) { if (keyValue.length < 2) {
log.error("1106 command get result is wrong"); log.error("1106 command get result is wrong");
continue; continue;
} }
state = keyValue[1].replaceAll(" ", ""); state = keyValue[1].replaceAll(" ", "");
flag = 0; flag = 0;
peerIps.put(ipString, state); peerIps.put(ipString, state);
} }
} }
return peerIps; return peerIps;
} }
/** /**
* ipip * ipip
* ipnull * ipnull
* ipPeerinCluster(Connected) * ipPeerinCluster(Connected)
* ipPeerinCluster(Disconnected) * ipPeerinCluster(Disconnected)
* @param peerip * @param peerip
* @return * @return
* @see [##] * @see [##]
*/ */
public String getPeerStatus(String peerip){ public String getPeerStatus(String peerip){
Map<String, String> peerIps=showClusterInfo(); Map<String, String> peerIps=showClusterInfo();
if(peerIps==null || peerIps.size()==0){ if(peerIps==null || peerIps.size()==0){
return null; return null;
} }
if(peerip.equals(Constant.hostIp)){ if(peerip.equals(Constant.hostIp)){
return Constant.peerincluster_connected; return Constant.peerincluster_connected;
} }
if(!peerIps.containsKey(peerip)){ if(!peerIps.containsKey(peerip)){
return Constant.peerNotinCluster; return Constant.peerNotinCluster;
} }
return peerIps.get(peerip); return peerIps.get(peerip);
} }
public static void main(String[] args) { public static void main(String[] args) {
// PropertyConfigurator.configure("log4j.properties"); // PropertyConfigurator.configure("log4j.properties");
System.out.println(new ClusterInfo().showClusterInfo()); System.out.println(new ClusterInfo().showClusterInfo());
System.out.println(new ClusterInfo().getPeerStatus("192.168.0.116")); System.out.println(new ClusterInfo().getPeerStatus("192.168.0.116"));
} }
} }

@ -1,125 +1,125 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.junit.Test; import org.junit.Test;
import com.platform.entities.FolderNode; import com.platform.entities.FolderNode;
import com.platform.utils.Constant; import com.platform.utils.Constant;
import com.platform.utils.FileOperateHelper; import com.platform.utils.FileOperateHelper;
import com.platform.utils.GanymedSSH; import com.platform.utils.GanymedSSH;
/** /**
* <> GFS * <> GFS
* <> * <>
* @author chen * @author chen
* @version [201698] * @version [201698]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class GetTreeData { public class GetTreeData {
ShowData showData = new ShowData(); ShowData showData = new ShowData();
/** /**
* <> * <>
* <> * <>
* @param name * @param name
* @return * @return
* @see [##] * @see [##]
*/ */
public FolderNode getDatas(String name) { public FolderNode getDatas(String name) {
String names[]=name.split("/"); String names[]=name.split("/");
String only_name=names[names.length-1]; String only_name=names[names.length-1];
FolderNode fileNode = new FolderNode(only_name); FolderNode fileNode = new FolderNode(only_name);
fileNode.setPath(name); fileNode.setPath(name);
Map<String, String> files = showData.showFolderData(name); Map<String, String> files = showData.showFolderData(name);
if(files==null || files.size()==0){ if(files==null || files.size()==0){
return fileNode; return fileNode;
} }
fileNode.setIsFolder(files.size()); fileNode.setIsFolder(files.size());
List<FolderNode> list = new ArrayList<FolderNode>(); List<FolderNode> list = new ArrayList<FolderNode>();
fileNode.setChildNodes(list); fileNode.setChildNodes(list);
for (Map.Entry<String, String> entry : files.entrySet()) { for (Map.Entry<String, String> entry : files.entrySet()) {
if(entry.getKey().equals("app")){ if(entry.getKey().equals("app")){
continue; continue;
} }
int number = Integer.parseInt(entry.getValue()); int number = Integer.parseInt(entry.getValue());
if (number == 1) { if (number == 1) {
fileNode.getChildNodes().add(new FolderNode(entry.getKey(), number)); fileNode.getChildNodes().add(new FolderNode(entry.getKey(), number));
} }
if (number > 1) { if (number > 1) {
FolderNode temp=getDatas(name+"/"+entry.getKey()); FolderNode temp=getDatas(name+"/"+entry.getKey());
fileNode.getChildNodes().add(temp); fileNode.getChildNodes().add(temp);
} }
} }
return fileNode; return fileNode;
} }
/** /**
* <> * <>
* <> * <>
* @param name * @param name
* @return * @return
* @see [##] * @see [##]
*/ */
public FolderNode getDatasWithShell(String name) { public FolderNode getDatasWithShell(String name) {
if(name.endsWith("/")){ if(name.endsWith("/")){
name=name.substring(0, name.length()-1); name=name.substring(0, name.length()-1);
} }
// String names[]=name.split("/"); // String names[]=name.split("/");
// String only_name=names[names.length-1]; // String only_name=names[names.length-1];
FolderNode fileNode = new FolderNode(name); FolderNode fileNode = new FolderNode(name);
fileNode.setPath(name); fileNode.setPath(name);
// String shellComment= new FileOperateHelper().fileReaderAndendline(Constant.fileGetTreeData); // String shellComment= new FileOperateHelper().fileReaderAndendline(Constant.fileGetTreeData);
String shellComment= Constant.strGetTreeData; String shellComment= Constant.strGetTreeData;
String sh_path="/getTreedata.sh"; String sh_path="/getTreedata.sh";
String cmd="echo -e \""+shellComment+"\" > "+sh_path+" & chmod +x "+sh_path; String cmd="echo -e \""+shellComment+"\" > "+sh_path+" & chmod +x "+sh_path;
Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// Map<String, String> files = showData.showFolderData(name); // Map<String, String> files = showData.showFolderData(name);
List<String> files=Constant.ganymedSSH.execCmdWaitAcquiescent(sh_path+" "+name); List<String> files=Constant.ganymedSSH.execCmdWaitAcquiescent(sh_path+" "+name);
if(files==null){ if(files==null){
return null; return null;
} }
if(files.size()==0){ if(files.size()==0){
return fileNode; return fileNode;
} }
for(String file:files){ for(String file:files){
} }
return fileNode; return fileNode;
} }
@Test @Test
public void test_getTreeData() { public void test_getTreeData() {
GetTreeData getTreeData=new GetTreeData(); GetTreeData getTreeData=new GetTreeData();
// FolderNode fileOrFolder=getTreeData.getDatas("/home/gfs_ftp_point"); // FolderNode fileOrFolder=getTreeData.getDatas("/home/gfs_ftp_point");
FolderNode fileOrFolder=getTreeData.getDatasWithShell("/home/gfs_ftp_point/"); FolderNode fileOrFolder=getTreeData.getDatasWithShell("/home/gfs_ftp_point/");
System.out.println(fileOrFolder); System.out.println(fileOrFolder);
} }
} }
/* /*
class FileOrFolder { class FileOrFolder {
String name; String name;
int isFolder; // 1 is file and other integer is folder show children number int isFolder; // 1 is file and other integer is folder show children number
List<FileOrFolder> children; List<FileOrFolder> children;
public FileOrFolder(String name) { public FileOrFolder(String name) {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
this.name = name; this.name = name;
} }
public FileOrFolder(String name, int isFolder) { public FileOrFolder(String name, int isFolder) {
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
this.name = name; this.name = name;
this.isFolder = isFolder; this.isFolder = isFolder;
} }
} }
*/ */

@ -1,56 +1,56 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator; import org.apache.log4j.PropertyConfigurator;
import org.junit.Test; import org.junit.Test;
import com.platform.utils.Constant; import com.platform.utils.Constant;
public class RemoveData { public class RemoveData {
public static Logger log = Logger.getLogger ( RemoveData.class); public static Logger log = Logger.getLogger ( RemoveData.class);
/** /**
* -1 :error; 0: the filename is not exists ; 1: right * -1 :error; 0: the filename is not exists ; 1: right
* @param folderName * @param folderName
* @param fileName * @param fileName
* @return * @return
*/ */
public int deleteFolder(String folderName){ public int deleteFolder(String folderName){
log.info("start delete "+folderName); log.info("start delete "+folderName);
ShowData showData=new ShowData(); ShowData showData=new ShowData();
Map<String,String> reStrings=showData.showFolderData(folderName); Map<String,String> reStrings=showData.showFolderData(folderName);
if(reStrings==null){ if(reStrings==null){
log.error("3301 "+folderName+" is not exists"); log.error("3301 "+folderName+" is not exists");
return -1; return -1;
} }
String command="rm -r "+folderName; String command="rm -r "+folderName;
// int status=runCommand.runCommand(command); // int status=runCommand.runCommand(command);
Constant.ganymedSSH.execCmdNoWaitAcquiescent(command); Constant.ganymedSSH.execCmdNoWaitAcquiescent(command);
log.info("delete "+folderName+" running"); log.info("delete "+folderName+" running");
return 1; return 1;
} }
@Test @Test
public void testDeleteFolderFiles() { public void testDeleteFolderFiles() {
PropertyConfigurator.configure("log4j.properties"); PropertyConfigurator.configure("log4j.properties");
deleteFolder("/home/ubuntu"); deleteFolder("/home/ubuntu");
} }
} }

@ -1,67 +1,67 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.util.List; import java.util.List;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.hamcrest.core.Is; import org.hamcrest.core.Is;
import com.platform.utils.Constant; import com.platform.utils.Constant;
import com.platform.utils.Support; import com.platform.utils.Support;
public class SetCluster { public class SetCluster {
public static Logger log = Logger.getLogger ( SetCluster.class); public static Logger log = Logger.getLogger ( SetCluster.class);
/** /**
* *
* 1-1ip-2 0 * 1-1ip-2 0
* @param peerip * @param peerip
* @return * @return
* @see [##] * @see [##]
*/ */
public int probePeer(String peerip){ public int probePeer(String peerip){
if(!Support.checkIP(peerip)){ if(!Support.checkIP(peerip)){
log.error(peerip +"is illegal!" ); log.error(peerip +"is illegal!" );
return -1; return -1;
} }
String cmd="gluster peer probe "+peerip; String cmd="gluster peer probe "+peerip;
List<String> reStrings=Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings=Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
if(reStrings==null || reStrings.size()==0){ if(reStrings==null || reStrings.size()==0){
log.error("detach error! "); log.error("detach error! ");
return -2; return -2;
} }
if(reStrings.contains(Constant.success)){ if(reStrings.contains(Constant.success)){
log.info("probe success!"); log.info("probe success!");
return 1; return 1;
} }
log.info("probe failed!"); log.info("probe failed!");
return 0; return 0;
} }
/** /**
* *
* 1-1ip-2 0 * 1-1ip-2 0
* @param peerip * @param peerip
* @return * @return
* @see [##] * @see [##]
*/ */
public int detachPeer(String peerip){ public int detachPeer(String peerip){
if(!Support.checkIP(peerip)){ if(!Support.checkIP(peerip)){
log.error(peerip +"is illegal!" ); log.error(peerip +"is illegal!" );
return -1; return -1;
} }
String cmd="gluster peer detach "+peerip; String cmd="gluster peer detach "+peerip;
List<String> reStrings=Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings=Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
if(reStrings==null || reStrings.size()==0){ if(reStrings==null || reStrings.size()==0){
log.error("detach error! "); log.error("detach error! ");
return -2; return -2;
} }
if(reStrings.contains(Constant.success)){ if(reStrings.contains(Constant.success)){
log.info("detach success!"); log.info("detach success!");
return 1; return 1;
} }
log.info("detach failed!"); log.info("detach failed!");
return 0; return 0;
} }
} }

File diff suppressed because it is too large Load Diff

@ -1,132 +1,132 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator; import org.apache.log4j.PropertyConfigurator;
import org.junit.Test; import org.junit.Test;
import com.platform.utils.Constant; import com.platform.utils.Constant;
public class ShowData { public class ShowData {
public static Logger log = Logger.getLogger ( ShowData.class); public static Logger log = Logger.getLogger ( ShowData.class);
/** /**
* get the data of volumeName Map<string s1,string s2> s1 is data name and s2 is type file or folder * get the data of volumeName Map<string s1,string s2> s1 is data name and s2 is type file or folder
* <> * <>
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public Map<String,String> showVolumeFiles(String volumeName){ public Map<String,String> showVolumeFiles(String volumeName){
log.info("start show the data"); log.info("start show the data");
Map<String,String> data_type=new HashMap<String, String>(); Map<String,String> data_type=new HashMap<String, String>();
/** /**
* get mount point of volumeName * get mount point of volumeName
*/ */
String folderName=volumeName; String folderName=volumeName;
data_type=showFolderData(volumeName); data_type=showFolderData(volumeName);
return data_type; return data_type;
} }
/** /**
* get the data of folder name * get the data of folder name
* Map<String,String> is folder name and type 1 is file and others is folder * Map<String,String> is folder name and type 1 is file and others is folder
* @param FolderName * @param FolderName
* @return * @return
*/ */
public Map<String,String> showFolderData(String folderName){ public Map<String,String> showFolderData(String folderName){
log.info(" start get "+folderName+" data"); log.info(" start get "+folderName+" data");
Map<String,String> data_type=new HashMap<String, String>(); Map<String,String> data_type=new HashMap<String, String>();
String command="ls -l "+folderName; String command="ls -l "+folderName;
/* /*
<<<<<<< HEAD <<<<<<< HEAD
* RunCommand runCommand=new RunCommand(); List<String> * RunCommand runCommand=new RunCommand(); List<String>
* reStrings=runCommand.runCommandWait(command); * reStrings=runCommand.runCommandWait(command);
*/ */
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(command); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(command);
if (reStrings == null) { if (reStrings == null) {
log.error("2101 command get result is null"); log.error("2101 command get result is null");
return null; return null;
} }
if(reStrings.size()==0){ if(reStrings.size()==0){
log.info("2102 the folder is empty"); log.info("2102 the folder is empty");
return data_type; return data_type;
} }
if(reStrings.get(0).contains("No such file or directory")){ if(reStrings.get(0).contains("No such file or directory")){
log.info("2103 the "+folderName+" is not exists"); log.info("2103 the "+folderName+" is not exists");
return null; return null;
} }
/** /**
* remove first line total number * remove first line total number
*/ */
reStrings.remove(0); reStrings.remove(0);
for(Iterator it2 = reStrings.iterator();it2.hasNext();){ for(Iterator it2 = reStrings.iterator();it2.hasNext();){
String line=(String)it2.next(); String line=(String)it2.next();
line=line.replaceAll(" +", " "); line=line.replaceAll(" +", " ");
String keyValue[]=line.split(" "); String keyValue[]=line.split(" ");
if(keyValue.length<9){ if(keyValue.length<9){
log.error("2104 "+line+" length is short"); log.error("2104 "+line+" length is short");
continue; continue;
} }
data_type.put(keyValue[8], keyValue[1]); data_type.put(keyValue[8], keyValue[1]);
} }
log.info(" get "+folderName+" data successed"); log.info(" get "+folderName+" data successed");
return data_type; return data_type;
} }
/** /**
* folder * folder
* -2-1folderfolder * -2-1folderfolder
* @param folderPath * @param folderPath
* @return * @return
* @see [##] * @see [##]
*/ */
public long getFolderSize(String folderPath) { public long getFolderSize(String folderPath) {
log.info("get " + folderPath + " Size "); log.info("get " + folderPath + " Size ");
String command = "du -k -d 0 "+folderPath+" | grep " + folderPath + "|awk \'{print $1}\'"; String command = "du -k -d 0 "+folderPath+" | grep " + folderPath + "|awk \'{print $1}\'";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(command); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(command);
if(reStrings==null || reStrings.size()==0){ if(reStrings==null || reStrings.size()==0){
log.error("get " + folderPath + " Size error!"); log.error("get " + folderPath + " Size error!");
return -2; return -2;
} }
if (reStrings.get(0).contains(Constant.noSuchFile)) { if (reStrings.get(0).contains(Constant.noSuchFile)) {
log.error(folderPath+" is not exists"); log.error(folderPath+" is not exists");
return -1; return -1;
} }
long size = Long.valueOf(reStrings.get(0)); long size = Long.valueOf(reStrings.get(0));
return size; return size;
} }
/** /**
* *
* <> * <>
* <> * <>
* @see [##] * @see [##]
*/ */
@Test @Test
public void testShowData(){ public void testShowData(){
System.out.println(showFolderData("/home")); System.out.println(showFolderData("/home"));
} }
} }

@ -1,93 +1,93 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.io.File; import java.io.File;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator; import org.apache.log4j.PropertyConfigurator;
import com.platform.utils.Constant; import com.platform.utils.Constant;
public class SizeInfo { public class SizeInfo {
public static Logger log = Logger.getLogger(ClusterInfo.class); public static Logger log = Logger.getLogger(ClusterInfo.class);
VolumeInfo volumeInfo = new VolumeInfo(); VolumeInfo volumeInfo = new VolumeInfo();
/** /**
* <EFBFBD>?<EFBFBD><EFBFBD>volume size * <EFBFBD>?<EFBFBD><EFBFBD>volume size
* -1<EFBFBD>? 0volume longsize * -1<EFBFBD>? 0volume longsize
* @return * @return
*/ */
public long showAllSize() { public long showAllSize() {
log.info("get AllSize "); log.info("get AllSize ");
List<String> volumeNames = volumeInfo.showAllVolumeName(); List<String> volumeNames = volumeInfo.showAllVolumeName();
if (volumeNames == null) { if (volumeNames == null) {
log.error("1201 showAllVolumeName error"); log.error("1201 showAllVolumeName error");
return -1; return -1;
} }
if (volumeNames.size() == 0) { if (volumeNames.size() == 0) {
log.error("1202 It is not exist any volume"); log.error("1202 It is not exist any volume");
return 0; return 0;
} }
List<String> reStrings = null; List<String> reStrings = null;
long size = 0L; long size = 0L;
for (String str : volumeNames) { for (String str : volumeNames) {
String command = "df |grep " + str + "|awk \'{print $2}\'"; String command = "df |grep " + str + "|awk \'{print $2}\'";
reStrings = Constant.ganymedSSH.execCmdWait(Constant.hostIp, Constant.rootUser, Constant.rootPasswd, Constant.port, reStrings = Constant.ganymedSSH.execCmdWait(Constant.hostIp, Constant.rootUser, Constant.rootPasswd, Constant.port,
command); command);
if (reStrings.isEmpty()) { if (reStrings.isEmpty()) {
log.error("1203 The brick is unmount"); log.error("1203 The brick is unmount");
} else { } else {
size += Long.parseLong(reStrings.get(0)); size += Long.parseLong(reStrings.get(0));
} }
} }
return size; return size;
} }
/** /**
* *
* @return * @return
* -1<EFBFBD>? 0volume longsize * -1<EFBFBD>? 0volume longsize
*/ */
public long showUseSize() { public long showUseSize() {
log.info("get UseSize "); log.info("get UseSize ");
List<String> volumeNames = volumeInfo.showAllVolumeName(); List<String> volumeNames = volumeInfo.showAllVolumeName();
List<String> reStrings = null; List<String> reStrings = null;
long size = 0L; long size = 0L;
if (volumeNames == null) { if (volumeNames == null) {
log.error("1201 showAllVolumeName error"); log.error("1201 showAllVolumeName error");
return -1; return -1;
} }
if (volumeNames.size() == 0) { if (volumeNames.size() == 0) {
log.error("1202 It is not exist any volume"); log.error("1202 It is not exist any volume");
return 0; return 0;
} }
for (String str : volumeNames) { for (String str : volumeNames) {
String command = "df |grep " + str + "|awk \'{print $3}\'"; String command = "df |grep " + str + "|awk \'{print $3}\'";
reStrings = Constant.ganymedSSH.execCmdWait(Constant.hostIp, Constant.rootUser, Constant.rootPasswd, reStrings = Constant.ganymedSSH.execCmdWait(Constant.hostIp, Constant.rootUser, Constant.rootPasswd,
Constant.port, command); Constant.port, command);
if (reStrings.isEmpty()) { if (reStrings.isEmpty()) {
log.error("1202 The brick is unmount"); log.error("1202 The brick is unmount");
} else { } else {
size += Integer.valueOf(reStrings.get(0)); size += Integer.valueOf(reStrings.get(0));
} }
} }
return size; return size;
} }
public static void main(String[] args) { public static void main(String[] args) {
PropertyConfigurator.configure("log4j.properties"); PropertyConfigurator.configure("log4j.properties");
System.out.println(new SizeInfo().showAllSize()); System.out.println(new SizeInfo().showAllSize());
System.out.println(new SizeInfo().showUseSize()); System.out.println(new SizeInfo().showUseSize());
} }
} }

@ -1,406 +1,406 @@
package com.platform.glusterfs; package com.platform.glusterfs;
import java.io.File; import java.io.File;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.Iterator; import java.util.Iterator;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.log4j.Logger; import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator; import org.apache.log4j.PropertyConfigurator;
import org.junit.Test; import org.junit.Test;
import org.omg.CosNaming.NamingContextExtPackage.StringNameHelper; import org.omg.CosNaming.NamingContextExtPackage.StringNameHelper;
import com.platform.utils.Constant; import com.platform.utils.Constant;
import com.platform.utils.GanymedSSH; import com.platform.utils.GanymedSSH;
import java.util.regex.Matcher; import java.util.regex.Matcher;
import java.util.regex.Pattern; import java.util.regex.Pattern;
/** /**
* volume <> * volume <>
* *
* @author liliy * @author liliy
* @version [2016913] * @version [2016913]
* @see [/] * @see [/]
* @since [/] * @since [/]
*/ */
public class VolumeInfo { public class VolumeInfo {
public static Logger log = Logger.getLogger(VolumeInfo.class); public static Logger log = Logger.getLogger(VolumeInfo.class);
/** /**
* volume <> * volume <>
* *
* @return * @return
* @see [##] * @see [##]
*/ */
public List<String> showAllVolumeName() { public List<String> showAllVolumeName() {
log.info("get volume name"); log.info("get volume name");
List<String> volNames = new ArrayList<String>(); List<String> volNames = new ArrayList<String>();
/* /*
* String command = "echo \"" + Constant.rootPasswd + * String command = "echo \"" + Constant.rootPasswd +
* "\" |sudo -S gluster volume info|grep ^Volume.Name"; RunCommand * "\" |sudo -S gluster volume info|grep ^Volume.Name"; RunCommand
* runCommand = new RunCommand(); List<String> reStrings = * runCommand = new RunCommand(); List<String> reStrings =
* runCommand.runCommandWait(command); * runCommand.runCommandWait(command);
*/ */
List<String> reStrings = Constant.ganymedSSH List<String> reStrings = Constant.ganymedSSH
.execCmdWaitAcquiescent(Constant.glusterVolumeInfo + "|grep ^Volume.Name"); .execCmdWaitAcquiescent(Constant.glusterVolumeInfo + "|grep ^Volume.Name");
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1401 get result is null"); log.error("1401 get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1402 get result is nothing"); log.error("1402 get result is nothing");
return null; return null;
} }
if (reStrings.get(0).contains(Constant.noVolume)) { if (reStrings.get(0).contains(Constant.noVolume)) {
reStrings.clear(); reStrings.clear();
return reStrings; return reStrings;
} }
if (!(reStrings.get(0).split(":")[0].contains("Volume Name"))) { if (!(reStrings.get(0).split(":")[0].contains("Volume Name"))) {
log.error("1403 get result string wrong"); log.error("1403 get result string wrong");
return null; return null;
} }
String nameInfo = ""; String nameInfo = "";
for (Iterator it = reStrings.iterator(); it.hasNext();) { for (Iterator it = reStrings.iterator(); it.hasNext();) {
String line = (String) it.next(); String line = (String) it.next();
String str[] = line.split(":"); String str[] = line.split(":");
volNames.add(str[1].replaceAll(" ", "")); volNames.add(str[1].replaceAll(" ", ""));
} }
return volNames; return volNames;
} }
/** /**
* volumevolume * volumevolume
* *
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public String getVolumeType(String volumeName) { public String getVolumeType(String volumeName) {
log.info("get volume type"); log.info("get volume type");
String volType = ""; String volType = "";
List<String> reStrings = Constant.ganymedSSH List<String> reStrings = Constant.ganymedSSH
.execCmdWaitAcquiescent(Constant.glusterVolumeInfo + volumeName + "|grep ^Type"); .execCmdWaitAcquiescent(Constant.glusterVolumeInfo + volumeName + "|grep ^Type");
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1501 get result is null"); log.error("1501 get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1502 get result is nothing"); log.error("1502 get result is nothing");
return null; return null;
} }
if (!(reStrings.get(0).split(":")[0].contains("Type"))) { if (!(reStrings.get(0).split(":")[0].contains("Type"))) {
log.error("1503 get result string wrong"); log.error("1503 get result string wrong");
return null; return null;
} }
// System.out.println(reStrings); // System.out.println(reStrings);
for (Iterator it = reStrings.iterator(); it.hasNext();) { for (Iterator it = reStrings.iterator(); it.hasNext();) {
String line = (String) it.next(); String line = (String) it.next();
String str[] = line.split(":"); String str[] = line.split(":");
volType = str[1]; volType = str[1];
} }
volType = volType.replaceAll(" ", ""); volType = volType.replaceAll(" ", "");
return volType; return volType;
} }
/** /**
* volumeName nullvolumeNameVolume volumeName does not * volumeName nullvolumeNameVolume volumeName does not
* existStarted,Stopped,Created * existStarted,Stopped,Created
* *
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public String getVolumeStatus(String volumeName) { public String getVolumeStatus(String volumeName) {
log.info("get volume status"); log.info("get volume status");
String volStatus = ""; String volStatus = "";
String cmd = Constant.glusterVolumeInfo + " " + volumeName + " |grep ^Status"; String cmd = Constant.glusterVolumeInfo + " " + volumeName + " |grep ^Status";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1701 get result is null"); log.error("1701 get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1702 get result is nothing"); log.error("1702 get result is nothing");
return null; return null;
} }
if (reStrings.get(0).contains("does not exist")) { if (reStrings.get(0).contains("does not exist")) {
log.error("1703 " + reStrings.get(0)); log.error("1703 " + reStrings.get(0));
return reStrings.get(0); return reStrings.get(0);
} }
if (!(reStrings.get(0).split(":")[0].contains("Status"))) { if (!(reStrings.get(0).split(":")[0].contains("Status"))) {
log.error("1704 get result string wrong"); log.error("1704 get result string wrong");
return null; return null;
} }
for (Iterator it = reStrings.iterator(); it.hasNext();) { for (Iterator it = reStrings.iterator(); it.hasNext();) {
String line = (String) it.next(); String line = (String) it.next();
String str[] = line.split(":"); String str[] = line.split(":");
volStatus = str[1].replaceAll(" ", ""); volStatus = str[1].replaceAll(" ", "");
} }
return volStatus; return volStatus;
} }
/** /**
* volumeName * volumeName
* volumeName-1-2 volumeName * volumeName-1-2 volumeName
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public Long getVolumeAvailableSize(String volumeName) throws Exception{ public Long getVolumeAvailableSize(String volumeName) throws Exception{
log.info("get volume availableSize"); log.info("get volume availableSize");
Long allSize = 0L; Long allSize = 0L;
String cmd = Constant.df + " | grep " + volumeName + "|awk '{print $4}'"; String cmd = Constant.df + " | grep " + volumeName + "|awk '{print $4}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1802 get result is error"); log.error("1802 get result is error");
return -2L; return -2L;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1801 " + volumeName + " is not exists!"); log.error("1801 " + volumeName + " is not exists!");
return -1L; return -1L;
} }
allSize = Long.parseLong(reStrings.get(0)); allSize = Long.parseLong(reStrings.get(0));
return allSize; return allSize;
} }
/** /**
* volumeName * volumeName
* volumeName-1-2 volumeName * volumeName-1-2 volumeName
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public Long getVolumeUseSize(String volumeName) throws Exception{ public Long getVolumeUseSize(String volumeName) throws Exception{
log.info("get volume used size"); log.info("get volume used size");
Long usedSize = 0L; Long usedSize = 0L;
if (volumeIsExists(volumeName) == false) { if (volumeIsExists(volumeName) == false) {
log.error("1901 " + volumeName + " is not exists!"); log.error("1901 " + volumeName + " is not exists!");
return -1L; return -1L;
} }
String cmd = "df | grep " + volumeName + "|awk '{print $3}'"; String cmd = "df | grep " + volumeName + "|awk '{print $3}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1901 get result is null"); log.error("1901 get result is null");
return -2L; return -2L;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1902 " + volumeName + " is not exists!"); log.error("1902 " + volumeName + " is not exists!");
return -1L; return -1L;
} }
usedSize = Long.parseLong(reStrings.get(0)); usedSize = Long.parseLong(reStrings.get(0));
return usedSize; return usedSize;
} }
/** /**
* volumeNamebricks * volumeNamebricks
* birckslist ip:path,volumeNamenull * birckslist ip:path,volumeNamenull
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public List<String> getVolumeBricks(String volumeName) { public List<String> getVolumeBricks(String volumeName) {
log.info("get volume bricks"); log.info("get volume bricks");
String cmd = "gluster volume info " + volumeName + " |grep ^Brick'[0-9]\\+' |awk '{print $2}'"; String cmd = "gluster volume info " + volumeName + " |grep ^Brick'[0-9]\\+' |awk '{print $2}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1601 get volume bricks wrong"); log.error("1601 get volume bricks wrong");
return null; return null;
} }
if (reStrings.size()==0) { if (reStrings.size()==0) {
log.error("1602 "+volumeName+" is not exists!"); log.error("1602 "+volumeName+" is not exists!");
return null; return null;
} }
return reStrings; return reStrings;
} }
/** /**
* volumeName * volumeName
* <> * <>
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public List<String> getVolumeMountPoint(String volumeName) { public List<String> getVolumeMountPoint(String volumeName) {
log.info("get volume MountPoint"); log.info("get volume MountPoint");
List<String> mountPoints = new ArrayList<>(); List<String> mountPoints = new ArrayList<>();
String cmd=Constant.df + "|grep " + volumeName + "|awk '{print $6}'"; String cmd=Constant.df + "|grep " + volumeName + "|awk '{print $6}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd); List<String> reStrings = Constant.ganymedSSH.execCmdWaitAcquiescent(cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("11001 get result string wrong"); log.error("11001 get result string wrong");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("11002 " + volumeName + " is not exists or no mountpoint"); log.error("11002 " + volumeName + " is not exists or no mountpoint");
return null; return null;
} }
for (String mountPoint : reStrings) { for (String mountPoint : reStrings) {
mountPoint = mountPoint.replaceAll(" ", ""); mountPoint = mountPoint.replaceAll(" ", "");
mountPoints.add(mountPoint); mountPoints.add(mountPoint);
} }
return mountPoints; return mountPoints;
} }
public String getOneVolumeMountPoint(String volumeName) { public String getOneVolumeMountPoint(String volumeName) {
log.info("get one volume MountPoint"); log.info("get one volume MountPoint");
String mountPoint=null; String mountPoint=null;
List<String> mountpoints = getVolumeMountPoint(volumeName); List<String> mountpoints = getVolumeMountPoint(volumeName);
// System.out.println(reStrings); // System.out.println(reStrings);
if (mountpoints == null || mountpoints.size() == 0) { if (mountpoints == null || mountpoints.size() == 0) {
log.error("11001 get result string wrong"); log.error("11001 get result string wrong");
return null; return null;
} }
mountPoint=mountpoints.get(0); mountPoint=mountpoints.get(0);
return mountPoint; return mountPoint;
} }
/** /**
* volumeNamebrick * volumeNamebrick
* mapbricks <ip:path,data_size> * mapbricks <ip:path,data_size>
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public Map<String, Double> getVolumebricksDataSize(String volumeName) { public Map<String, Double> getVolumebricksDataSize(String volumeName) {
List<String> bricks = getVolumeBricks(volumeName); List<String> bricks = getVolumeBricks(volumeName);
Map<String, Double> brick_size = new HashMap<>(); Map<String, Double> brick_size = new HashMap<>();
if (bricks == null) { if (bricks == null) {
return null; return null;
} }
for (String brick : bricks) { for (String brick : bricks) {
String ipAndpath[] = brick.split(":"); String ipAndpath[] = brick.split(":");
String ip = ipAndpath[0]; String ip = ipAndpath[0];
String path = ipAndpath[1]; String path = ipAndpath[1];
String cmd = "du -d 0 " + path + "|awk '{print $1}'"; String cmd = "du -d 0 " + path + "|awk '{print $1}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWait(ip, Constant.rootUser, Constant.rootPasswd, List<String> reStrings = Constant.ganymedSSH.execCmdWait(ip, Constant.rootUser, Constant.rootPasswd,
Constant.port, cmd); Constant.port, cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1901 get result is null"); log.error("1901 get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1902 "+brick+" is not exits!"); log.error("1902 "+brick+" is not exits!");
return null; return null;
} }
Pattern pattern = Pattern.compile("[0-9]*"); Pattern pattern = Pattern.compile("[0-9]*");
Matcher isNum = pattern.matcher(reStrings.get(0)); Matcher isNum = pattern.matcher(reStrings.get(0));
if (!isNum.matches()) { if (!isNum.matches()) {
log.error("1903 " + reStrings.get(0) + " is unexpect"); log.error("1903 " + reStrings.get(0) + " is unexpect");
return null; return null;
} }
brick_size.put(brick, Double.parseDouble(reStrings.get(0))); brick_size.put(brick, Double.parseDouble(reStrings.get(0)));
} }
return brick_size; return brick_size;
} }
/** /**
* volumeNamebrick * volumeNamebrick
* mapbricks <ip:path,available_size> * mapbricks <ip:path,available_size>
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public Map<String, Double> getVolumebricksAvailableSize(String volumeName) { public Map<String, Double> getVolumebricksAvailableSize(String volumeName) {
List<String> bricks = getVolumeBricks(volumeName); List<String> bricks = getVolumeBricks(volumeName);
Map<String, Double> brick_size = new HashMap<>(); Map<String, Double> brick_size = new HashMap<>();
if (bricks == null) { if (bricks == null) {
return null; return null;
} }
for (String brick : bricks) { for (String brick : bricks) {
String ipAndpath[] = brick.split(":"); String ipAndpath[] = brick.split(":");
String ip = ipAndpath[0]; String ip = ipAndpath[0];
String path = ipAndpath[1]; String path = ipAndpath[1];
String cmd = "df " + path + "|awk '{print $4}'"; String cmd = "df " + path + "|awk '{print $4}'";
List<String> reStrings = Constant.ganymedSSH.execCmdWait(ip, Constant.rootUser, Constant.rootPasswd, List<String> reStrings = Constant.ganymedSSH.execCmdWait(ip, Constant.rootUser, Constant.rootPasswd,
Constant.port, cmd); Constant.port, cmd);
// System.out.println(reStrings); // System.out.println(reStrings);
if (reStrings == null) { if (reStrings == null) {
log.error("1901 get result is null"); log.error("1901 get result is null");
return null; return null;
} }
if (reStrings.size() == 0) { if (reStrings.size() == 0) {
log.error("1902 get result is nothing"); log.error("1902 get result is nothing");
return null; return null;
} }
Pattern pattern = Pattern.compile("[0-9]*"); Pattern pattern = Pattern.compile("[0-9]*");
Matcher isNum = pattern.matcher(reStrings.get(1)); Matcher isNum = pattern.matcher(reStrings.get(1));
if (!isNum.matches()) { if (!isNum.matches()) {
log.error("1903 " + reStrings.get(1) + " is unexpect"); log.error("1903 " + reStrings.get(1) + " is unexpect");
return null; return null;
} }
brick_size.put(brick, Double.parseDouble(reStrings.get(1))); brick_size.put(brick, Double.parseDouble(reStrings.get(1)));
} }
return brick_size; return brick_size;
} }
/** /**
* volumeNametruefalse * volumeNametruefalse
* *
* @param volumeName * @param volumeName
* @return * @return
* @see [##] * @see [##]
*/ */
public boolean volumeIsExists(String volumeName) { public boolean volumeIsExists(String volumeName) {
List<String> volumes = showAllVolumeName(); List<String> volumes = showAllVolumeName();
if (volumes == null) { if (volumes == null) {
return false; return false;
} }
if (volumes.contains(volumeName)) { if (volumes.contains(volumeName)) {
return true; return true;
} }
return false; return false;
} }
// @Test // @Test
public void test_getVolumebricksDataSize() { public void test_getVolumebricksDataSize() {
System.out.println(getVolumebricksDataSize("gfs_ftp")); System.out.println(getVolumebricksDataSize("gfs_ftp"));
} }
// @Test // @Test
public void test_getVolumebricksAvailableSize() { public void test_getVolumebricksAvailableSize() {
System.out.println(getVolumebricksAvailableSize("gfs_ftp")); System.out.println(getVolumebricksAvailableSize("gfs_ftp"));
} }
// @Test // @Test
public void test_getVolumeBricks() { public void test_getVolumeBricks() {
getVolumeBricks("gfs_ftp"); getVolumeBricks("gfs_ftp");
} }
@Test @Test
public void test_getVolumeStatus() { public void test_getVolumeStatus() {
System.out.println(getVolumeStatus("gs_fp")); System.out.println(getVolumeStatus("gs_fp"));
} }
// @Test // @Test
public void test_getVolumeMountPoint() { public void test_getVolumeMountPoint() {
System.out.println(getVolumeMountPoint("gfs_ftp")); System.out.println(getVolumeMountPoint("gfs_ftp"));
System.out.println(getVolumeMountPoint("v1")); System.out.println(getVolumeMountPoint("v1"));
} }
} }

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save