BusinessLog.java 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. package com.yihu.hos.models;
  2. import org.springframework.data.annotation.Id;
  3. import org.springframework.data.mongodb.core.index.Indexed;
  4. import org.springframework.data.mongodb.core.mapping.Document;
  5. import java.util.Date;
  6. /**
  7. * @created Airhead 2016/8/8.
  8. */
  9. @Document(collection = "businessLog")
  10. public class BusinessLog {
  11. @Id
  12. private String id;
  13. @Indexed
  14. private String exchangeId;
  15. private String correlationId;
  16. private String transactionKey;
  17. @Indexed
  18. private String routeId;
  19. @Indexed
  20. private String breadcrumbId;
  21. private Integer totalServers;
  22. private String serverName;
  23. private String camelContextId;
  24. private String body;
  25. private Integer bodyLength;
  26. private String fireTimeSource;
  27. //@Indexed(name = "fireTime_1", expireAfterSeconds = 30)
  28. @Indexed
  29. private Date fireTime; //后期建议转成TTL
  30. public String getId() {
  31. return id;
  32. }
  33. public void setId(String id) {
  34. this.id = id;
  35. }
  36. public String getExchangeId() {
  37. return exchangeId;
  38. }
  39. public void setExchangeId(String exchangeId) {
  40. this.exchangeId = exchangeId;
  41. }
  42. public String getCorrelationId() {
  43. return correlationId;
  44. }
  45. public void setCorrelationId(String correlationId) {
  46. this.correlationId = correlationId;
  47. }
  48. public String getTransactionKey() {
  49. return transactionKey;
  50. }
  51. public void setTransactionKey(String transactionKey) {
  52. this.transactionKey = transactionKey;
  53. }
  54. public String getRouteId() {
  55. return routeId;
  56. }
  57. public void setRouteId(String routeId) {
  58. this.routeId = routeId;
  59. }
  60. public String getBreadcrumbId() {
  61. return breadcrumbId;
  62. }
  63. public void setBreadcrumbId(String breadcrumbId) {
  64. this.breadcrumbId = breadcrumbId;
  65. }
  66. public String getCamelContextId() {
  67. return camelContextId;
  68. }
  69. public void setCamelContextId(String camelContextId) {
  70. this.camelContextId = camelContextId;
  71. }
  72. public String getBody() {
  73. return body;
  74. }
  75. public void setBody(String body) {
  76. this.body = body;
  77. }
  78. public Date getFireTime() {
  79. return fireTime;
  80. }
  81. public void setFireTime(Date fireTime) {
  82. this.fireTime = fireTime;
  83. }
  84. public Integer getBodyLength() {
  85. return bodyLength;
  86. }
  87. public void setBodyLength(Integer bodyLength) {
  88. this.bodyLength = bodyLength;
  89. }
  90. public String getFireTimeSource() {
  91. return fireTimeSource;
  92. }
  93. public void setFireTimeSource(String fireTimeSource) {
  94. this.fireTimeSource = fireTimeSource;
  95. }
  96. public Integer getTotalServers() {
  97. return totalServers;
  98. }
  99. public void setTotalServers(Integer totalServers) {
  100. this.totalServers = totalServers;
  101. }
  102. public String getServerName() {
  103. return serverName;
  104. }
  105. public void setServerName(String serverName) {
  106. this.serverName = serverName;
  107. }
  108. }