Skip to content

Commit

Permalink
fix: avoid opening a session for tostring of the instance
Browse files Browse the repository at this point in the history
  • Loading branch information
tglman committed Jan 25, 2024
1 parent 51a998a commit d1de1b6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,16 @@ public void drop() {
factory.close();
}

@Override
public String toString() {
return OrientGraph.class.getSimpleName().toLowerCase()
+ "["
+ connectionURI
+ "/"
+ dbName
+ "]";
}

public boolean isOpen() {
return factory.isOpen();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,6 @@ public boolean isOpen() {

@Override
public String toString() {
return graph().toString();
return factory.toString();
}
}

0 comments on commit d1de1b6

Please sign in to comment.