1 /*******************************************************************************
2 * Copyright 2016-2017 ZTE, Inc. and others.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 ******************************************************************************/
16 package org.onap.msb.apiroute.wrapper.dao.route.bean;
18 import org.onap.msb.apiroute.wrapper.dao.DAOConstants;
20 import lombok.AllArgsConstructor;
22 import lombok.NoArgsConstructor;
29 public class RouteInfo {
30 private String kind = DAOConstants.ROUTE_KIND;
31 private String apiVersion = "";
32 private String status = "";
33 private Metadata metadata;
43 "name" : "kubernetes",
44 "namespace" : "default",
45 "uid" : "0b6f198e-c6ab-11e6-86aa-fa163ee2118b",
46 "creationTimestamp" : "2016-12-20T11:54:21Z",
47 "updateTimestamp" : "",
49 "component" : "apiserver",
50 "provider" : "kubernetes"
62 "consulServiceName" : ""
63 "useOwnUpstream" : "" //是否使用该服务独立的upstream转发
64 "publishProtocol" : "", //发布地址使用http还是http协议
65 "enable_ssl" : "0|1", //转发时,使用http还是http转发。http:0/https:1
66 "controll" : "", //是否可以修改
78 public boolean equals(Object o) {
79 if (this == o) return true;
80 if (o == null || getClass() != o.getClass()) return false;
81 RouteInfo that = (RouteInfo) o;
82 return Objects.equals(kind, that.kind) &&
83 Objects.equals(apiVersion, that.apiVersion) &&
84 Objects.equals(status, that.status) &&
85 Objects.equals(metadata, that.metadata) &&
86 Objects.equals(spec, that.spec);
90 public int hashCode() {
91 return Objects.hash(kind, apiVersion, status, metadata, spec);