Thanks, it worked On Mon, Mar 9, 2015 at 4:58 PM, Shashika Karunatilaka <[email protected]> wrote:
> HI Chathura, > > If you start a tenant flow you can set the tenant Id and from that you can > get the tenant domain from below code > PrivilegedCarbonContext.getThreadLocalCarbonContext().setTenantId(tenantId, > true); > setTenantId with boolean argument it will resolve the tenant domain. or > else you can get from > PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantDomain(); > > To get the admin user name you can use realmConfig > > PrivilegedCarbonContext.getThreadLocalCarbonContext().getUserRealm().getRealmConfiguration().getAdminUserName() > > Thank you. > > On Mon, Mar 9, 2015 at 4:48 PM, Chathura Dilan <[email protected]> wrote: > >> Hi All, >> >> Is there a way to get the tenant domain name and the tenant admin >> username when tenantId is provided to >> PrivilegedCarbonContext.getThreadLocalCarbonContext()? >> >> >> Thanks >> >> -- >> Regards, >> >> Chatura Dilan Perera >> *(Senior Software Engineer** - WSO2 Inc.**)* >> www.dilan.me >> >> _______________________________________________ >> Dev mailing list >> [email protected] >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Shashika Prabath Karunatilaka, > Software Engineer, > WSO2, Inc: http://wso2.com/ > mobile : +94 77 7487792 > -- Regards, Chatura Dilan Perera *(Senior Software Engineer** - WSO2 Inc.**)* www.dilan.me
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
