Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
neo4jRelation
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
qiuchaofei
neo4jRelation
Commits
9415f88c
Commit
9415f88c
authored
Jan 10, 2022
by
qiuchaofei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1按照环境 区分系统
parent
cd4ccaf6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
11 deletions
+24
-11
MetaDataController.java
...adata/metadataRelation/controller/MetaDataController.java
+2
-2
RelationalGraphController.java
...etadataRelation/controller/RelationalGraphController.java
+12
-4
IMetadataService.java
...e/metadata/metadataRelation/service/IMetadataService.java
+1
-2
MetadataServiceImpl.java
...ta/metadataRelation/service/impl/MetadataServiceImpl.java
+8
-2
TableServiceImpl.java
...adata/metadataRelation/service/impl/TableServiceImpl.java
+1
-1
No files found.
src/main/java/com/keymobile/metadata/metadataRelation/controller/MetaDataController.java
View file @
9415f88c
...
@@ -165,7 +165,7 @@ public class MetaDataController {
...
@@ -165,7 +165,7 @@ public class MetaDataController {
returnReslult
=
multiModelService
.
findResultByModelNameList
(
modelNameList
,
sizeInt
);
returnReslult
=
multiModelService
.
findResultByModelNameList
(
modelNameList
,
sizeInt
);
}
}
else
if
(
modelName0
.
toLowerCase
().
equals
(
"system"
)){
else
if
(
modelName0
.
toLowerCase
().
equals
(
"system"
)){
returnReslult
=
metadataService
.
getSystemGraph
(
sizeInt
);
returnReslult
=
metadataService
.
getSystemGraph
(
""
,
sizeInt
);
}
else
if
(
!
modelName0
.
toLowerCase
().
equals
(
"all"
)){
}
else
if
(
!
modelName0
.
toLowerCase
().
equals
(
"all"
)){
returnReslult
=
metadataService
.
findResultByModelName
(
modelName0
,
sizeInt
);
returnReslult
=
metadataService
.
findResultByModelName
(
modelName0
,
sizeInt
);
}
else
{
}
else
{
...
@@ -334,7 +334,7 @@ public class MetaDataController {
...
@@ -334,7 +334,7 @@ public class MetaDataController {
@RequestMapping
(
path
=
"/getSystemGraph"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
path
=
"/getSystemGraph"
,
method
=
RequestMethod
.
GET
)
public
ReturnReslult
getSystemGraph
(){
public
ReturnReslult
getSystemGraph
(){
int
size
=
300
;
int
size
=
300
;
return
metadataService
.
getSystemGraph
(
size
);
return
metadataService
.
getSystemGraph
(
""
,
size
);
}
}
...
...
src/main/java/com/keymobile/metadata/metadataRelation/controller/RelationalGraphController.java
View file @
9415f88c
...
@@ -75,13 +75,21 @@ public class RelationalGraphController {
...
@@ -75,13 +75,21 @@ public class RelationalGraphController {
//系统总图的接口
//系统总图的接口
@ApiOperation
(
tags
=
""
,
value
=
"系统总图"
)
@ApiOperation
(
tags
=
""
,
value
=
"
按照环境参数返回
系统总图"
)
@RequestMapping
(
path
=
"/getAllSystemGraph"
,
method
=
RequestMethod
.
GET
)
@RequestMapping
(
path
=
"/getAllSystemGraph"
,
method
=
RequestMethod
.
GET
)
public
ReturnReslult
getAllSystemGraph
(){
public
ReturnReslult
getAllSystemGraph
(
String
environment
){
int
size
=
300
;
int
size
=
300
;
return
metadataService
.
getSystemGraph
(
size
);
return
metadataService
.
getSystemGraph
(
environment
,
size
);
}
}
// //系统总图的接口
// @ApiOperation(tags = "", value = "按照环境参数返回系统总图")
// @RequestMapping(path = "/getAllSystemGraphByEnvironment", method = RequestMethod.GET)
// public ReturnReslult getAllSystemGraphByEnvironment(String environment){
// int size = 300;
// return metadataService.getSystemGraph(environment,size);
//
// }
//schema的分层,图的形式,由里到外,同上面的分层接口
//schema的分层,图的形式,由里到外,同上面的分层接口
//系统总图下钻获取schema,schema要分层
//系统总图下钻获取schema,schema要分层
@ApiOperation
(
tags
=
""
,
value
=
"按照系统获取schema,要分层"
)
@ApiOperation
(
tags
=
""
,
value
=
"按照系统获取schema,要分层"
)
...
...
src/main/java/com/keymobile/metadata/metadataRelation/service/IMetadataService.java
View file @
9415f88c
...
@@ -17,8 +17,7 @@ public interface IMetadataService {
...
@@ -17,8 +17,7 @@ public interface IMetadataService {
ReturnReslult
findResultByModelName
(
String
modelName
,
int
count
);
ReturnReslult
findResultByModelName
(
String
modelName
,
int
count
);
ReturnReslult
getSystemGraph
(
int
size
);
ReturnReslult
getSystemGraph
(
String
catalogName
,
int
size
);
ReturnReslult
searchGraph
(
String
metadataId
,
int
layer
);
ReturnReslult
searchGraph
(
String
metadataId
,
int
layer
);
List
<
MetaData
>
findChildrenByParentId
(
String
parentId
,
Integer
count
);
List
<
MetaData
>
findChildrenByParentId
(
String
parentId
,
Integer
count
);
...
...
src/main/java/com/keymobile/metadata/metadataRelation/service/impl/MetadataServiceImpl.java
View file @
9415f88c
...
@@ -370,7 +370,7 @@ public class MetadataServiceImpl implements IMetadataService {
...
@@ -370,7 +370,7 @@ public class MetadataServiceImpl implements IMetadataService {
}
}
@Override
@Override
public
ReturnReslult
getSystemGraph
(
int
size
)
{
public
ReturnReslult
getSystemGraph
(
String
catlogName
,
int
size
)
{
ReturnReslult
returnReslult
=
new
ReturnReslult
();
ReturnReslult
returnReslult
=
new
ReturnReslult
();
...
@@ -382,7 +382,13 @@ public class MetadataServiceImpl implements IMetadataService {
...
@@ -382,7 +382,13 @@ public class MetadataServiceImpl implements IMetadataService {
" union match data=(na:softplatform) return data "
+
" union match data=(na:softplatform) return data "
+
" union match data=(na:Neo4jSystem)<-[r]->(nb:Neo4jSystem) return data "
+
" union match data=(na:Neo4jSystem)<-[r]->(nb:Neo4jSystem) return data "
+
" union match data=(na:Neo4jSystem) return data "
;
" union match data=(na:Neo4jSystem) return data "
;
logger
.
info
(
"系统总图的查询语句:"
+
cypher
);
if
(
catlogName
!=
null
&&
!
catlogName
.
equals
(
""
)){
cypher
=
"match data=(na:softplatform)<-[r]->(nb:softplatform) return data "
+
" union match data=(na:softplatform) return data "
+
" union match data=(na:Neo4jSystem)<-[r]->(nb:Neo4jSystem) where na.metadataId=~'.*=\"+catlogName+\"=.*' return data "
+
" union match data=(na:Neo4jSystem) where na.metadataId=~'.*="
+
catlogName
+
"=.*' return data "
;
}
logger
.
info
(
"系统环境参数:"
+
catlogName
+
";系统总图的查询语句:"
+
cypher
);
long
starttime
=
System
.
currentTimeMillis
();
long
starttime
=
System
.
currentTimeMillis
();
StatementResult
result
=
session
.
run
(
cypher
);
StatementResult
result
=
session
.
run
(
cypher
);
...
...
src/main/java/com/keymobile/metadata/metadataRelation/service/impl/TableServiceImpl.java
View file @
9415f88c
...
@@ -120,11 +120,11 @@ public class TableServiceImpl implements ITableService {
...
@@ -120,11 +120,11 @@ public class TableServiceImpl implements ITableService {
returnNode
.
setCnName
(
cnName
);
returnNode
.
setCnName
(
cnName
);
standardList
.
add
(
returnNode
);
standardList
.
add
(
returnNode
);
}
}
relationObjects
.
put
(
"标准"
,
standardList
);
}
catch
(
Exception
e
){
}
catch
(
Exception
e
){
e
.
printStackTrace
();
e
.
printStackTrace
();
}
}
relationObjects
.
put
(
"标准"
,
standardList
);
long
start
=
System
.
currentTimeMillis
();
long
start
=
System
.
currentTimeMillis
();
List
<
ReturnNode
>
neo4jTableList
=
getCurrentTableInfo
(
tableId
);
List
<
ReturnNode
>
neo4jTableList
=
getCurrentTableInfo
(
tableId
);
...
...
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