Select to view content in your preferred language

Arcgis 11.1 SOI not return username for feature server

428
2
09-01-2023 05:57 AM
Dvirus
by
New Contributor III

Arcgis 11.1 SOI not return username for feature server

Hi,

 

var serverUtilities = ServerUtilities.GetServerEnvironment();
var username = serverUtilities .UserInfo.Name

 

username return null

 

I tried to

"disableCaching": "true",

even it's only affected on MapServer.

This bug occurs also in version 10.9.1 - fully patched.

 

 

0 Kudos
2 Replies
Amir-Sarrafzadeh-Arasi
Occasional Contributor
Dear Dvirus,
Please try this for getting the username,
 
IServerUserInfo userinfo = ServerUtilities.getServerUserInfo();
String user = userinfo.getName();
 
Amir Sarrafzadeh Arasi
Amir Sarrafzadeh Arasi
Amir-Sarrafzadeh-Arasi
Occasional Contributor

Hi Dvirus,

I solved the problem, it depends on your operation name, when you do not separate the operation names the request return null for the username,

Please double check your script and check the operation name in the first line of the SOI.

 

Hope it helps

Amir Sarrafzadeh Arasi
0 Kudos