ing
This commit is contained in:
parent
b3b052b5bd
commit
1d3ae7c6a7
2
pom.xml
2
pom.xml
|
@ -13,7 +13,7 @@
|
|||
<groupId>com.loafle.overflow</groupId>
|
||||
<artifactId>commons-java</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<version>1.0.1-SNAPSHOT</version>
|
||||
<version>1.0.3-SNAPSHOT</version>
|
||||
<name>com.loafle.overflow.commons-java</name>
|
||||
|
||||
<properties>
|
||||
|
|
|
@ -5,7 +5,7 @@ import java.lang.annotation.Retention;
|
|||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Target({ElementType.METHOD})
|
||||
@Target({ ElementType.METHOD })
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface ProbeAPI {
|
||||
String value() default "";
|
||||
|
|
|
@ -8,7 +8,7 @@ import java.lang.annotation.Target;
|
|||
import org.springframework.core.annotation.AliasFor;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Target({ElementType.TYPE})
|
||||
@Target({ ElementType.TYPE })
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Component
|
||||
public @interface RPCService {
|
||||
|
|
|
@ -5,7 +5,7 @@ import java.lang.annotation.Retention;
|
|||
import java.lang.annotation.RetentionPolicy;
|
||||
import java.lang.annotation.Target;
|
||||
|
||||
@Target({ElementType.METHOD})
|
||||
@Target({ ElementType.METHOD })
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface WebappAPI {
|
||||
String value() default "";
|
||||
|
|
|
@ -2,7 +2,11 @@ package com.loafle.overflow.core.exception;
|
|||
|
||||
public class OverflowException extends Exception {
|
||||
private static final long serialVersionUID = -2737018677113628699L;
|
||||
public OverflowException(String message){ super(message); }
|
||||
|
||||
public OverflowException(String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
public OverflowException(String message, Throwable throwable) {
|
||||
super(message, throwable);
|
||||
}
|
||||
|
|
|
@ -15,11 +15,10 @@ public class Mail {
|
|||
private String mailSubject;
|
||||
private String mailContent;
|
||||
private String contentType;
|
||||
private List< Object > attachments;
|
||||
private Map< String, Object > model;
|
||||
private List<Object> attachments;
|
||||
private Map<String, Object> model;
|
||||
private String templateLoacation;
|
||||
|
||||
|
||||
public Mail() {
|
||||
contentType = "text/plain";
|
||||
}
|
||||
|
@ -84,19 +83,19 @@ public class Mail {
|
|||
this.mailContent = mailContent;
|
||||
}
|
||||
|
||||
public List< Object > getAttachments() {
|
||||
public List<Object> getAttachments() {
|
||||
return attachments;
|
||||
}
|
||||
|
||||
public void setAttachments(List < Object > attachments) {
|
||||
public void setAttachments(List<Object> attachments) {
|
||||
this.attachments = attachments;
|
||||
}
|
||||
|
||||
public Map< String, Object > getModel() {
|
||||
public Map<String, Object> getModel() {
|
||||
return model;
|
||||
}
|
||||
|
||||
public void setModel(Map < String, Object > model) {
|
||||
public void setModel(Map<String, Object> model) {
|
||||
this.model = model;
|
||||
}
|
||||
|
||||
|
|
|
@ -40,9 +40,7 @@ public class PublishMessage {
|
|||
}
|
||||
|
||||
public static enum TargetType {
|
||||
MEMBER_SESSION("MEMBER_SESSION"),
|
||||
MEMBER("MEMBER"),
|
||||
PROBE("PROBE");
|
||||
MEMBER_SESSION("MEMBER_SESSION"), MEMBER("MEMBER"), PROBE("PROBE");
|
||||
|
||||
final private String name;
|
||||
|
||||
|
|
|
@ -8,7 +8,10 @@ public enum CryptoType {
|
|||
TLS("TLS");
|
||||
|
||||
private String stringValue;
|
||||
CryptoType(String string) {stringValue = string;}
|
||||
|
||||
CryptoType(String string) {
|
||||
stringValue = string;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
|
|
|
@ -9,7 +9,10 @@ public enum PortType {
|
|||
TLS("TLS");
|
||||
|
||||
private String stringValue;
|
||||
PortType(String string) {stringValue = string;}
|
||||
|
||||
PortType(String string) {
|
||||
stringValue = string;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
|
|
|
@ -14,7 +14,7 @@ public class ApiKey {
|
|||
private Domain domain;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -23,7 +23,7 @@ public class ApiKey {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
@Column(name = "API_KEY", nullable = false, unique = true,length = 50)
|
||||
@Column(name = "API_KEY", nullable = false, unique = true, length = 50)
|
||||
public String getApiKey() {
|
||||
return apiKey;
|
||||
}
|
||||
|
@ -33,7 +33,7 @@ public class ApiKey {
|
|||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
@ -43,7 +43,7 @@ public class ApiKey {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "DOMAIN_ID", nullable=false)
|
||||
@JoinColumn(name = "DOMAIN_ID", nullable = false)
|
||||
public Domain getDomain() {
|
||||
return domain;
|
||||
}
|
||||
|
@ -51,28 +51,30 @@ public class ApiKey {
|
|||
public void setDomain(Domain domain) {
|
||||
this.domain = domain;
|
||||
}
|
||||
//
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// TblApiKey tblApiKey = (TblApiKey) o;
|
||||
//
|
||||
// if (id != tblApiKey.id) return false;
|
||||
// if (domainId != tblApiKey.domainId) return false;
|
||||
// if (apiKey != null ? !apiKey.equals(tblApiKey.apiKey) : tblApiKey.apiKey != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(tblApiKey.createDate) : tblApiKey.createDate != null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (int) (domainId ^ (domainId >>> 32));
|
||||
// return result;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// TblApiKey tblApiKey = (TblApiKey) o;
|
||||
//
|
||||
// if (id != tblApiKey.id) return false;
|
||||
// if (domainId != tblApiKey.domainId) return false;
|
||||
// if (apiKey != null ? !apiKey.equals(tblApiKey.apiKey) : tblApiKey.apiKey !=
|
||||
// null) return false;
|
||||
// if (createDate != null ? !createDate.equals(tblApiKey.createDate) :
|
||||
// tblApiKey.createDate != null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (int) (domainId ^ (domainId >>> 32));
|
||||
// return result;
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -15,13 +15,13 @@ import java.util.Date;
|
|||
@Table(name = "AUTH_CRAWLER", schema = "public")
|
||||
public class AuthCrawler {
|
||||
private Long id;
|
||||
private MetaCrawler crawler;
|
||||
private MetaCrawler metaCrawler;
|
||||
private Target target;
|
||||
private String authJson;
|
||||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -31,13 +31,13 @@ public class AuthCrawler {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
|
|
|
@ -27,30 +27,35 @@ public class Metric {
|
|||
public String getSensorConfigID() {
|
||||
return sensorConfigID;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param sensorConfigID the sensorConfigID to set
|
||||
*/
|
||||
public void setSensorConfigID(String sensorConfigID) {
|
||||
this.sensorConfigID = sensorConfigID;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the data
|
||||
*/
|
||||
public Map<String, String> getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param data the data to set
|
||||
*/
|
||||
public void setData(Map<String, String> data) {
|
||||
this.data = data;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the collectDate
|
||||
*/
|
||||
public Date getCollectDate() {
|
||||
return collectDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param collectDate the collectDate to set
|
||||
*/
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.discovery;
|
||||
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.discovery;
|
||||
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.loafle.overflow.core.type.CryptoType;
|
||||
|
|
|
@ -15,12 +15,13 @@ public class Domain {
|
|||
|
||||
public Domain() {
|
||||
}
|
||||
|
||||
public Domain(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@ public class DomainMember {
|
|||
private Domain domain;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -36,7 +36,6 @@ public class DomainMember {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "MEMBER_ID", nullable = false)
|
||||
public Member getMember() {
|
||||
|
|
|
@ -17,10 +17,10 @@ public class EmailAuth {
|
|||
private Date createDate;
|
||||
private Date authConfirmDate;
|
||||
private Member member;
|
||||
private MetaEmailStatus emailStatus;
|
||||
private MetaEmailStatus metaEmailStatus;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -70,12 +70,12 @@ public class EmailAuth {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "STATUS", nullable = false)
|
||||
public MetaEmailStatus getEmailStatus() {
|
||||
return emailStatus;
|
||||
@JoinColumn(name = "META_EMAIL_STATUS_ID", nullable = false)
|
||||
public MetaEmailStatus getMetaEmailStatus() {
|
||||
return metaEmailStatus;
|
||||
}
|
||||
|
||||
public void setEmailStatus(MetaEmailStatus emailStatus) {
|
||||
this.emailStatus = emailStatus;
|
||||
public void setMetaEmailStatus(MetaEmailStatus metaEmailStatus) {
|
||||
this.metaEmailStatus = metaEmailStatus;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,17 +16,16 @@ import java.util.Date;
|
|||
public class History {
|
||||
private Long id;
|
||||
private Date createDate;
|
||||
private MetaHistoryType type;
|
||||
private MetaHistoryType metaHistoryType;
|
||||
private String message;
|
||||
private Probe probe;
|
||||
private Member member;
|
||||
private Domain domain;
|
||||
|
||||
//private MetaResultType resultType; // i'm not sure this is necessary
|
||||
|
||||
// private MetaResultType resultType; // i'm not sure this is necessary
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -46,13 +45,13 @@ public class History {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable = false)
|
||||
public MetaHistoryType getType() {
|
||||
return type;
|
||||
@JoinColumn(name = "META_HISTORY_TYPE_ID", nullable = false)
|
||||
public MetaHistoryType getMetaHistoryType() {
|
||||
return metaHistoryType;
|
||||
}
|
||||
|
||||
public void setType(MetaHistoryType type) {
|
||||
this.type = type;
|
||||
public void setMetaHistoryType(MetaHistoryType metaHistoryType) {
|
||||
this.metaHistoryType = metaHistoryType;
|
||||
}
|
||||
|
||||
@Column(name = "MESSAGE", nullable = false, length = 255)
|
||||
|
@ -96,13 +95,17 @@ public class History {
|
|||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
if (this == o)
|
||||
return true;
|
||||
if (o == null || getClass() != o.getClass())
|
||||
return false;
|
||||
|
||||
History that = (History) o;
|
||||
|
||||
if (id != that.id) return false;
|
||||
if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false;
|
||||
if (id != that.id)
|
||||
return false;
|
||||
if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.infra;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.meta.MetaInfraType;
|
||||
import com.loafle.overflow.model.probe.Probe;
|
||||
import javax.persistence.*;
|
||||
|
@ -15,12 +14,12 @@ import java.util.Date;
|
|||
@DiscriminatorColumn(name = "INFRA_TYPE", discriminatorType = DiscriminatorType.INTEGER)
|
||||
public abstract class Infra {
|
||||
private Long id;
|
||||
private MetaInfraType infraType;
|
||||
private MetaInfraType metaInfraType;
|
||||
private Date createDate;
|
||||
private Probe probe;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -30,13 +29,13 @@ public abstract class Infra {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable = false)
|
||||
public MetaInfraType getInfraType() {
|
||||
return infraType;
|
||||
@JoinColumn(name = "META_INFRA_TYPE_ID", nullable = false)
|
||||
public MetaInfraType getMetaInfraType() {
|
||||
return metaInfraType;
|
||||
}
|
||||
|
||||
public void setInfraType(MetaInfraType infraType) {
|
||||
this.infraType = infraType;
|
||||
public void setMetaInfraType(MetaInfraType metaInfraType) {
|
||||
this.metaInfraType = metaInfraType;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
|
@ -59,5 +58,4 @@ public abstract class Infra {
|
|||
this.probe = probe;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -10,31 +10,31 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_HOST", schema = "public")
|
||||
@DiscriminatorValue("2")
|
||||
public class InfraHost extends Infra {
|
||||
// private Long id;
|
||||
private InfraOS os;
|
||||
// private Long id;
|
||||
private InfraOS infraOS;
|
||||
private String ipv4;
|
||||
private String ipv6;
|
||||
private String mac;
|
||||
private Date createDate;
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "OS_ID", nullable = true)
|
||||
public InfraOS getOs() {
|
||||
return os;
|
||||
@JoinColumn(name = "INFRA_OS_ID", nullable = true)
|
||||
public InfraOS getInfraOS() {
|
||||
return infraOS;
|
||||
}
|
||||
|
||||
public void setOs(InfraOS os) {
|
||||
this.os = os;
|
||||
public void setInfraOS(InfraOS infraOS) {
|
||||
this.infraOS = infraOS;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
|
|
@ -10,26 +10,24 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_MACHINE", schema = "public")
|
||||
@DiscriminatorValue("1")
|
||||
public class InfraMachine extends Infra {
|
||||
// private Long id;
|
||||
// private Long id;
|
||||
|
||||
private String meta;
|
||||
private Date createDate;
|
||||
|
||||
/*
|
||||
private Long id;
|
||||
private String meta;
|
||||
private Date createDate;
|
||||
* private Long id; private String meta; private Date createDate;
|
||||
*/
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@Basic
|
||||
@Column(name = "META", nullable = true, length = 1000)
|
||||
|
@ -52,4 +50,3 @@ public class InfraMachine extends Infra {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.infra;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.meta.MetaInfraVendor;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
@ -13,30 +12,30 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_OS", schema = "public")
|
||||
@DiscriminatorValue("3")
|
||||
public class InfraOS extends Infra {
|
||||
// private Long id;
|
||||
private InfraMachine machine;
|
||||
// private Long id;
|
||||
private InfraMachine infraMachine;
|
||||
private String meta;
|
||||
private Date createDate;
|
||||
private MetaInfraVendor vendor;
|
||||
private MetaInfraVendor metaInfraVendor;
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "MACHINE_ID", nullable = true)
|
||||
public InfraMachine getMachine() {
|
||||
return machine;
|
||||
@JoinColumn(name = "INFRA_MACHINE_ID", nullable = true)
|
||||
public InfraMachine getInfraMachine() {
|
||||
return infraMachine;
|
||||
}
|
||||
|
||||
public void setMachine(InfraMachine machine) {
|
||||
this.machine = machine;
|
||||
public void setInfraMachine(InfraMachine infraMachine) {
|
||||
this.infraMachine = infraMachine;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
@ -60,13 +59,13 @@ public class InfraOS extends Infra {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getVendor() {
|
||||
return vendor;
|
||||
@JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getMetaInfraVendor() {
|
||||
return metaInfraVendor;
|
||||
}
|
||||
|
||||
public void setVendor(MetaInfraVendor vendor) {
|
||||
this.vendor = vendor;
|
||||
public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) {
|
||||
this.metaInfraVendor = metaInfraVendor;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -10,29 +10,29 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_OS_APPLICATION", schema = "public")
|
||||
@DiscriminatorValue("4")
|
||||
public class InfraOSApplication extends Infra {
|
||||
// private Long id;
|
||||
private InfraOS os;
|
||||
// private Long id;
|
||||
private InfraOS infraOS;
|
||||
private String name;
|
||||
private Date createDate;
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "OS_ID", nullable = true)
|
||||
public InfraOS getOs() {
|
||||
return os;
|
||||
@JoinColumn(name = "INFRA_OS_ID", nullable = true)
|
||||
public InfraOS getInfraOS() {
|
||||
return infraOS;
|
||||
}
|
||||
|
||||
public void setOs(InfraOS os) {
|
||||
this.os = os;
|
||||
public void setInfraOS(InfraOS infraOS) {
|
||||
this.infraOS = infraOS;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
|
|
@ -10,29 +10,29 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_OS_DAEMON", schema = "public")
|
||||
@DiscriminatorValue("5")
|
||||
public class InfraOSDaemon extends Infra {
|
||||
// private Long id;
|
||||
private InfraOS os;
|
||||
// private Long id;
|
||||
private InfraOS infraOS;
|
||||
private String name;
|
||||
private Date createDate;
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "OS_ID", nullable = true)
|
||||
public InfraOS getOs() {
|
||||
return os;
|
||||
@JoinColumn(name = "INFRA_OS_ID", nullable = true)
|
||||
public InfraOS getInfraOS() {
|
||||
return infraOS;
|
||||
}
|
||||
|
||||
public void setOs(InfraOS os) {
|
||||
this.os = os;
|
||||
public void setInfraOS(InfraOS infraOS) {
|
||||
this.infraOS = infraOS;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.infra;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.meta.MetaInfraVendor;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
@ -13,32 +12,32 @@ import java.util.Date;
|
|||
@Table(name = "INFRA_OS_PORT", schema = "public")
|
||||
@DiscriminatorValue("6")
|
||||
public class InfraOSPort extends Infra {
|
||||
// private Long id;
|
||||
private InfraOS os;
|
||||
// private Long id;
|
||||
private InfraOS infraOS;
|
||||
private Date createDate;
|
||||
private Integer port;
|
||||
private String portType;
|
||||
private MetaInfraVendor vendor;
|
||||
private MetaInfraVendor metaInfraVendor;
|
||||
private Boolean tlsType;
|
||||
//
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
//
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "OS_ID", nullable = true)
|
||||
public InfraOS getOs() {
|
||||
return this.os;
|
||||
@JoinColumn(name = "INFRA_OS_ID", nullable = true)
|
||||
public InfraOS getInfraOS() {
|
||||
return infraOS;
|
||||
}
|
||||
|
||||
public void setOs(InfraOS os) {
|
||||
this.os = os;
|
||||
public void setInfraOS(InfraOS infraOS) {
|
||||
this.infraOS = infraOS;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
|
@ -72,13 +71,13 @@ public class InfraOSPort extends Infra {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getVendor() {
|
||||
return vendor;
|
||||
@JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getMetaInfraVendor() {
|
||||
return metaInfraVendor;
|
||||
}
|
||||
|
||||
public void setVendor(MetaInfraVendor vendor) {
|
||||
this.vendor = vendor;
|
||||
public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) {
|
||||
this.metaInfraVendor = metaInfraVendor;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.infra;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.meta.MetaInfraVendor;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
@ -12,33 +11,33 @@ import java.util.Date;
|
|||
@Entity(name = "INFRA_SERVICE")
|
||||
@Table(name = "INFRA_SERVICE", schema = "public")
|
||||
@DiscriminatorValue("7")
|
||||
public class InfraService extends Infra{
|
||||
// private Long id;
|
||||
private InfraHost host;
|
||||
public class InfraService extends Infra {
|
||||
// private Long id;
|
||||
private InfraHost infraHost;
|
||||
private String portType;
|
||||
private Integer port;
|
||||
private MetaInfraVendor vendor;
|
||||
private MetaInfraVendor metaInfraVendor;
|
||||
private Date createDate;
|
||||
private Boolean tlsType;
|
||||
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
// @Id
|
||||
// @GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
// public Long getId() {
|
||||
// return id;
|
||||
// }
|
||||
//
|
||||
// public void setId(Long id) {
|
||||
// this.id = id;
|
||||
// }
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "HOST_ID", nullable = true)
|
||||
public InfraHost getHost() {
|
||||
return host;
|
||||
@JoinColumn(name = "INFRA_HOST_ID", nullable = true)
|
||||
public InfraHost getInfraHost() {
|
||||
return infraHost;
|
||||
}
|
||||
|
||||
public void setHost(InfraHost host) {
|
||||
this.host = host;
|
||||
public void setInfraHost(InfraHost infraHost) {
|
||||
this.infraHost = infraHost;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
@ -62,13 +61,13 @@ public class InfraService extends Infra{
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getVendor() {
|
||||
return vendor;
|
||||
@JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = true)
|
||||
public MetaInfraVendor getMetaInfraVendor() {
|
||||
return metaInfraVendor;
|
||||
}
|
||||
|
||||
public void setVendor(MetaInfraVendor vendor) {
|
||||
this.vendor = vendor;
|
||||
public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) {
|
||||
this.metaInfraVendor = metaInfraVendor;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
|
|
|
@ -20,7 +20,7 @@ public class Member {
|
|||
private String phone;
|
||||
private String companyName;
|
||||
private Date createDate;
|
||||
private MetaMemberStatus status;
|
||||
private MetaMemberStatus metaMemberStatus;
|
||||
private Integer signinFailCount;
|
||||
private Boolean totpType;
|
||||
|
||||
|
@ -32,7 +32,7 @@ public class Member {
|
|||
}
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -103,17 +103,17 @@ public class Member {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "STATUS_ID", nullable = false)
|
||||
public MetaMemberStatus getStatus() {
|
||||
return status;
|
||||
@JoinColumn(name = "META_MEMBER_STATUS_ID", nullable = false)
|
||||
public MetaMemberStatus getMetaMemberStatus() {
|
||||
return metaMemberStatus;
|
||||
}
|
||||
|
||||
public void setStatus(MetaMemberStatus status) {
|
||||
this.status = status;
|
||||
public void setMetaMemberStatus(MetaMemberStatus metaMemberStatus) {
|
||||
this.metaMemberStatus = metaMemberStatus;
|
||||
}
|
||||
|
||||
@Column(name = "SIGNIN_FAIL_COUNT", nullable = true, columnDefinition = "int default 0")
|
||||
public Integer getSigninFailCount(){
|
||||
public Integer getSigninFailCount() {
|
||||
return this.signinFailCount;
|
||||
}
|
||||
|
||||
|
@ -131,4 +131,3 @@ public class Member {
|
|||
this.totpType = totpType;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.member;
|
||||
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.Date;
|
||||
|
||||
|
@ -25,7 +24,7 @@ public class MemberTotp {
|
|||
}
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
|
|
@ -24,7 +24,7 @@ public class MetaCrawler {
|
|||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
@ -51,5 +51,4 @@ public class MetaCrawler {
|
|||
this.description = description;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -10,8 +10,8 @@ import java.util.Date;
|
|||
@Table(name = "META_CRAWLER_INPUT_ITEM", schema = "public")
|
||||
public class MetaCrawlerInputItem {
|
||||
private Integer id;
|
||||
private MetaInputType inputType;
|
||||
private MetaCrawler crawler;
|
||||
private MetaInputType metaInputType;
|
||||
private MetaCrawler metaCrawler;
|
||||
private String description;
|
||||
private String name;
|
||||
private Date createDate;
|
||||
|
@ -30,25 +30,24 @@ public class MetaCrawlerInputItem {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable = false)
|
||||
public MetaInputType getInputType() {
|
||||
return inputType;
|
||||
@JoinColumn(name = "META_INPUT_TYPE_ID", nullable = false)
|
||||
public MetaInputType getMetaInputType() {
|
||||
return metaInputType;
|
||||
}
|
||||
|
||||
public void setInputType(MetaInputType inputType) {
|
||||
this.inputType = inputType;
|
||||
public void setMetaInputType(MetaInputType metaInputType) {
|
||||
this.metaInputType = metaInputType;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@Column(name = "DESCRIPTION", nullable = true, length = 50)
|
||||
|
@ -97,7 +96,6 @@ public class MetaCrawlerInputItem {
|
|||
this.defaultValue = defaultValue;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "PATTERN", nullable = true, length = 50)
|
||||
public String getPattern() {
|
||||
return pattern;
|
||||
|
@ -107,7 +105,6 @@ public class MetaCrawlerInputItem {
|
|||
this.pattern = pattern;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "KEY_NAME", nullable = true, length = 50)
|
||||
public String getKeyName() {
|
||||
return keyName;
|
||||
|
@ -117,7 +114,6 @@ public class MetaCrawlerInputItem {
|
|||
this.keyName = keyName;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "KEY_VALUE", nullable = true, length = 50)
|
||||
public String getKeyValue() {
|
||||
return keyValue;
|
||||
|
@ -127,41 +123,46 @@ public class MetaCrawlerInputItem {
|
|||
this.keyValue = keyValue;
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public Boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// MetaCrawlerInputItem that = (MetaCrawlerInputItem) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (typeId != that.typeId) return false;
|
||||
// if (crawlerId != that.crawlerId) return false;
|
||||
// if (required != that.required) return false;
|
||||
// if (desc != null ? !desc.equals(that.desc) : that.desc != null) return false;
|
||||
// if (name != null ? !name.equals(that.name) : that.name != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false;
|
||||
// if (defaultValue != null ? !defaultValue.equals(that.defaultValue) : that.defaultValue != null) return false;
|
||||
// if (pattern != null ? !pattern.equals(that.pattern) : that.pattern != null) return false;
|
||||
// if (keyName != null ? !keyName.equals(that.keyName) : that.keyName != null) return false;
|
||||
// if (keyValue != null ? !keyValue.equals(that.keyValue) : that.keyValue != null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = id;
|
||||
// result = 31 * result + (int) typeId;
|
||||
// result = 31 * result + (int) crawlerId;
|
||||
// result = 31 * result + (desc != null ? desc.hashCode() : 0);
|
||||
// result = 31 * result + (name != null ? name.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (required ? 1 : 0);
|
||||
// result = 31 * result + (defaultValue != null ? defaultValue.hashCode() : 0);
|
||||
// result = 31 * result + (pattern != null ? pattern.hashCode() : 0);
|
||||
// result = 31 * result + (keyName != null ? keyName.hashCode() : 0);
|
||||
// result = 31 * result + (keyValue != null ? keyValue.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
// @Override
|
||||
// public Boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// MetaCrawlerInputItem that = (MetaCrawlerInputItem) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (typeId != that.typeId) return false;
|
||||
// if (crawlerId != that.crawlerId) return false;
|
||||
// if (required != that.required) return false;
|
||||
// if (desc != null ? !desc.equals(that.desc) : that.desc != null) return false;
|
||||
// if (name != null ? !name.equals(that.name) : that.name != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) :
|
||||
// that.createDate != null) return false;
|
||||
// if (defaultValue != null ? !defaultValue.equals(that.defaultValue) :
|
||||
// that.defaultValue != null) return false;
|
||||
// if (pattern != null ? !pattern.equals(that.pattern) : that.pattern != null)
|
||||
// return false;
|
||||
// if (keyName != null ? !keyName.equals(that.keyName) : that.keyName != null)
|
||||
// return false;
|
||||
// if (keyValue != null ? !keyValue.equals(that.keyValue) : that.keyValue !=
|
||||
// null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = id;
|
||||
// result = 31 * result + (int) typeId;
|
||||
// result = 31 * result + (int) crawlerId;
|
||||
// result = 31 * result + (desc != null ? desc.hashCode() : 0);
|
||||
// result = 31 * result + (name != null ? name.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (required ? 1 : 0);
|
||||
// result = 31 * result + (defaultValue != null ? defaultValue.hashCode() : 0);
|
||||
// result = 31 * result + (pattern != null ? pattern.hashCode() : 0);
|
||||
// result = 31 * result + (keyName != null ? keyName.hashCode() : 0);
|
||||
// result = 31 * result + (keyValue != null ? keyValue.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -11,7 +11,8 @@ public class MetaEmailStatus {
|
|||
private String name;
|
||||
private Date createDate;
|
||||
|
||||
public MetaEmailStatus(){}
|
||||
public MetaEmailStatus() {
|
||||
}
|
||||
|
||||
public MetaEmailStatus(Integer id) {
|
||||
this.id = id;
|
||||
|
@ -26,7 +27,6 @@ public class MetaEmailStatus {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -37,7 +37,7 @@ public class MetaEmailStatus {
|
|||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
|
|
@ -30,7 +30,6 @@ public class MetaHistoryType {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -41,7 +40,7 @@ public class MetaHistoryType {
|
|||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
|
|
@ -13,6 +13,10 @@ public class MetaInfraType {
|
|||
private String name;
|
||||
private Date createDate;
|
||||
|
||||
public MetaInfraType(Integer id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
@Id
|
||||
public Integer getId() {
|
||||
return id;
|
||||
|
@ -22,7 +26,6 @@ public class MetaInfraType {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -12,7 +12,7 @@ public class MetaInfraVendor {
|
|||
private Integer id;
|
||||
private String name;
|
||||
private Date createDate;
|
||||
private MetaInfraType infraType;
|
||||
private MetaInfraType metaInfraType;
|
||||
|
||||
@Id
|
||||
public Integer getId() {
|
||||
|
@ -23,7 +23,6 @@ public class MetaInfraVendor {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -43,31 +42,28 @@ public class MetaInfraVendor {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable=false)
|
||||
public MetaInfraType getInfraType() {
|
||||
return infraType;
|
||||
@JoinColumn(name = "META_INFRA_TYPE_ID", nullable = false)
|
||||
public MetaInfraType getMetaInfraType() {
|
||||
return metaInfraType;
|
||||
}
|
||||
|
||||
public void setInfraType(MetaInfraType infraType) {
|
||||
this.infraType = infraType;
|
||||
public void setMetaInfraType(MetaInfraType metaInfraType) {
|
||||
this.metaInfraType = metaInfraType;
|
||||
}
|
||||
|
||||
|
||||
public static MetaInfraVendor CreateInfraVendorByOS(String osName) {
|
||||
|
||||
MetaInfraVendor vendor = new MetaInfraVendor();
|
||||
|
||||
if(osName == null || osName.length() <= 0) {
|
||||
if (osName == null || osName.length() <= 0) {
|
||||
vendor.setId(24); // FIXME: Unknown
|
||||
return vendor;
|
||||
}
|
||||
|
||||
if(osName.equals("Windows")) {
|
||||
if (osName.equals("Windows")) {
|
||||
vendor.setId(26);
|
||||
}
|
||||
else if(osName.equals("Linux")) {
|
||||
} else if (osName.equals("Linux")) {
|
||||
vendor.setId(28); // ubuntu
|
||||
} else {
|
||||
vendor.setId(24); // FIXME: Unknown
|
||||
|
@ -84,23 +80,18 @@ public class MetaInfraVendor {
|
|||
|
||||
MetaInfraVendor vendor = new MetaInfraVendor();
|
||||
|
||||
if(serviceName.equals("mysql")) {
|
||||
if (serviceName.equals("mysql")) {
|
||||
vendor.setId(11);
|
||||
}
|
||||
else if(serviceName.equals("portgresql")) {
|
||||
} else if (serviceName.equals("portgresql")) {
|
||||
vendor.setId(15);
|
||||
}
|
||||
else if(serviceName.equals("wmi")) {
|
||||
} else if (serviceName.equals("wmi")) {
|
||||
vendor.setId(23);
|
||||
}
|
||||
else if(serviceName.equals("snmpv2")) {
|
||||
} else if (serviceName.equals("snmpv2")) {
|
||||
vendor.setId(20);
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
vendor.setId(24); // unknown
|
||||
}
|
||||
|
||||
|
||||
return vendor;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,7 +23,6 @@ public class MetaInputType {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -33,7 +32,6 @@ public class MetaInputType {
|
|||
this.name = name;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "DESCRIPTION", nullable = true, length = 50)
|
||||
public String getDescription() {
|
||||
return description;
|
||||
|
|
|
@ -31,7 +31,6 @@ public class MetaMemberStatus {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "Name", nullable = false, length = 10)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -31,7 +31,6 @@ public class MetaNoAuthProbeStatus {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "Name", nullable = false, length = 10)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -33,7 +33,6 @@ public class MetaNotification {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -22,7 +22,6 @@ public class MetaProbeArchitecture {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "ARCHITECTURE", nullable = true, length = 10)
|
||||
public String getArchitecture() {
|
||||
return architecture;
|
||||
|
|
|
@ -22,7 +22,6 @@ public class MetaProbeOs {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -10,13 +10,13 @@ import java.util.Date;
|
|||
@Table(name = "META_PROBE_PACKAGE", schema = "public")
|
||||
public class MetaProbePackage {
|
||||
private Long id;
|
||||
private MetaProbeVersion version;
|
||||
private MetaProbeOs os;
|
||||
private MetaProbeArchitecture architecture;
|
||||
private MetaProbeVersion metaProbeVersion;
|
||||
private MetaProbeOs metaProbeOs;
|
||||
private MetaProbeArchitecture metaProbeArchitecture;
|
||||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -26,33 +26,33 @@ public class MetaProbePackage {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VERSION_ID", nullable = false)
|
||||
public MetaProbeVersion getVersion() {
|
||||
return version;
|
||||
@JoinColumn(name = "META_PROBE_VERSION_ID", nullable = false)
|
||||
public MetaProbeVersion getMetaProbeVersion() {
|
||||
return metaProbeVersion;
|
||||
}
|
||||
|
||||
public void setVersion(MetaProbeVersion version) {
|
||||
this.version = version;
|
||||
public void setMetaProbeVersion(MetaProbeVersion metaProbeVersion) {
|
||||
this.metaProbeVersion = metaProbeVersion;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "OS_ID", nullable = false)
|
||||
public MetaProbeOs getOs() {
|
||||
return os;
|
||||
@JoinColumn(name = "META_PROBE_OS_ID", nullable = false)
|
||||
public MetaProbeOs getMetaProbeOs() {
|
||||
return metaProbeOs;
|
||||
}
|
||||
|
||||
public void setOs(MetaProbeOs os) {
|
||||
this.os = os;
|
||||
public void setMetaProbeOs(MetaProbeOs metaProbeOs) {
|
||||
this.metaProbeOs = metaProbeOs;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ARCHITECTURE_ID", nullable = false)
|
||||
public MetaProbeArchitecture getArchitecture() {
|
||||
return architecture;
|
||||
@JoinColumn(name = "META_PROBE_ARCHITECTURE_ID", nullable = false)
|
||||
public MetaProbeArchitecture getMetaProbeArchitecture() {
|
||||
return metaProbeArchitecture;
|
||||
}
|
||||
|
||||
public void setArchitecture(MetaProbeArchitecture architecture) {
|
||||
this.architecture = architecture;
|
||||
public void setMetaProbeArchitecture(MetaProbeArchitecture metaProbeArchitecture) {
|
||||
this.metaProbeArchitecture = metaProbeArchitecture;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
|
|
|
@ -31,7 +31,6 @@ public class MetaProbeStatus {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "Name", nullable = false, length = 10)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -23,7 +23,6 @@ public class MetaProbeTaskType {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = false, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -52,5 +51,4 @@ public class MetaProbeTaskType {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -14,7 +14,7 @@ public class MetaProbeVersion {
|
|||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Short getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -23,7 +23,6 @@ public class MetaProbeVersion {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "VERSION", nullable = true, length = 10)
|
||||
public String getVersion() {
|
||||
return version;
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.meta;
|
||||
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.Date;
|
||||
|
||||
|
@ -15,15 +14,16 @@ public class MetaSensorDisplayItem {
|
|||
private String key;
|
||||
private String displayName;
|
||||
private String description;
|
||||
private MetaCrawler crawler;
|
||||
private MetaSensorItemUnit unit;
|
||||
private MetaCrawler metaCrawler;
|
||||
private MetaSensorItemUnit metaSensorItemUnit;
|
||||
private Date createDate;
|
||||
private Boolean isDefault;
|
||||
private MetaSensorItemType itemType;
|
||||
private MetaSensorItemType metaSensorItemType;
|
||||
|
||||
public MetaSensorDisplayItem() {
|
||||
|
||||
}
|
||||
|
||||
public MetaSensorDisplayItem(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
@ -64,29 +64,28 @@ public class MetaSensorDisplayItem {
|
|||
this.description = description;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "UNIT_ID", nullable = true)
|
||||
public MetaSensorItemUnit getUnit() {
|
||||
return unit;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_UNIT_ID", nullable = true)
|
||||
public MetaSensorItemUnit getMetaSensorItemUnit() {
|
||||
return metaSensorItemUnit;
|
||||
}
|
||||
|
||||
public void setUnit(MetaSensorItemUnit unit) {
|
||||
this.unit = unit;
|
||||
public void setMetaSensorItemUnit(MetaSensorItemUnit metaSensorItemUnit) {
|
||||
this.metaSensorItemUnit = metaSensorItemUnit;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
@ -95,9 +94,8 @@ public class MetaSensorDisplayItem {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
@Basic
|
||||
@Column(name="IS_DEFAULT", nullable = false, columnDefinition = "Boolean default false")
|
||||
@Column(name = "IS_DEFAULT", nullable = false, columnDefinition = "Boolean default false")
|
||||
public Boolean getDefault() {
|
||||
return isDefault;
|
||||
}
|
||||
|
@ -107,13 +105,13 @@ public class MetaSensorDisplayItem {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable = false)
|
||||
public MetaSensorItemType getItemType() {
|
||||
return itemType;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_TYPE_ID", nullable = false)
|
||||
public MetaSensorItemType getMetaSensorItemType() {
|
||||
return metaSensorItemType;
|
||||
}
|
||||
|
||||
public void setItemType(MetaSensorItemType itemType) {
|
||||
this.itemType = itemType;
|
||||
public void setMetaSensorItemType(MetaSensorItemType metaSensorItemType) {
|
||||
this.metaSensorItemType = metaSensorItemType;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -10,11 +10,11 @@ import javax.persistence.*;
|
|||
public class MetaSensorDisplayMapping {
|
||||
|
||||
private Long id;
|
||||
private MetaSensorDisplayItem displayItem;
|
||||
private MetaSensorItemKey itemKey;
|
||||
private MetaSensorDisplayItem metaSensorDisplayItem;
|
||||
private MetaSensorItemKey metaSensorItemKey;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -24,22 +24,22 @@ public class MetaSensorDisplayMapping {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "DISPLAY_ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getDisplayItem() {
|
||||
return displayItem;
|
||||
@JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getMetaSensorDisplayItem() {
|
||||
return metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
public void setDisplayItem(MetaSensorDisplayItem displayItem) {
|
||||
this.displayItem = displayItem;
|
||||
public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) {
|
||||
this.metaSensorDisplayItem = metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ITEM_KEY_ID", nullable = false)
|
||||
public MetaSensorItemKey getItemKey() {
|
||||
return itemKey;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_KEY_ID", nullable = false)
|
||||
public MetaSensorItemKey getMetaSensorItemKey() {
|
||||
return metaSensorItemKey;
|
||||
}
|
||||
|
||||
public void setItemKey(MetaSensorItemKey itemKey) {
|
||||
this.itemKey = itemKey;
|
||||
public void setMetaSensorItemKey(MetaSensorItemKey metaSensorItemKey) {
|
||||
this.metaSensorItemKey = metaSensorItemKey;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -23,7 +23,6 @@ public class MetaSensorItem {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "KEY", nullable = true, length = 100)
|
||||
public String getKey() {
|
||||
return key;
|
||||
|
|
|
@ -10,16 +10,16 @@ import java.util.Date;
|
|||
@Table(name = "META_SENSOR_ITEM_KEY", schema = "public")
|
||||
public class MetaSensorItemKey {
|
||||
private Long id;
|
||||
private MetaSensorItem item;
|
||||
private MetaSensorItem metaSensorItem;
|
||||
private String key;
|
||||
private String froms;
|
||||
private String option;
|
||||
private MetaCrawler crawler;
|
||||
private MetaCrawler metaCrawler;
|
||||
private Date createDate;
|
||||
private MetaSensorItemUnit unit;
|
||||
private MetaSensorItemUnit metaSensorItemUnit;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -29,13 +29,13 @@ public class MetaSensorItemKey {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ITEM_ID", nullable = false)
|
||||
public MetaSensorItem getItem() {
|
||||
return item;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_ID", nullable = false)
|
||||
public MetaSensorItem getMetaSensorItem() {
|
||||
return metaSensorItem;
|
||||
}
|
||||
|
||||
public void setItem(MetaSensorItem item) {
|
||||
this.item = item;
|
||||
public void setMetaSensorItem(MetaSensorItem metaSensorItem) {
|
||||
this.metaSensorItem = metaSensorItem;
|
||||
}
|
||||
|
||||
@Column(name = "KEY", nullable = false, length = 100)
|
||||
|
@ -66,17 +66,17 @@ public class MetaSensorItemKey {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
@ -86,12 +86,12 @@ public class MetaSensorItemKey {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "UNIT_ID", nullable = true)
|
||||
public MetaSensorItemUnit getUnit() {
|
||||
return unit;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_UNIT_ID", nullable = true)
|
||||
public MetaSensorItemUnit getMetaSensorItemUnit() {
|
||||
return metaSensorItemUnit;
|
||||
}
|
||||
|
||||
public void setUnit(MetaSensorItemUnit unit) {
|
||||
this.unit = unit;
|
||||
public void setMetaSensorItemUnit(MetaSensorItemUnit metaSensorItemUnit) {
|
||||
this.metaSensorItemUnit = metaSensorItemUnit;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -30,7 +30,6 @@ public class MetaSensorItemType {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "NAME", nullable = true, length = 50)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -40,7 +39,6 @@ public class MetaSensorItemType {
|
|||
this.name = name;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "DESCRIPTION", nullable = true, length = 50)
|
||||
public String getDescription() {
|
||||
return description;
|
||||
|
|
|
@ -33,7 +33,7 @@ public class MetaSensorItemUnit {
|
|||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name="CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
public Date getCreateDate() {
|
||||
return createDate;
|
||||
}
|
||||
|
|
|
@ -31,7 +31,6 @@ public class MetaSensorStatus {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "Name", nullable = false, length = 10)
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -10,8 +10,8 @@ import java.util.Date;
|
|||
@Table(name = "META_VENDOR_CRAWLER", schema = "public")
|
||||
public class MetaVendorCrawler {
|
||||
private Integer id;
|
||||
private MetaCrawler crawler;
|
||||
private MetaInfraVendor infraVendor;
|
||||
private MetaCrawler metaCrawler;
|
||||
private MetaInfraVendor metaInfraVendor;
|
||||
private Date createDate;
|
||||
|
||||
@Id
|
||||
|
@ -24,44 +24,44 @@ public class MetaVendorCrawler {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VENDOR_ID", nullable = false)
|
||||
public MetaInfraVendor getInfraVendor() {
|
||||
return infraVendor;
|
||||
@JoinColumn(name = "META_INFRA_VENDOR_ID", nullable = false)
|
||||
public MetaInfraVendor getMetaInfraVendor() {
|
||||
return metaInfraVendor;
|
||||
}
|
||||
|
||||
public void setInfraVendor(MetaInfraVendor infraVendor) {
|
||||
this.infraVendor = infraVendor;
|
||||
public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) {
|
||||
this.metaInfraVendor = metaInfraVendor;
|
||||
}
|
||||
|
||||
// @Basic
|
||||
// @Column(name = "CRAWLER_ID", nullable = false)
|
||||
// public short getCrawlerId() {
|
||||
// return crawlerId;
|
||||
// }
|
||||
//
|
||||
// public void setCrawlerId(short crawlerId) {
|
||||
// this.crawlerId = crawlerId;
|
||||
// }
|
||||
//
|
||||
// @Basic
|
||||
// @Column(name = "VENDOR_ID", nullable = false)
|
||||
// public int getVendorId() {
|
||||
// return vendorId;
|
||||
// }
|
||||
//
|
||||
// public void setVendorId(int vendorId) {
|
||||
// this.vendorId = vendorId;
|
||||
// }
|
||||
// @Column(name = "CRAWLER_ID", nullable = false)
|
||||
// public short getCrawlerId() {
|
||||
// return crawlerId;
|
||||
// }
|
||||
//
|
||||
// public void setCrawlerId(short crawlerId) {
|
||||
// this.crawlerId = crawlerId;
|
||||
// }
|
||||
//
|
||||
// @Basic
|
||||
// @Column(name = "VENDOR_ID", nullable = false)
|
||||
// public int getVendorId() {
|
||||
// return vendorId;
|
||||
// }
|
||||
//
|
||||
// public void setVendorId(int vendorId) {
|
||||
// this.vendorId = vendorId;
|
||||
// }
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
@Column(name = "CREATE_DATE", nullable = false, columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP", insertable = false, updatable = false)
|
||||
|
|
|
@ -13,12 +13,12 @@ public class MetaVendorCrawlerSensorItem {
|
|||
private String interval;
|
||||
private String warnCondition;
|
||||
private Date createDate;
|
||||
private MetaSensorItem sensorItem;
|
||||
private MetaInfraVendor vendor;
|
||||
private MetaSensorItem metaSensorItem;
|
||||
private MetaInfraVendor metaInfraVendor;
|
||||
private Short crawlerId;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -27,7 +27,6 @@ public class MetaVendorCrawlerSensorItem {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "INTERVAL", nullable = true, length = 50)
|
||||
public String getInterval() {
|
||||
return interval;
|
||||
|
@ -37,7 +36,6 @@ public class MetaVendorCrawlerSensorItem {
|
|||
this.interval = interval;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "WARN_CONDITION", nullable = true, length = 50)
|
||||
public String getWarnCondition() {
|
||||
return warnCondition;
|
||||
|
@ -57,25 +55,24 @@ public class MetaVendorCrawlerSensorItem {
|
|||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ITEM_ID", nullable = false)
|
||||
public MetaSensorItem getSensorItem() {
|
||||
return sensorItem;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_ID", nullable = false)
|
||||
public MetaSensorItem getMetaSensorItem() {
|
||||
return metaSensorItem;
|
||||
}
|
||||
|
||||
public void setSensorItem(MetaSensorItem sensorItem) {
|
||||
this.sensorItem = sensorItem;
|
||||
public void setMetaSensorItem(MetaSensorItem metaSensorItem) {
|
||||
this.metaSensorItem = metaSensorItem;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "VENDOR_ID", nullable = false)
|
||||
public MetaInfraVendor getVendor() {
|
||||
return vendor;
|
||||
public MetaInfraVendor getMetaInfraVendor() {
|
||||
return metaInfraVendor;
|
||||
}
|
||||
|
||||
public void setVendor(MetaInfraVendor vendor) {
|
||||
this.vendor = vendor;
|
||||
public void setMetaInfraVendor(MetaInfraVendor metaInfraVendor) {
|
||||
this.metaInfraVendor = metaInfraVendor;
|
||||
}
|
||||
|
||||
@Basic
|
||||
|
|
|
@ -5,31 +5,30 @@ package com.loafle.overflow.model.meta.type;
|
|||
*/
|
||||
public enum MetaCrawlerEnum {
|
||||
|
||||
ACTIVEDIRECTORY_CRAWLER((short)1),
|
||||
CASSANDRA_CRAWLER((short)2),
|
||||
DHCP_CRAWLER((short)3),
|
||||
DNS_CRAWLER((short)4),
|
||||
FTP_CRAWLER((short)5),
|
||||
HTTP_CRAWLER((short)6),
|
||||
IMAP_CRAWLER((short)7),
|
||||
LDAP_CRAWLER((short)8),
|
||||
MONGODB_CRAWLER((short)9),
|
||||
MSSQL_CRAWLER((short)10),
|
||||
MYSQL_CRAWLER((short)11),
|
||||
NETBIOS_CRAWLER((short)12),
|
||||
ORACLE_CRAWLER((short)13),
|
||||
POP_CRAWLER((short)14),
|
||||
POSTGRESQL_CRAWLER((short)15),
|
||||
REDIS_CRAWLER((short)16),
|
||||
JMX_CRAWLER((short)17),
|
||||
SMB_CRAWLER((short)18),
|
||||
SMTP_CRAWLER((short)19),
|
||||
SNMP_CRAWLER((short)20),
|
||||
SSH_CRAWLER((short)21),
|
||||
TELNET_CRAWLER((short)22),
|
||||
WMI_CRAWLER((short)23),
|
||||
UNKNOWN_CRAWLER((short)24);
|
||||
|
||||
ACTIVEDIRECTORY_CRAWLER((short) 1),
|
||||
CASSANDRA_CRAWLER((short) 2),
|
||||
DHCP_CRAWLER((short) 3),
|
||||
DNS_CRAWLER((short) 4),
|
||||
FTP_CRAWLER((short) 5),
|
||||
HTTP_CRAWLER((short) 6),
|
||||
IMAP_CRAWLER((short) 7),
|
||||
LDAP_CRAWLER((short) 8),
|
||||
MONGODB_CRAWLER((short) 9),
|
||||
MSSQL_CRAWLER((short) 10),
|
||||
MYSQL_CRAWLER((short) 11),
|
||||
NETBIOS_CRAWLER((short) 12),
|
||||
ORACLE_CRAWLER((short) 13),
|
||||
POP_CRAWLER((short) 14),
|
||||
POSTGRESQL_CRAWLER((short) 15),
|
||||
REDIS_CRAWLER((short) 16),
|
||||
JMX_CRAWLER((short) 17),
|
||||
SMB_CRAWLER((short) 18),
|
||||
SMTP_CRAWLER((short) 19),
|
||||
SNMP_CRAWLER((short) 20),
|
||||
SSH_CRAWLER((short) 21),
|
||||
TELNET_CRAWLER((short) 22),
|
||||
WMI_CRAWLER((short) 23),
|
||||
UNKNOWN_CRAWLER((short) 24);
|
||||
|
||||
private Short value;
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.noauthprobe;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.domain.Domain;
|
||||
import com.loafle.overflow.model.meta.MetaNoAuthProbeStatus;
|
||||
import com.loafle.overflow.model.probe.Probe;
|
||||
|
@ -16,7 +15,7 @@ import java.util.Date;
|
|||
public class NoAuthProbe {
|
||||
private Long id;
|
||||
private String description;
|
||||
private MetaNoAuthProbeStatus status;
|
||||
private MetaNoAuthProbeStatus metaNoAuthProbeStatus;
|
||||
private String tempProbeKey;
|
||||
private Date connectDate;
|
||||
private String apiKey;
|
||||
|
@ -26,7 +25,7 @@ public class NoAuthProbe {
|
|||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -45,13 +44,13 @@ public class NoAuthProbe {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "STATUS", nullable = false)
|
||||
public MetaNoAuthProbeStatus getStatus() {
|
||||
return status;
|
||||
@JoinColumn(name = "META_NOAUTH_PROBE_STATUS_ID", nullable = false)
|
||||
public MetaNoAuthProbeStatus getMetaNoAuthProbeStatus() {
|
||||
return metaNoAuthProbeStatus;
|
||||
}
|
||||
|
||||
public void setStatus(MetaNoAuthProbeStatus status) {
|
||||
this.status = status;
|
||||
public void setMetaNoAuthProbeStatus(MetaNoAuthProbeStatus metaNoAuthProbeStatus) {
|
||||
this.metaNoAuthProbeStatus = metaNoAuthProbeStatus;
|
||||
}
|
||||
|
||||
@Column(name = "TEMP_PROBE_KEY", nullable = false, length = 50, unique = true)
|
||||
|
@ -83,7 +82,7 @@ public class NoAuthProbe {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "DOMAIN_ID", nullable=false)
|
||||
@JoinColumn(name = "DOMAIN_ID", nullable = false)
|
||||
public Domain getDomain() {
|
||||
return domain;
|
||||
}
|
||||
|
@ -121,39 +120,47 @@ public class NoAuthProbe {
|
|||
this.connectAddress = connectAddress;
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// NoAuthProbe that = (NoAuthProbe) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (domainId != that.domainId) return false;
|
||||
// if (hostName != null ? !hostName.equals(that.hostName) : that.hostName != null) return false;
|
||||
// if (macAddress != null ? !macAddress.equals(that.macAddress) : that.macAddress != null) return false;
|
||||
// if (ipAddress != null ? !ipAddress.equals(that.ipAddress) : that.ipAddress != null) return false;
|
||||
// if (status != null ? !status.equals(that.status) : that.status != null) return false;
|
||||
// if (tempProbeKey != null ? !tempProbeKey.equals(that.tempProbeKey) : that.tempProbeKey != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false;
|
||||
// if (apiKey != null ? !apiKey.equals(that.apiKey) : that.apiKey != null) return false;
|
||||
// if (probeId != null ? !probeId.equals(that.probeId) : that.probeId != null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (hostName != null ? hostName.hashCode() : 0);
|
||||
// result = 31 * result + (macAddress != null ? macAddress.hashCode() : 0);
|
||||
// result = 31 * result + (ipAddress != null ? ipAddress.hashCode() : 0);
|
||||
// result = 31 * result + (status != null ? status.hashCode() : 0);
|
||||
// result = 31 * result + (tempProbeKey != null ? tempProbeKey.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0);
|
||||
// result = 31 * result + (int) (domainId ^ (domainId >>> 32));
|
||||
// result = 31 * result + (probeId != null ? probeId.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// NoAuthProbe that = (NoAuthProbe) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (domainId != that.domainId) return false;
|
||||
// if (hostName != null ? !hostName.equals(that.hostName) : that.hostName !=
|
||||
// null) return false;
|
||||
// if (macAddress != null ? !macAddress.equals(that.macAddress) :
|
||||
// that.macAddress != null) return false;
|
||||
// if (ipAddress != null ? !ipAddress.equals(that.ipAddress) : that.ipAddress !=
|
||||
// null) return false;
|
||||
// if (status != null ? !status.equals(that.status) : that.status != null)
|
||||
// return false;
|
||||
// if (tempProbeKey != null ? !tempProbeKey.equals(that.tempProbeKey) :
|
||||
// that.tempProbeKey != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) :
|
||||
// that.createDate != null) return false;
|
||||
// if (apiKey != null ? !apiKey.equals(that.apiKey) : that.apiKey != null)
|
||||
// return false;
|
||||
// if (probeId != null ? !probeId.equals(that.probeId) : that.probeId != null)
|
||||
// return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (hostName != null ? hostName.hashCode() : 0);
|
||||
// result = 31 * result + (macAddress != null ? macAddress.hashCode() : 0);
|
||||
// result = 31 * result + (ipAddress != null ? ipAddress.hashCode() : 0);
|
||||
// result = 31 * result + (status != null ? status.hashCode() : 0);
|
||||
// result = 31 * result + (tempProbeKey != null ? tempProbeKey.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (apiKey != null ? apiKey.hashCode() : 0);
|
||||
// result = 31 * result + (int) (domainId ^ (domainId >>> 32));
|
||||
// result = 31 * result + (probeId != null ? probeId.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -6,24 +6,28 @@ package com.loafle.overflow.model.noauthprobe;
|
|||
public class NoAuthProbeDescription {
|
||||
private NoAuthProbeDescriptionHost host;
|
||||
private NoAuthProbeDescriptionNetwork network;
|
||||
|
||||
/**
|
||||
* @return the host
|
||||
*/
|
||||
public NoAuthProbeDescriptionHost getHost() {
|
||||
return host;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param host the host to set
|
||||
*/
|
||||
public void setHost(NoAuthProbeDescriptionHost host) {
|
||||
this.host = host;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the network
|
||||
*/
|
||||
public NoAuthProbeDescriptionNetwork getNetwork() {
|
||||
return network;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param network the network to set
|
||||
*/
|
||||
|
@ -31,5 +35,4 @@ public class NoAuthProbeDescription {
|
|||
this.network = network;
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -13,18 +13,21 @@ public class NoAuthProbeDescriptionHost {
|
|||
private String platformVersion;
|
||||
private String kernelVersion;
|
||||
private String hostID;
|
||||
|
||||
/**
|
||||
* @return the name
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param name the name to set
|
||||
*/
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the os
|
||||
*/
|
||||
|
@ -32,6 +35,7 @@ public class NoAuthProbeDescriptionHost {
|
|||
public String getOS() {
|
||||
return os;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param os the os to set
|
||||
*/
|
||||
|
@ -39,60 +43,70 @@ public class NoAuthProbeDescriptionHost {
|
|||
public void setOS(String os) {
|
||||
this.os = os;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the platform
|
||||
*/
|
||||
public String getPlatform() {
|
||||
return platform;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param platform the platform to set
|
||||
*/
|
||||
public void setPlatform(String platform) {
|
||||
this.platform = platform;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the platformFamily
|
||||
*/
|
||||
public String getPlatformFamily() {
|
||||
return platformFamily;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param platformFamily the platformFamily to set
|
||||
*/
|
||||
public void setPlatformFamily(String platformFamily) {
|
||||
this.platformFamily = platformFamily;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the platformVersion
|
||||
*/
|
||||
public String getPlatformVersion() {
|
||||
return platformVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param platformVersion the platformVersion to set
|
||||
*/
|
||||
public void setPlatformVersion(String platformVersion) {
|
||||
this.platformVersion = platformVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the kernelVersion
|
||||
*/
|
||||
public String getKernelVersion() {
|
||||
return kernelVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param kernelVersion the kernelVersion to set
|
||||
*/
|
||||
public void setKernelVersion(String kernelVersion) {
|
||||
this.kernelVersion = kernelVersion;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the hostID
|
||||
*/
|
||||
public String getHostID() {
|
||||
return hostID;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param hostID the hostID to set
|
||||
*/
|
||||
|
|
|
@ -8,48 +8,56 @@ public class NoAuthProbeDescriptionNetwork {
|
|||
private String address;
|
||||
private String gateway;
|
||||
private String macAddress;
|
||||
|
||||
/**
|
||||
* @return the name
|
||||
*/
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param name the name to set
|
||||
*/
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the address
|
||||
*/
|
||||
public String getAddress() {
|
||||
return address;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param address the address to set
|
||||
*/
|
||||
public void setAddress(String address) {
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the gateway
|
||||
*/
|
||||
public String getGateway() {
|
||||
return gateway;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param gateway the gateway to set
|
||||
*/
|
||||
public void setGateway(String gateway) {
|
||||
this.gateway = gateway;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the macAddress
|
||||
*/
|
||||
public String getMacAddress() {
|
||||
return macAddress;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param macAddress the macAddress to set
|
||||
*/
|
||||
|
@ -57,5 +65,4 @@ public class NoAuthProbeDescriptionNetwork {
|
|||
this.macAddress = macAddress;
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -20,7 +20,7 @@ public class Notification {
|
|||
private String url;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -77,7 +77,6 @@ public class Notification {
|
|||
this.confirmDate = confirmDate;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "URL", nullable = false, length = 255)
|
||||
public String getUrl() {
|
||||
return url;
|
||||
|
|
|
@ -4,7 +4,6 @@ import com.loafle.overflow.model.domain.Domain;
|
|||
import com.loafle.overflow.model.member.Member;
|
||||
import com.loafle.overflow.model.meta.MetaProbeStatus;
|
||||
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.util.Date;
|
||||
|
||||
|
@ -16,7 +15,7 @@ import java.util.Date;
|
|||
public class Probe {
|
||||
|
||||
private Long id;
|
||||
private MetaProbeStatus status;
|
||||
private MetaProbeStatus metaProbeStatus;
|
||||
private String description;
|
||||
private Date createDate;
|
||||
private Domain domain;
|
||||
|
@ -49,13 +48,13 @@ public class Probe {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "STATUS", nullable = false)
|
||||
public MetaProbeStatus getStatus() {
|
||||
return status;
|
||||
@JoinColumn(name = "META_PROBE_STATUS_ID", nullable = false)
|
||||
public MetaProbeStatus getMetaProbeStatus() {
|
||||
return metaProbeStatus;
|
||||
}
|
||||
|
||||
public void setStatus(MetaProbeStatus status) {
|
||||
this.status = status;
|
||||
public void setMetaProbeStatus(MetaProbeStatus metaProbeStatus) {
|
||||
this.metaProbeStatus = metaProbeStatus;
|
||||
}
|
||||
|
||||
@Column(name = "DESCRIPTION", nullable = true, length = 50)
|
||||
|
|
|
@ -17,7 +17,7 @@ public class ProbeHost {
|
|||
private InfraHost host;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.model.probe;
|
||||
|
||||
|
||||
import com.loafle.overflow.model.meta.MetaProbeTaskType;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
@ -13,7 +12,7 @@ import java.util.Date;
|
|||
@Table(name = "PROBE_TASK", schema = "public")
|
||||
public class ProbeTask {
|
||||
private Long id;
|
||||
private MetaProbeTaskType taskType;
|
||||
private MetaProbeTaskType metaProbeTaskType;
|
||||
private Probe probe;
|
||||
private String data;
|
||||
private Date createDate;
|
||||
|
@ -23,7 +22,7 @@ public class ProbeTask {
|
|||
private Boolean succeed;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -33,13 +32,13 @@ public class ProbeTask {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "TYPE_ID", nullable = false)
|
||||
public MetaProbeTaskType getTaskType() {
|
||||
return taskType;
|
||||
@JoinColumn(name = "META_PROBE_TASK_TYPE_ID", nullable = false)
|
||||
public MetaProbeTaskType getMetaProbeTaskType() {
|
||||
return metaProbeTaskType;
|
||||
}
|
||||
|
||||
public void setTaskType(MetaProbeTaskType taskType) {
|
||||
this.taskType = taskType;
|
||||
public void setMetaProbeTaskType(MetaProbeTaskType metaProbeTaskType) {
|
||||
this.metaProbeTaskType = metaProbeTaskType;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
|
@ -107,37 +106,42 @@ public class ProbeTask {
|
|||
this.succeed = succeed;
|
||||
}
|
||||
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// ProbeTask that = (ProbeTask) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (typeId != that.typeId) return false;
|
||||
// if (probeId != that.probeId) return false;
|
||||
// if (data != null ? !data.equals(that.data) : that.data != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) : that.createDate != null) return false;
|
||||
// if (sendDate != null ? !sendDate.equals(that.sendDate) : that.sendDate != null) return false;
|
||||
// if (startDate != null ? !startDate.equals(that.startDate) : that.startDate != null) return false;
|
||||
// if (endDate != null ? !endDate.equals(that.endDate) : that.endDate != null) return false;
|
||||
// if (succeed != null ? !succeed.equals(that.succeed) : that.succeed != null) return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (int) typeId;
|
||||
// result = 31 * result + (int) (probeId ^ (probeId >>> 32));
|
||||
// result = 31 * result + (data != null ? data.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (sendDate != null ? sendDate.hashCode() : 0);
|
||||
// result = 31 * result + (startDate != null ? startDate.hashCode() : 0);
|
||||
// result = 31 * result + (endDate != null ? endDate.hashCode() : 0);
|
||||
// result = 31 * result + (succeed != null ? succeed.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
// @Override
|
||||
// public boolean equals(Object o) {
|
||||
// if (this == o) return true;
|
||||
// if (o == null || getClass() != o.getClass()) return false;
|
||||
//
|
||||
// ProbeTask that = (ProbeTask) o;
|
||||
//
|
||||
// if (id != that.id) return false;
|
||||
// if (typeId != that.typeId) return false;
|
||||
// if (probeId != that.probeId) return false;
|
||||
// if (data != null ? !data.equals(that.data) : that.data != null) return false;
|
||||
// if (createDate != null ? !createDate.equals(that.createDate) :
|
||||
// that.createDate != null) return false;
|
||||
// if (sendDate != null ? !sendDate.equals(that.sendDate) : that.sendDate !=
|
||||
// null) return false;
|
||||
// if (startDate != null ? !startDate.equals(that.startDate) : that.startDate !=
|
||||
// null) return false;
|
||||
// if (endDate != null ? !endDate.equals(that.endDate) : that.endDate != null)
|
||||
// return false;
|
||||
// if (succeed != null ? !succeed.equals(that.succeed) : that.succeed != null)
|
||||
// return false;
|
||||
//
|
||||
// return true;
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public int hashCode() {
|
||||
// int result = (int) (id ^ (id >>> 32));
|
||||
// result = 31 * result + (int) typeId;
|
||||
// result = 31 * result + (int) (probeId ^ (probeId >>> 32));
|
||||
// result = 31 * result + (data != null ? data.hashCode() : 0);
|
||||
// result = 31 * result + (createDate != null ? createDate.hashCode() : 0);
|
||||
// result = 31 * result + (sendDate != null ? sendDate.hashCode() : 0);
|
||||
// result = 31 * result + (startDate != null ? startDate.hashCode() : 0);
|
||||
// result = 31 * result + (endDate != null ? endDate.hashCode() : 0);
|
||||
// result = 31 * result + (succeed != null ? succeed.hashCode() : 0);
|
||||
// return result;
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -20,9 +20,9 @@ public class Sensor {
|
|||
private Long id;
|
||||
private Date createDate;
|
||||
private String description;
|
||||
private MetaSensorStatus status;
|
||||
private MetaSensorStatus metaSensorStatus;
|
||||
private Target target;
|
||||
private MetaCrawler crawler;
|
||||
private MetaCrawler metaCrawler;
|
||||
private String crawlerInputItems;
|
||||
private Short itemCount = 0;
|
||||
private String displayName;
|
||||
|
@ -31,7 +31,7 @@ public class Sensor {
|
|||
private List<MetaSensorDisplayItem> sensorItems;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -60,13 +60,13 @@ public class Sensor {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "STATUS")
|
||||
public MetaSensorStatus getStatus() {
|
||||
return status;
|
||||
@JoinColumn(name = "META_SENSOR_STATUS_ID")
|
||||
public MetaSensorStatus getMetaSensorStatus() {
|
||||
return metaSensorStatus;
|
||||
}
|
||||
|
||||
public void setStatus(MetaSensorStatus status) {
|
||||
this.status = status;
|
||||
public void setMetaSensorStatus(MetaSensorStatus metaSensorStatus) {
|
||||
this.metaSensorStatus = metaSensorStatus;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
|
@ -81,13 +81,13 @@ public class Sensor {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getCrawler() {
|
||||
return crawler;
|
||||
@JoinColumn(name = "META_CRAWLER_ID", nullable = false)
|
||||
public MetaCrawler getMetaCrawler() {
|
||||
return metaCrawler;
|
||||
}
|
||||
|
||||
public void setCrawler(MetaCrawler crawler) {
|
||||
this.crawler = crawler;
|
||||
public void setMetaCrawler(MetaCrawler metaCrawler) {
|
||||
this.metaCrawler = metaCrawler;
|
||||
}
|
||||
|
||||
@Column(name = "CRAWLER_INPUT_ITEMS", nullable = true, length = 50)
|
||||
|
@ -131,5 +131,4 @@ public class Sensor {
|
|||
this.sensorItems = sensorItems;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -15,11 +15,11 @@ import java.util.Date;
|
|||
public class SensorItem {
|
||||
private Long id;
|
||||
private Sensor sensor;
|
||||
private MetaSensorDisplayItem item;
|
||||
private MetaSensorDisplayItem metaSensorDisplayItem;
|
||||
private Date createDate;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -40,13 +40,13 @@ public class SensorItem {
|
|||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getItem() {
|
||||
return item;
|
||||
@JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getMetaSensorDisplayItem() {
|
||||
return metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
public void setItem(MetaSensorDisplayItem item) {
|
||||
this.item = item;
|
||||
public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) {
|
||||
this.metaSensorDisplayItem = metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
@Temporal(TemporalType.TIMESTAMP)
|
||||
|
|
|
@ -12,11 +12,11 @@ import javax.persistence.*;
|
|||
@Table(name = "SENSOR_ITEM_DEPENDENCY", schema = "public")
|
||||
public class SensorItemDependency {
|
||||
private Long id;
|
||||
private MetaSensorDisplayItem displayItem;
|
||||
private MetaSensorItemKey sensorItem;
|
||||
private MetaSensorDisplayItem metaSensorDisplayItem;
|
||||
private MetaSensorItemKey metaSensorItemKey;
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -25,24 +25,23 @@ public class SensorItemDependency {
|
|||
this.id = id;
|
||||
}
|
||||
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "DISPLAY_ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getDisplayItem() {
|
||||
return displayItem;
|
||||
@JoinColumn(name = "META_SENSOR_DISPLAY_ITEM_ID", nullable = false)
|
||||
public MetaSensorDisplayItem getMetaSensorDisplayItem() {
|
||||
return metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
public void setDisplayItem(MetaSensorDisplayItem displayItem) {
|
||||
this.displayItem = displayItem;
|
||||
public void setMetaSensorDisplayItem(MetaSensorDisplayItem metaSensorDisplayItem) {
|
||||
this.metaSensorDisplayItem = metaSensorDisplayItem;
|
||||
}
|
||||
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "SENSOR_ITEM_ID", nullable = false)
|
||||
public MetaSensorItemKey getSensorItem() {
|
||||
return sensorItem;
|
||||
@JoinColumn(name = "META_SENSOR_ITEM_KEY_ID", nullable = false)
|
||||
public MetaSensorItemKey getMetaSensorItemKey() {
|
||||
return metaSensorItemKey;
|
||||
}
|
||||
|
||||
public void setSensorItem(MetaSensorItemKey sensorItem) {
|
||||
this.sensorItem = sensorItem;
|
||||
public void setMetaSensorItemKey(MetaSensorItemKey metaSensorItemKey) {
|
||||
this.metaSensorItemKey = metaSensorItemKey;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,9 +25,8 @@ public class Target {
|
|||
// Transient property
|
||||
private List<Sensor> sensors;
|
||||
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy= GenerationType.IDENTITY)
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
@ -64,7 +63,6 @@ public class Target {
|
|||
this.description = description;
|
||||
}
|
||||
|
||||
|
||||
@Column(name = "SENSOR_COUNT", nullable = false)
|
||||
public Integer getSensorCount() {
|
||||
return sensorCount;
|
||||
|
@ -101,27 +99,25 @@ public class Target {
|
|||
this.infra = infra;
|
||||
}
|
||||
|
||||
|
||||
// @ManyToOne
|
||||
// @JoinColumn(name = "PROBE_ID", nullable = false)
|
||||
// @OnDelete(action = OnDeleteAction.CASCADE)
|
||||
// public Probe getProbe() {
|
||||
// return probe;
|
||||
// }
|
||||
//
|
||||
// public void setProbe(Probe probe) {
|
||||
// this.probe = probe;
|
||||
// }
|
||||
//
|
||||
// @ManyToOne
|
||||
// @JoinColumn(name = "INFRA_ID", nullable = false)
|
||||
// public Infra getInfra() {
|
||||
// return infra;
|
||||
// }
|
||||
//
|
||||
// public void setInfra(Infra infra) {
|
||||
// this.infra = infra;
|
||||
// }
|
||||
|
||||
// @ManyToOne
|
||||
// @JoinColumn(name = "PROBE_ID", nullable = false)
|
||||
// @OnDelete(action = OnDeleteAction.CASCADE)
|
||||
// public Probe getProbe() {
|
||||
// return probe;
|
||||
// }
|
||||
//
|
||||
// public void setProbe(Probe probe) {
|
||||
// this.probe = probe;
|
||||
// }
|
||||
//
|
||||
// @ManyToOne
|
||||
// @JoinColumn(name = "INFRA_ID", nullable = false)
|
||||
// public Infra getInfra() {
|
||||
// return infra;
|
||||
// }
|
||||
//
|
||||
// public void setInfra(Infra infra) {
|
||||
// this.infra = infra;
|
||||
// }
|
||||
|
||||
}
|
||||
|
|
|
@ -10,9 +10,12 @@ import com.loafle.overflow.model.apikey.ApiKey;
|
|||
public interface ApiKeyService {
|
||||
@WebappAPI
|
||||
ApiKey regist(ApiKey apiKey) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
ApiKey readByDomainID(Long domainID) throws OverflowException;
|
||||
|
||||
boolean check(String apiKey) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
ApiKey readByApiKey(String apiKey) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -4,7 +4,6 @@ import com.loafle.overflow.model.auth.AuthCrawler;
|
|||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaCrawler;
|
||||
import com.loafle.overflow.model.target.Target;
|
||||
|
||||
/**
|
||||
* Created by geek on 17. 11. 7.
|
||||
|
@ -12,8 +11,10 @@ import com.loafle.overflow.model.target.Target;
|
|||
public interface AuthCrawlerService {
|
||||
@WebappAPI
|
||||
AuthCrawler regist(AuthCrawler authCrawler) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
boolean checkAuthCrawler(Long infraId, MetaCrawler crawler, String authJson) throws OverflowException;
|
||||
boolean checkAuthCrawler(Long infraId, MetaCrawler metaCrawler, String authJson) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
AuthCrawler readAuth(MetaCrawler metaCrawler, Target target) throws OverflowException;
|
||||
AuthCrawler readByMCrawlerIDAndTargetID(Short metaCrawlerID, Long targetID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -20,23 +20,34 @@ import com.loafle.overflow.model.discovery.Zone;
|
|||
public interface DiscoveryService {
|
||||
@WebappAPI
|
||||
void discoverZone(String probeID, DiscoverZone discoverZone) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void discoverHost(String probeID, Zone zone, DiscoverHost discoverHost) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void discoverPort(String probeID, Host host, DiscoverPort discoverPort) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void discoverService(String probeID, Port port, DiscoverService discoverService) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void stopDiscovery(String probeID) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveryStart(String requesterSessionID, Date startDate) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveryStop(String requesterSessionID, Date stopDate) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveredZone(String requesterSessionID, Zone zone) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveredHost(String requesterSessionID, Host host) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveredPort(String requesterSessionID, Port port) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void discoveredService(String requesterSessionID, Service service) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -14,10 +14,13 @@ import com.loafle.overflow.model.member.Member;
|
|||
public interface DomainMemberService {
|
||||
@WebappAPI
|
||||
void regist(DomainMember domainMember) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Domain readDomainByMemberID(Long memberID) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
DomainMember readByMemberEmail(String email) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<Member> readAllMemberByDomainID(final Long domainID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -11,11 +11,14 @@ public interface HistoryService {
|
|||
History regist(History history);
|
||||
|
||||
@WebappAPI
|
||||
Page<History> readAllByProbeIDAndType(Long probeID, MetaHistoryType type, PageParams pageParams);
|
||||
Page<History> readAllByProbeIDAndMetaHistoryTypeID(Long probeID, Integer metaHistoryTypeID, PageParams pageParams);
|
||||
|
||||
@WebappAPI
|
||||
Page<History> readAllByProbeID(Long probeID, PageParams pageParams);
|
||||
|
||||
@WebappAPI
|
||||
Page<History> readAllByDomainID(Long domainID, PageParams pageParams);
|
||||
|
||||
@WebappAPI
|
||||
Page<History> readAllByDomainIDAndType(Long domainID, MetaHistoryType type, PageParams pageParams);
|
||||
Page<History> readAllByDomainIDAndMetaHistoryTypeID(Long domainID, Integer metaHistoryTypeID, PageParams pageParams);
|
||||
}
|
||||
|
|
|
@ -9,6 +9,8 @@ import com.loafle.overflow.model.infra.InfraHost;
|
|||
|
||||
public interface InfraHostService {
|
||||
InfraHost regist(InfraHost infraHost) throws OverflowException;
|
||||
|
||||
InfraHost read(Long id) throws OverflowException;
|
||||
|
||||
InfraHost readByIp(String ip) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -8,5 +8,6 @@ import com.loafle.overflow.model.infra.InfraMachine;
|
|||
*/
|
||||
public interface InfraMachineService {
|
||||
InfraMachine regist(InfraMachine infraMachine) throws OverflowException;
|
||||
|
||||
InfraMachine read(Long id) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOSApplication;
|
|||
|
||||
public interface InfraOSApplicationService {
|
||||
InfraOSApplication regist(InfraOSApplication infraOSApplication) throws OverflowException;
|
||||
|
||||
InfraOSApplication read(Long id) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOSDaemon;
|
|||
|
||||
public interface InfraOSDaemonService {
|
||||
InfraOSDaemon regist(InfraOSDaemon infraOSDaemon) throws OverflowException;
|
||||
|
||||
InfraOSDaemon read(Long id) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -9,6 +9,8 @@ import com.loafle.overflow.model.infra.InfraOSPort;
|
|||
|
||||
public interface InfraOSPortService {
|
||||
InfraOSPort regist(InfraOSPort infraOSPort) throws OverflowException;
|
||||
|
||||
InfraOSPort read(Long id) throws OverflowException;
|
||||
InfraOSPort readByPort(Long osId, int portNumber, String portType) throws OverflowException;
|
||||
|
||||
InfraOSPort readByInfraOSIDAndPortAndPortType(Long infraOSID, Integer port, String portType) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -9,5 +9,6 @@ import com.loafle.overflow.model.infra.InfraOS;
|
|||
|
||||
public interface InfraOSService {
|
||||
InfraOS regist(InfraOS infraOS) throws OverflowException;
|
||||
|
||||
InfraOS read(Long id) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -16,10 +16,16 @@ import org.springframework.data.domain.Page;
|
|||
|
||||
public interface InfraService {
|
||||
Infra regist(Infra infra) throws OverflowException;
|
||||
|
||||
Infra read(Long id) throws OverflowException;
|
||||
|
||||
Page<Infra> readAllByProbeID(Long probeID, PageParams pageParams) throws OverflowException;
|
||||
|
||||
Page<Infra> readAllByDomainID(Long domainID, PageParams pageParams) throws OverflowException;
|
||||
|
||||
List<Target> readAllTargetByDomainID(Long domainID) throws OverflowException;
|
||||
List<Target> readAllTargetByProbeList(List<Probe> probeList) throws OverflowException;
|
||||
|
||||
List<Target> readAllTargetByProbes(List<Probe> probes) throws OverflowException;
|
||||
|
||||
Infra readByTargetID(Long targetID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -13,24 +13,34 @@ import java.util.List;
|
|||
public interface MemberService {
|
||||
@WebappAPI
|
||||
DomainMember signin(String signinId, String signinPw) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member signup(Member member, String pw) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member sendEmailForPassword(String email) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member resetPassword(String token, String pw) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member modify(Member member, String pw) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member forgotPassword(String signinId, String newPw) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Member read(Long memberId) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void withdrawal(Long memberId) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<Member> readAllByProbeKey(String probeKey) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<Member> readAllByApiKey(String apikey) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<Member> readAllByDomainID(final Long domainID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -12,16 +12,22 @@ import java.util.Map;
|
|||
public interface MemberTotpService {
|
||||
@WebappAPI
|
||||
void regist(Member member, String secretCode, String code) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MemberTotp modify(MemberTotp totp) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void remove(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MemberTotp read(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
boolean checkCodeForMember(Member member, String code) throws OverflowException;
|
||||
boolean checkCodeForMember(String email, String code) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
boolean checkCode(String secretCode, String code) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Map<String, String> createTotp(Member member) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaCrawler;
|
||||
import com.loafle.overflow.model.meta.MetaCrawlerInputItem;
|
||||
|
||||
import java.util.List;
|
||||
|
@ -13,5 +12,5 @@ import java.util.List;
|
|||
public interface MetaCrawlerInputItemService {
|
||||
|
||||
@WebappAPI
|
||||
List<MetaCrawlerInputItem> readAllByMetaCrawler(MetaCrawler metaCrawler) throws OverflowException;
|
||||
List<MetaCrawlerInputItem> readAllByMetaCrawlerID(Short metaCrawlerID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.loafle.overflow.service.central.meta;
|
||||
|
||||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaHistoryType;
|
||||
|
@ -16,9 +15,9 @@ public interface MetaHistoryTypeService {
|
|||
List<MetaHistoryType> readAll() throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MetaHistoryType regist(MetaHistoryType type) throws OverflowException;
|
||||
MetaHistoryType regist(MetaHistoryType metaHistoryType) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<MetaHistoryType> registAll(List<MetaHistoryType> types) throws OverflowException;
|
||||
List<MetaHistoryType> registAllByMetaHistoryTypes(List<MetaHistoryType> metaHistoryTypes) throws OverflowException;
|
||||
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaInfraType;
|
||||
import com.loafle.overflow.model.meta.MetaInfraVendor;
|
||||
|
||||
import java.util.List;
|
||||
|
@ -12,5 +11,5 @@ import java.util.List;
|
|||
*/
|
||||
public interface MetaInfraVendorService {
|
||||
@WebappAPI
|
||||
List<MetaInfraVendor> readAllByMetaInfraType(MetaInfraType infraType) throws OverflowException;
|
||||
List<MetaInfraVendor> readAllByMetaInfraTypeID(Integer metaInfraTypeID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -12,5 +12,5 @@ import java.util.List;
|
|||
*/
|
||||
public interface MetaProbePackageService {
|
||||
@WebappAPI
|
||||
List<MetaProbePackage> readAllByOs(MetaProbeOs metaProbeOs) throws OverflowException;
|
||||
List<MetaProbePackage> readAllByMetaProbeOs(MetaProbeOs metaProbeOs) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaCrawler;
|
||||
import com.loafle.overflow.model.meta.MetaSensorDisplayItem;
|
||||
|
||||
import java.util.List;
|
||||
|
@ -13,11 +12,11 @@ import java.util.List;
|
|||
|
||||
public interface MetaSensorDisplayItemService {
|
||||
@WebappAPI
|
||||
MetaSensorDisplayItem regist(MetaSensorDisplayItem item) throws OverflowException;
|
||||
MetaSensorDisplayItem regist(MetaSensorDisplayItem metaSensorDisplayItem) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MetaSensorDisplayItem read(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<MetaSensorDisplayItem> readAllByCrawler(MetaCrawler crawler) throws OverflowException;
|
||||
List<MetaSensorDisplayItem> readAllByCrawlerID(Short metaCrawlerID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaSensorDisplayItem;
|
||||
import com.loafle.overflow.model.meta.MetaSensorDisplayMapping;
|
||||
import com.loafle.overflow.model.meta.MetaSensorItemKey;
|
||||
|
||||
|
@ -13,8 +12,8 @@ import java.util.List;
|
|||
*/
|
||||
public interface MetaSensorDisplayMappingService {
|
||||
@WebappAPI
|
||||
MetaSensorDisplayMapping regist(MetaSensorDisplayMapping m) throws OverflowException;
|
||||
MetaSensorDisplayMapping regist(MetaSensorDisplayMapping metaSensorDisplayMapping) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<MetaSensorItemKey> readAllMetaSensorItemKeyByDisplayItem(MetaSensorDisplayItem displayItem) throws OverflowException;
|
||||
List<MetaSensorItemKey> readAllMetaSensorItemKeyByDisplayItemID(Long metaSensorDisplayItemID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaCrawler;
|
||||
import com.loafle.overflow.model.meta.MetaSensorItemKey;
|
||||
|
||||
import java.util.List;
|
||||
|
@ -13,8 +12,8 @@ import java.util.Map;
|
|||
*/
|
||||
public interface MetaSensorItemKeyService {
|
||||
@WebappAPI
|
||||
List<MetaSensorItemKey> readAllByCrawler(MetaCrawler metaCrawler) throws OverflowException;
|
||||
List<MetaSensorItemKey> readAllByMetaCrawlerID(Short metaCrawlerID) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Map<Integer, MetaSensorItemKey> readAllMapByCrawler(MetaCrawler metaCrawler) throws OverflowException;
|
||||
Map<Integer, MetaSensorItemKey> readAllMapByMetaCrawlerID(Short metaCrawlerID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -14,9 +14,9 @@ public interface MetaSensorItemTypeService {
|
|||
List<MetaSensorItemType> readAll() throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MetaSensorItemType regist(MetaSensorItemType type) throws OverflowException;
|
||||
MetaSensorItemType regist(MetaSensorItemType metaSensorItemType) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<MetaSensorItemType> registAll(List<MetaSensorItemType> list) throws OverflowException;
|
||||
List<MetaSensorItemType> registAll(List<MetaSensorItemType> metaSensorItemTypes) throws OverflowException;
|
||||
|
||||
}
|
||||
|
|
|
@ -10,5 +10,5 @@ import com.loafle.overflow.model.meta.MetaSensorItemUnit;
|
|||
public interface MetaSensorItemUnitService {
|
||||
|
||||
@WebappAPI
|
||||
MetaSensorItemUnit regist(MetaSensorItemUnit sensorItemUnit) throws OverflowException;
|
||||
MetaSensorItemUnit regist(MetaSensorItemUnit metaSensorItemUnit) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@ package com.loafle.overflow.service.central.meta;
|
|||
|
||||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.model.meta.MetaInfraVendor;
|
||||
import com.loafle.overflow.model.meta.MetaVendorCrawler;
|
||||
|
||||
import java.util.List;
|
||||
|
@ -13,7 +12,7 @@ import java.util.List;
|
|||
public interface MetaVendorCrawlerService {
|
||||
|
||||
@WebappAPI
|
||||
List<MetaVendorCrawler> readAllByInfraVendor(MetaInfraVendor infraVendor) throws OverflowException;
|
||||
List<MetaVendorCrawler> readAllByMetaInfraVendorID(Integer metaInfraVendorID) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
MetaVendorCrawler regist(MetaVendorCrawler metaVendorCrawler) throws OverflowException;
|
||||
|
|
|
@ -13,17 +13,22 @@ import java.util.List;
|
|||
public interface NoAuthProbeService {
|
||||
@ProbeAPI
|
||||
NoAuthProbe regist(NoAuthProbe noAuthProbe) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
NoAuthProbe readByTempProbeKey(String tempKey) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void onConnect(String tempKey, String connectAddress) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void onDisconnect(String tempKey) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<NoAuthProbe> readAllByDomainID(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<NoAuthProbe> acceptNoAuthProbe(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<NoAuthProbe> denyNoauthProbe(Long id) throws OverflowException;
|
||||
|
||||
|
|
|
@ -6,22 +6,29 @@ import com.loafle.overflow.core.model.PageParams;
|
|||
import com.loafle.overflow.model.member.Member;
|
||||
import com.loafle.overflow.model.notification.Notification;
|
||||
import org.springframework.data.domain.Page;
|
||||
|
||||
/**
|
||||
* Created by insanity on 17. 8. 25.
|
||||
*/
|
||||
public interface NotificationService {
|
||||
@WebappAPI
|
||||
Notification regist(Notification notification) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Notification> readAllByMember(Member member, PageParams pageParams) throws OverflowException;
|
||||
Page<Notification> readAllByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Notification> readAllUnconfirmedByMember(Member member, PageParams pageParams) throws OverflowException;
|
||||
Page<Notification> readAllUnconfirmedByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
int readUnconfirmedCount(Member member) throws OverflowException;
|
||||
int readUnconfirmedCountByMemberEmail(String memberEmail) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Notification> markAllAsRead(Member member, PageParams pageParams) throws OverflowException;
|
||||
Page<Notification> markAllAsReadByMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Notification> markAllAsUnread(Member member, PageParams pageParams) throws OverflowException;
|
||||
Page<Notification> markAllAsUnreadMemberEmail(String memberEmail, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Notification markAsRead(Notification notification) throws OverflowException;
|
||||
Notification markAsRead(Long notificationID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -11,7 +11,9 @@ import com.loafle.overflow.model.probe.ProbeHost;
|
|||
*/
|
||||
public interface ProbeHostService {
|
||||
ProbeHost read(Long id) throws OverflowException;
|
||||
|
||||
ProbeHost readByProbeID(Long probeID) throws OverflowException;
|
||||
|
||||
ProbeHost regist(ProbeHost probeHost) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
|
|
|
@ -13,23 +13,28 @@ import java.util.List;
|
|||
public interface ProbeService {
|
||||
// NoauthProbe.acceptNoAuthProbe
|
||||
Probe regist(Probe probe) throws OverflowException;
|
||||
|
||||
// NoauthProbe.acceptNoAuthProbe
|
||||
List<Probe> regist(List<Probe> probes) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<Probe> readAllByDomainID(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Probe read(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Probe modifyDisplayName(Long probeId, String displayName) throws OverflowException;
|
||||
|
||||
@ProbeAPI //?
|
||||
@ProbeAPI // ?
|
||||
Probe readByProbeKey(String probeKey) throws OverflowException;
|
||||
@ProbeAPI //?
|
||||
|
||||
@ProbeAPI // ?
|
||||
Probe modify(Probe probe) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void onConnect(String probeKey, String connectAddress) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void onDisconnect(String probeKey) throws OverflowException;
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@ import java.util.List;
|
|||
public interface ProbeTaskService {
|
||||
@ProbeAPI
|
||||
ProbeTask regist(ProbeTask probeTask) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
List<ProbeTask> readAllByProbeID(Long probeID) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -16,9 +16,12 @@ import java.util.Map;
|
|||
public interface SensorItemDependencyService {
|
||||
@WebappAPI
|
||||
SensorItemDependency regist(SensorItemDependency dependency) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
List<MetaSensorItemKey> readAllByDisplayItem(MetaSensorDisplayItem displayItem) throws OverflowException;
|
||||
List<MetaSensorItemKey> readAllMetaSensorItemKeyByMetaSensorDisplayItemID(Long metaSensorDisplayItemID) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Map<String, List<MetaSensorItemKey>> readAllByDisplayItems(List<MetaSensorDisplayItem> displayItems) throws OverflowException;
|
||||
Map<String, List<MetaSensorItemKey>> readAllMapByMetaSensorDisplayItems(List<MetaSensorDisplayItem> metaSensorDisplayItems)
|
||||
throws OverflowException;
|
||||
|
||||
}
|
||||
|
|
|
@ -3,7 +3,6 @@ package com.loafle.overflow.service.central.sensor;
|
|||
import com.loafle.overflow.core.annotation.WebappAPI;
|
||||
import com.loafle.overflow.core.exception.OverflowException;
|
||||
import com.loafle.overflow.core.model.PageParams;
|
||||
import com.loafle.overflow.model.sensor.Sensor;
|
||||
import com.loafle.overflow.model.sensor.SensorItem;
|
||||
import org.springframework.data.domain.Page;
|
||||
|
||||
|
@ -15,12 +14,16 @@ import java.util.List;
|
|||
public interface SensorItemService {
|
||||
@WebappAPI
|
||||
SensorItem regist(SensorItem sensorItem) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
boolean registAll(List<SensorItem> sensorItemList) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
SensorItem read(String id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<SensorItem> readAllBySensor(Sensor sensor, PageParams pageParams) throws OverflowException;
|
||||
Page<SensorItem> readAllBySensorID(Long sensorID, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void remove(SensorItem sensorItem) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -15,23 +15,31 @@ import java.util.List;
|
|||
public interface SensorService {
|
||||
@WebappAPI
|
||||
Sensor regist(Sensor sensor) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Sensor read(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void remove(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Sensor start(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Sensor stop(Long id) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Sensor registSensorConfig(Sensor sensor, List<SensorItem> sensorItemList, String etcJson) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
String generateSensorConfig(Sensor sensor) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Sensor> readAllByDomainID(Long domainID, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Sensor> readAllByInfraID(Long infraID, PageParams pageParams) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
Page<Sensor> readAllByTargetID(Long targetID, PageParams pageParams) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -11,13 +11,18 @@ import com.loafle.overflow.model.target.Target;
|
|||
public interface TargetService {
|
||||
|
||||
public Target regist(Target target, Probe probe) throws OverflowException;
|
||||
|
||||
public void remove(Target target, Probe probe) throws OverflowException;
|
||||
|
||||
public Target read(String id) throws OverflowException;
|
||||
|
||||
public Target increaseSensorCount(Target target) throws OverflowException;
|
||||
|
||||
public Target decreaseSensorCount(Target target) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
public Target modify(Target target) throws OverflowException;
|
||||
|
||||
@WebappAPI
|
||||
void remove(Target target) throws OverflowException;
|
||||
}
|
||||
|
|
|
@ -13,10 +13,13 @@ import com.loafle.overflow.model.sensorconfig.SensorConfig;
|
|||
public interface SensorConfigService extends Service {
|
||||
@ProbeAPI
|
||||
void InitConfig(List<SensorConfig> sensorConfigs) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void AddConfig(SensorConfig sensorConfig) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void UpdateConfig(SensorConfig sensorConfig) throws OverflowException;
|
||||
|
||||
@ProbeAPI
|
||||
void RemoveConfig(String configID) throws OverflowException;
|
||||
}
|
Loading…
Reference in New Issue
Block a user