Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
discovery
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
谢捷峰
discovery
Commits
649c18f8
Commit
649c18f8
authored
Jul 22, 2018
by
Nepxion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
重构类结构
parent
ed132fe2
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
21 deletions
+2
-21
discovery-console/src/main/java/com/nepxion/discovery/console/entity/ResultEntity.java
+0
-9
discovery-console/src/main/java/com/nepxion/discovery/console/rest/AbstractRestInvoker.java
+0
-2
discovery-springcloud-example-console/pom.xml
+2
-10
No files found.
discovery-console/src/main/java/com/nepxion/discovery/console/entity/ResultEntity.java
View file @
649c18f8
...
@@ -19,18 +19,9 @@ import org.apache.commons.lang3.builder.ToStringStyle;
...
@@ -19,18 +19,9 @@ import org.apache.commons.lang3.builder.ToStringStyle;
public
class
ResultEntity
implements
Serializable
{
public
class
ResultEntity
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
3322655604556025836L
;
private
static
final
long
serialVersionUID
=
-
3322655604556025836L
;
private
String
serviceId
;
private
String
url
;
private
String
url
;
private
String
result
;
private
String
result
;
public
String
getServiceId
()
{
return
serviceId
;
}
public
void
setServiceId
(
String
serviceId
)
{
this
.
serviceId
=
serviceId
;
}
public
String
getUrl
()
{
public
String
getUrl
()
{
return
url
;
return
url
;
}
}
...
...
discovery-console/src/main/java/com/nepxion/discovery/console/rest/AbstractRestInvoker.java
View file @
649c18f8
...
@@ -46,7 +46,6 @@ public abstract class AbstractRestInvoker {
...
@@ -46,7 +46,6 @@ public abstract class AbstractRestInvoker {
List
<
ResultEntity
>
resultEntityList
=
new
ArrayList
<
ResultEntity
>();
List
<
ResultEntity
>
resultEntityList
=
new
ArrayList
<
ResultEntity
>();
for
(
ServiceInstance
serviceInstance
:
serviceInstances
)
{
for
(
ServiceInstance
serviceInstance
:
serviceInstances
)
{
String
serviceId
=
serviceInstance
.
getServiceId
().
toLowerCase
();
String
host
=
serviceInstance
.
getHost
();
String
host
=
serviceInstance
.
getHost
();
int
port
=
serviceInstance
.
getPort
();
int
port
=
serviceInstance
.
getPort
();
String
url
=
getUrl
(
host
,
port
);
String
url
=
getUrl
(
host
,
port
);
...
@@ -65,7 +64,6 @@ public abstract class AbstractRestInvoker {
...
@@ -65,7 +64,6 @@ public abstract class AbstractRestInvoker {
}
}
ResultEntity
resultEntity
=
new
ResultEntity
();
ResultEntity
resultEntity
=
new
ResultEntity
();
resultEntity
.
setServiceId
(
serviceId
);
resultEntity
.
setUrl
(
url
);
resultEntity
.
setUrl
(
url
);
resultEntity
.
setResult
(
result
);
resultEntity
.
setResult
(
result
);
...
...
discovery-springcloud-example-console/pom.xml
View file @
649c18f8
...
@@ -51,17 +51,9 @@
...
@@ -51,17 +51,9 @@
<dependency>
<dependency>
<groupId>
org.springframework.cloud
</groupId>
<groupId>
org.springframework.cloud
</groupId>
<artifactId>
spring-cloud-starter-netflix-eureka-client
</artifactId>
<artifactId>
spring-cloud-starter-netflix-eureka-client
</artifactId>
<!-- <artifactId>spring-cloud-starter-consul-discovery</artifactId> -->
<!-- <artifactId>spring-cloud-starter-zookeeper-discovery</artifactId> -->
</dependency>
</dependency>
<!-- <dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-consul-discovery</artifactId>
</dependency> -->
<!-- <dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-zookeeper-discovery</artifactId>
</dependency> -->
</dependencies>
</dependencies>
<build>
<build>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment