Project

General

Profile

Story #8857

D1Client.getCN() always get the production cn on the CN Tomcat context

Added by Jing Tao over 1 year ago.

Status:
New
Priority:
Normal
Assignee:
Category:
dataone-cn-rest-service
Target version:
-
Start date:
2019-12-13
Due date:
% Done:

0%

Story Points:

Description

Today Val from ess-dive reported an issue that in the cn-stage environment, the rest call cn/v2/diag/subject didn't return any group information for a user even though the cn/v2/accounts call proves the user is in some groups.

After looking at the code, it seems suspicious that the cn/v2/diag/subject uses the method D1Client.getCN().getSubjectInfo(subject) to get the suer information. I guess it aways uses the production cn rather than the cn-stage. I put the property D1Client.CN_URL=https://cn-stage.test.dataone.org/cn on the file /var/lib/tomcat8/webapps/cn/WEB-INF/classes/org/dataone/configuration/portal.properties, then it works.

So we need to set up the property during our package building process.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 14.8 MB)