Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Afkham Azeez
On Wed, Sep 5, 2012 at 12:15 PM, Harshana Martin  wrote:

> Hi Shankar,
>
> On Wed, Sep 5, 2012 at 9:48 AM, Selvaratnam Uthaiyashankar <
> shan...@wso2.com> wrote:
>
>>
>>
>> On Wed, Sep 5, 2012 at 9:46 AM, Harshana Martin wrote:
>>
>>> Hi Shankar,
>>>
>>> On Sep 5, 2012 8:44 AM, "Selvaratnam Uthaiyashankar" 
>>> wrote:
>>> >
>>> >
>>> >
>>> > On Wed, Sep 5, 2012 at 8:26 AM, Harshana Martin 
>>> wrote:
>>> >>
>>> >> Hi Shankar,
>>> >>
>>> >> On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar <
>>> shan...@wso2.com> wrote:
>>> >>>
>>> >>> I didn't understand your requirements fully. Why do you need the
>>> tenant Id? Normally, you logged in using correct tenant username, and
>>> internally it will handle it. We do not need to handle this at the dev
>>> studio level. Can you explain what kind of operations you are trying to do?
>>> >>
>>> >>
>>> >> Previously we deployed C-App to a common location of
>>> repository/deployment/server/carbonapps location. But now servers running
>>> in tenant mode, deploying the C-App to super tenant is wrong IMO.
>>> >>
>>> >> If an user adds a Remote Server to Developer Studio, user provide the
>>> server URL. So that URL is now contains tenant domiain. Therefore we need
>>> the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
>>> Server now.
>>> >>
>>> >> Therefore now we need the Tenant Id at the Dev Studio side.
>>> >
>>> >
>>> > No, IMO, user gives the server URL as
>>> https://appserver.stratoslive.wso2.com  and user name as f...@bar.com
>>> >
>>> > Even previously, we used to do that, and developer studio uses (AFAIK)
>>> CApp uploader admin service by passing above username. In that case, it
>>> will be deployed to correct tenant. Developer studio will not be able to
>>> copy the file to a location in file system. If you calculate that path and
>>> copy, now that logic is in two places (dev studio and CApp uploader admin
>>> service). I believe, you should use the admin service only.
>>>
>>> Yes. This is correct for remote servers. The problem occurs for local
>>> servers.
>>>
>>> For local servers we use the file system for this operation but not the
>>> admin service. In rhat casr we have it.
>>>
>>> But for local severs also we can use the admin service. But it will
>>> slowdown the deployment a bit.
>>>
>>
>> But, isn't it clean? The logic should be only in one place for
>> maintainability, IMO :).
>>
>
> True. I agree!!
>
> It's clean and maintainable but it adds an extra couple of seconds
> overhead to Car deployment :-).
>

That is fine since the maintenance advantage outweighs the couple of extra
seconds. The CAR deployer can independently choose where it deploys
artifacts from.


>
> Anyway I'll use the C-App uploading Admin service instead of writing new
> admin service to expose the Tenant Id.
>
> Thanks and Regards,
> Harshana
>
>>
>> Shankar
>>
>>
>>
>>> Thanks and Regards,
>>> Harahana
>>>
>>> >
>>> > Shankar
>>> >
>>> >
>>> >>
>>> >>
>>> >> Thanks and Regards,
>>> >> Harshana
>>> >>>
>>> >>>
>>> >>> Shankar
>>> >>>
>>> >>>
>>> >>> On Tuesday, September 4, 2012, Harshana Martin wrote:
>>> 
>>>  Hi All,
>>> 
>>>  Can someone explain $Subject?
>>> 
>>>  We need to get the Tenant Id for C-App deployment to Servers from
>>> Dev Studio. Now that servers running in Service mode, C-App deployment also
>>> has to be tenant specific. Therefore we need this.
>>> 
>>>  Is there any existing Admin Service we can reuse? If yes, can
>>> someone point it to me?
>>> 
>>>  Thanks and Regards,
>>>  Harshana
>>>  --
>>>  Harshana Martin
>>>  Senior Software Engineer
>>>  Member, Management Committee - Development Technologies
>>>  WSO2 Inc. : http://wso2.com ; http://wso2.org
>>>  Mobile: +94 775 998 115
>>>  Profile: https://www.google.com/profiles/harshana05
>>>  Blog: http://harshana05.blogspot.com
>>>  Twitter: http://twitter.com/harshana05
>>> 
>>> 
>>> >>>
>>> >>>
>>> >>> --
>>> >>> S.Uthaiyashankar
>>> >>> Director, Cloud Solutions
>>> >>> WSO2 Inc.
>>> >>> http://wso2.com/ - "lean . enterprise . middleware"
>>> >>>
>>> >>> Phone: +94 714897591
>>> >>
>>> >>
>>> >>
>>> >>
>>> >> --
>>> >> Harshana Martin
>>> >> Senior Software Engineer
>>> >> Member, Management Committee - Development Technologies
>>> >> WSO2 Inc. : http://wso2.com ; http://wso2.org
>>> >> Mobile: +94 775 998 115
>>> >> Profile: https://www.google.com/profiles/harshana05
>>> >> Blog: http://harshana05.blogspot.com
>>> >> Twitter: http://twitter.com/harshana05
>>> >>
>>> >>
>>> >
>>> >
>>> >
>>> > --
>>> > S.Uthaiyashankar
>>> > Director, Cloud Solutions
>>> > WSO2 Inc.
>>> > http://wso2.com/ - "lean . enterprise . middleware"
>>> >
>>> > Phone: +94 714897591
>>>
>>>
>>
>>
>> --
>> S.Uthaiyashankar
>> Director, Cloud Solutions
>> WSO2 Inc.
>> http://wso2.com/ - "lean . enterprise . middleware"
>>
>> Phone: +94 714897591
>>
>
>
>
> --
> Harshana Martin
> Senior Software Engineer
> Memb

Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi Shankar,

On Wed, Sep 5, 2012 at 9:48 AM, Selvaratnam Uthaiyashankar  wrote:

>
>
> On Wed, Sep 5, 2012 at 9:46 AM, Harshana Martin  wrote:
>
>> Hi Shankar,
>>
>> On Sep 5, 2012 8:44 AM, "Selvaratnam Uthaiyashankar" 
>> wrote:
>> >
>> >
>> >
>> > On Wed, Sep 5, 2012 at 8:26 AM, Harshana Martin 
>> wrote:
>> >>
>> >> Hi Shankar,
>> >>
>> >> On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar <
>> shan...@wso2.com> wrote:
>> >>>
>> >>> I didn't understand your requirements fully. Why do you need the
>> tenant Id? Normally, you logged in using correct tenant username, and
>> internally it will handle it. We do not need to handle this at the dev
>> studio level. Can you explain what kind of operations you are trying to do?
>> >>
>> >>
>> >> Previously we deployed C-App to a common location of
>> repository/deployment/server/carbonapps location. But now servers running
>> in tenant mode, deploying the C-App to super tenant is wrong IMO.
>> >>
>> >> If an user adds a Remote Server to Developer Studio, user provide the
>> server URL. So that URL is now contains tenant domiain. Therefore we need
>> the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
>> Server now.
>> >>
>> >> Therefore now we need the Tenant Id at the Dev Studio side.
>> >
>> >
>> > No, IMO, user gives the server URL as
>> https://appserver.stratoslive.wso2.com  and user name as f...@bar.com
>> >
>> > Even previously, we used to do that, and developer studio uses (AFAIK)
>> CApp uploader admin service by passing above username. In that case, it
>> will be deployed to correct tenant. Developer studio will not be able to
>> copy the file to a location in file system. If you calculate that path and
>> copy, now that logic is in two places (dev studio and CApp uploader admin
>> service). I believe, you should use the admin service only.
>>
>> Yes. This is correct for remote servers. The problem occurs for local
>> servers.
>>
>> For local servers we use the file system for this operation but not the
>> admin service. In rhat casr we have it.
>>
>> But for local severs also we can use the admin service. But it will
>> slowdown the deployment a bit.
>>
>
> But, isn't it clean? The logic should be only in one place for
> maintainability, IMO :).
>

True. I agree!!

It's clean and maintainable but it adds an extra couple of seconds overhead
to Car deployment :-).

Anyway I'll use the C-App uploading Admin service instead of writing new
admin service to expose the Tenant Id.

Thanks and Regards,
Harshana

>
> Shankar
>
>
>
>> Thanks and Regards,
>> Harahana
>>
>> >
>> > Shankar
>> >
>> >
>> >>
>> >>
>> >> Thanks and Regards,
>> >> Harshana
>> >>>
>> >>>
>> >>> Shankar
>> >>>
>> >>>
>> >>> On Tuesday, September 4, 2012, Harshana Martin wrote:
>> 
>>  Hi All,
>> 
>>  Can someone explain $Subject?
>> 
>>  We need to get the Tenant Id for C-App deployment to Servers from
>> Dev Studio. Now that servers running in Service mode, C-App deployment also
>> has to be tenant specific. Therefore we need this.
>> 
>>  Is there any existing Admin Service we can reuse? If yes, can
>> someone point it to me?
>> 
>>  Thanks and Regards,
>>  Harshana
>>  --
>>  Harshana Martin
>>  Senior Software Engineer
>>  Member, Management Committee - Development Technologies
>>  WSO2 Inc. : http://wso2.com ; http://wso2.org
>>  Mobile: +94 775 998 115
>>  Profile: https://www.google.com/profiles/harshana05
>>  Blog: http://harshana05.blogspot.com
>>  Twitter: http://twitter.com/harshana05
>> 
>> 
>> >>>
>> >>>
>> >>> --
>> >>> S.Uthaiyashankar
>> >>> Director, Cloud Solutions
>> >>> WSO2 Inc.
>> >>> http://wso2.com/ - "lean . enterprise . middleware"
>> >>>
>> >>> Phone: +94 714897591
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >> Harshana Martin
>> >> Senior Software Engineer
>> >> Member, Management Committee - Development Technologies
>> >> WSO2 Inc. : http://wso2.com ; http://wso2.org
>> >> Mobile: +94 775 998 115
>> >> Profile: https://www.google.com/profiles/harshana05
>> >> Blog: http://harshana05.blogspot.com
>> >> Twitter: http://twitter.com/harshana05
>> >>
>> >>
>> >
>> >
>> >
>> > --
>> > S.Uthaiyashankar
>> > Director, Cloud Solutions
>> > WSO2 Inc.
>> > http://wso2.com/ - "lean . enterprise . middleware"
>> >
>> > Phone: +94 714897591
>>
>>
>
>
> --
> S.Uthaiyashankar
> Director, Cloud Solutions
> WSO2 Inc.
> http://wso2.com/ - "lean . enterprise . middleware"
>
> Phone: +94 714897591
>



-- 
Harshana Martin
Senior Software Engineer
Member, Management Committee - Development Technologies
WSO2 Inc. : http://wso2.com ; http://wso2.org
Mobile: +94 775 998 115
Profile: https://www.google.com/profiles/harshana05
Blog: http://harshana05.blogspot.com
Twitter: http://twitter.com/harshana05
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Selvaratnam Uthaiyashankar
On Wed, Sep 5, 2012 at 9:46 AM, Harshana Martin  wrote:

> Hi Shankar,
>
> On Sep 5, 2012 8:44 AM, "Selvaratnam Uthaiyashankar" 
> wrote:
> >
> >
> >
> > On Wed, Sep 5, 2012 at 8:26 AM, Harshana Martin 
> wrote:
> >>
> >> Hi Shankar,
> >>
> >> On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar <
> shan...@wso2.com> wrote:
> >>>
> >>> I didn't understand your requirements fully. Why do you need the
> tenant Id? Normally, you logged in using correct tenant username, and
> internally it will handle it. We do not need to handle this at the dev
> studio level. Can you explain what kind of operations you are trying to do?
> >>
> >>
> >> Previously we deployed C-App to a common location of
> repository/deployment/server/carbonapps location. But now servers running
> in tenant mode, deploying the C-App to super tenant is wrong IMO.
> >>
> >> If an user adds a Remote Server to Developer Studio, user provide the
> server URL. So that URL is now contains tenant domiain. Therefore we need
> the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
> Server now.
> >>
> >> Therefore now we need the Tenant Id at the Dev Studio side.
> >
> >
> > No, IMO, user gives the server URL as
> https://appserver.stratoslive.wso2.com  and user name as f...@bar.com
> >
> > Even previously, we used to do that, and developer studio uses (AFAIK)
> CApp uploader admin service by passing above username. In that case, it
> will be deployed to correct tenant. Developer studio will not be able to
> copy the file to a location in file system. If you calculate that path and
> copy, now that logic is in two places (dev studio and CApp uploader admin
> service). I believe, you should use the admin service only.
>
> Yes. This is correct for remote servers. The problem occurs for local
> servers.
>
> For local servers we use the file system for this operation but not the
> admin service. In rhat casr we have it.
>
> But for local severs also we can use the admin service. But it will
> slowdown the deployment a bit.
>

But, isn't it clean? The logic should be only in one place for
maintainability, IMO :).

Shankar



> Thanks and Regards,
> Harahana
>
> >
> > Shankar
> >
> >
> >>
> >>
> >> Thanks and Regards,
> >> Harshana
> >>>
> >>>
> >>> Shankar
> >>>
> >>>
> >>> On Tuesday, September 4, 2012, Harshana Martin wrote:
> 
>  Hi All,
> 
>  Can someone explain $Subject?
> 
>  We need to get the Tenant Id for C-App deployment to Servers from Dev
> Studio. Now that servers running in Service mode, C-App deployment also has
> to be tenant specific. Therefore we need this.
> 
>  Is there any existing Admin Service we can reuse? If yes, can someone
> point it to me?
> 
>  Thanks and Regards,
>  Harshana
>  --
>  Harshana Martin
>  Senior Software Engineer
>  Member, Management Committee - Development Technologies
>  WSO2 Inc. : http://wso2.com ; http://wso2.org
>  Mobile: +94 775 998 115
>  Profile: https://www.google.com/profiles/harshana05
>  Blog: http://harshana05.blogspot.com
>  Twitter: http://twitter.com/harshana05
> 
> 
> >>>
> >>>
> >>> --
> >>> S.Uthaiyashankar
> >>> Director, Cloud Solutions
> >>> WSO2 Inc.
> >>> http://wso2.com/ - "lean . enterprise . middleware"
> >>>
> >>> Phone: +94 714897591
> >>
> >>
> >>
> >>
> >> --
> >> Harshana Martin
> >> Senior Software Engineer
> >> Member, Management Committee - Development Technologies
> >> WSO2 Inc. : http://wso2.com ; http://wso2.org
> >> Mobile: +94 775 998 115
> >> Profile: https://www.google.com/profiles/harshana05
> >> Blog: http://harshana05.blogspot.com
> >> Twitter: http://twitter.com/harshana05
> >>
> >>
> >
> >
> >
> > --
> > S.Uthaiyashankar
> > Director, Cloud Solutions
> > WSO2 Inc.
> > http://wso2.com/ - "lean . enterprise . middleware"
> >
> > Phone: +94 714897591
>
>


-- 
S.Uthaiyashankar
Director, Cloud Solutions
WSO2 Inc.
http://wso2.com/ - "lean . enterprise . middleware"

Phone: +94 714897591
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi Shankar,
On Sep 5, 2012 8:44 AM, "Selvaratnam Uthaiyashankar" 
wrote:
>
>
>
> On Wed, Sep 5, 2012 at 8:26 AM, Harshana Martin  wrote:
>>
>> Hi Shankar,
>>
>> On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar <
shan...@wso2.com> wrote:
>>>
>>> I didn't understand your requirements fully. Why do you need the tenant
Id? Normally, you logged in using correct tenant username, and internally
it will handle it. We do not need to handle this at the dev studio level.
Can you explain what kind of operations you are trying to do?
>>
>>
>> Previously we deployed C-App to a common location of
repository/deployment/server/carbonapps location. But now servers running
in tenant mode, deploying the C-App to super tenant is wrong IMO.
>>
>> If an user adds a Remote Server to Developer Studio, user provide the
server URL. So that URL is now contains tenant domiain. Therefore we need
the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
Server now.
>>
>> Therefore now we need the Tenant Id at the Dev Studio side.
>
>
> No, IMO, user gives the server URL as
https://appserver.stratoslive.wso2.com  and user name as f...@bar.com
>
> Even previously, we used to do that, and developer studio uses (AFAIK)
CApp uploader admin service by passing above username. In that case, it
will be deployed to correct tenant. Developer studio will not be able to
copy the file to a location in file system. If you calculate that path and
copy, now that logic is in two places (dev studio and CApp uploader admin
service). I believe, you should use the admin service only.

Yes. This is correct for remote servers. The problem occurs for local
servers.

For local servers we use the file system for this operation but not the
admin service. In rhat casr we have it.

But for local severs also we can use the admin service. But it will
slowdown the deployment a bit.

Thanks and Regards,
Harahana
>
> Shankar
>
>
>>
>>
>> Thanks and Regards,
>> Harshana
>>>
>>>
>>> Shankar
>>>
>>>
>>> On Tuesday, September 4, 2012, Harshana Martin wrote:

 Hi All,

 Can someone explain $Subject?

 We need to get the Tenant Id for C-App deployment to Servers from Dev
Studio. Now that servers running in Service mode, C-App deployment also has
to be tenant specific. Therefore we need this.

 Is there any existing Admin Service we can reuse? If yes, can someone
point it to me?

 Thanks and Regards,
 Harshana
 --
 Harshana Martin
 Senior Software Engineer
 Member, Management Committee - Development Technologies
 WSO2 Inc. : http://wso2.com ; http://wso2.org
 Mobile: +94 775 998 115
 Profile: https://www.google.com/profiles/harshana05
 Blog: http://harshana05.blogspot.com
 Twitter: http://twitter.com/harshana05


>>>
>>>
>>> --
>>> S.Uthaiyashankar
>>> Director, Cloud Solutions
>>> WSO2 Inc.
>>> http://wso2.com/ - "lean . enterprise . middleware"
>>>
>>> Phone: +94 714897591
>>
>>
>>
>>
>> --
>> Harshana Martin
>> Senior Software Engineer
>> Member, Management Committee - Development Technologies
>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>> Mobile: +94 775 998 115
>> Profile: https://www.google.com/profiles/harshana05
>> Blog: http://harshana05.blogspot.com
>> Twitter: http://twitter.com/harshana05
>>
>>
>
>
>
> --
> S.Uthaiyashankar
> Director, Cloud Solutions
> WSO2 Inc.
> http://wso2.com/ - "lean . enterprise . middleware"
>
> Phone: +94 714897591
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Selvaratnam Uthaiyashankar
On Wed, Sep 5, 2012 at 8:26 AM, Harshana Martin  wrote:

> Hi Shankar,
>
> On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar <
> shan...@wso2.com> wrote:
>
>> I didn't understand your requirements fully. Why do you need the tenant
>> Id? Normally, you logged in using correct tenant username, and internally
>> it will handle it. We do not need to handle this at the dev studio level.
>> Can you explain what kind of operations you are trying to do?
>
>
> Previously we deployed C-App to a common location of
> repository/deployment/server/carbonapps location. But now servers running
> in tenant mode, deploying the C-App to super tenant is wrong IMO.
>
> If an user adds a Remote Server to Developer Studio, user provide the
> server URL. So that URL is now contains tenant domiain. Therefore we need
> the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
> Server now.
>
> Therefore now we need the Tenant Id at the Dev Studio side.
>

No, IMO, user gives the server URL as https://appserver.stratoslive.wso2.com
and user name as f...@bar.com

Even previously, we used to do that, and developer studio uses (AFAIK) CApp
uploader admin service by passing above username. In that case, it will be
deployed to correct tenant. Developer studio will not be able to copy the
file to a location in file system. If you calculate that path and copy, now
that logic is in two places (dev studio and CApp uploader admin service). I
believe, you should use the admin service only.

Shankar



>
> Thanks and Regards,
> Harshana
>
>>
>> Shankar
>>
>>
>> On Tuesday, September 4, 2012, Harshana Martin wrote:
>>
>>> Hi All,
>>>
>>> Can someone explain $Subject?
>>>
>>> We need to get the Tenant Id for C-App deployment to Servers from Dev
>>> Studio. Now that servers running in Service mode, C-App deployment also has
>>> to be tenant specific. Therefore we need this.
>>>
>>> Is there any existing Admin Service we can reuse? If yes, can someone
>>> point it to me?
>>>
>>> Thanks and Regards,
>>> Harshana
>>> --
>>> Harshana Martin
>>> Senior Software Engineer
>>> Member, Management Committee - Development Technologies
>>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>>> Mobile: +94 775 998 115
>>> Profile: https://www.google.com/profiles/harshana05
>>> Blog: http://harshana05.blogspot.com
>>> Twitter: http://twitter.com/harshana05
>>>
>>>
>>>
>>
>> --
>> S.Uthaiyashankar
>> Director, Cloud Solutions
>> WSO2 Inc.
>> http://wso2.com/ - "lean . enterprise . middleware"
>>
>> Phone: +94 714897591
>>
>
>
>
> --
> Harshana Martin
> Senior Software Engineer
> Member, Management Committee - Development Technologies
> WSO2 Inc. : http://wso2.com ; http://wso2.org
> Mobile: +94 775 998 115
> Profile: https://www.google.com/profiles/harshana05
> Blog: http://harshana05.blogspot.com
> Twitter: http://twitter.com/harshana05
>
>
>


-- 
S.Uthaiyashankar
Director, Cloud Solutions
WSO2 Inc.
http://wso2.com/ - "lean . enterprise . middleware"

Phone: +94 714897591
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi Shankar,

On Wed, Sep 5, 2012 at 7:41 AM, Selvaratnam Uthaiyashankar  wrote:

> I didn't understand your requirements fully. Why do you need the tenant
> Id? Normally, you logged in using correct tenant username, and internally
> it will handle it. We do not need to handle this at the dev studio level.
> Can you explain what kind of operations you are trying to do?


Previously we deployed C-App to a common location of
repository/deployment/server/carbonapps location. But now servers running
in tenant mode, deploying the C-App to super tenant is wrong IMO.

If an user adds a Remote Server to Developer Studio, user provide the
server URL. So that URL is now contains tenant domiain. Therefore we need
the Tenant Id corresponding to Tenant Domain to deploy the C-App to remote
Server now.

Therefore now we need the Tenant Id at the Dev Studio side.

Thanks and Regards,
Harshana

>
> Shankar
>
>
> On Tuesday, September 4, 2012, Harshana Martin wrote:
>
>> Hi All,
>>
>> Can someone explain $Subject?
>>
>> We need to get the Tenant Id for C-App deployment to Servers from Dev
>> Studio. Now that servers running in Service mode, C-App deployment also has
>> to be tenant specific. Therefore we need this.
>>
>> Is there any existing Admin Service we can reuse? If yes, can someone
>> point it to me?
>>
>> Thanks and Regards,
>> Harshana
>> --
>> Harshana Martin
>> Senior Software Engineer
>> Member, Management Committee - Development Technologies
>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>> Mobile: +94 775 998 115
>> Profile: https://www.google.com/profiles/harshana05
>> Blog: http://harshana05.blogspot.com
>> Twitter: http://twitter.com/harshana05
>>
>>
>>
>
> --
> S.Uthaiyashankar
> Director, Cloud Solutions
> WSO2 Inc.
> http://wso2.com/ - "lean . enterprise . middleware"
>
> Phone: +94 714897591
>



-- 
Harshana Martin
Senior Software Engineer
Member, Management Committee - Development Technologies
WSO2 Inc. : http://wso2.com ; http://wso2.org
Mobile: +94 775 998 115
Profile: https://www.google.com/profiles/harshana05
Blog: http://harshana05.blogspot.com
Twitter: http://twitter.com/harshana05
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Selvaratnam Uthaiyashankar
I didn't understand your requirements fully. Why do you need the tenant Id?
Normally, you logged in using correct tenant username, and internally it
will handle it. We do not need to handle this at the dev studio level. Can
you explain what kind of operations you are trying to do?

Shankar

On Tuesday, September 4, 2012, Harshana Martin wrote:

> Hi All,
>
> Can someone explain $Subject?
>
> We need to get the Tenant Id for C-App deployment to Servers from Dev
> Studio. Now that servers running in Service mode, C-App deployment also has
> to be tenant specific. Therefore we need this.
>
> Is there any existing Admin Service we can reuse? If yes, can someone
> point it to me?
>
> Thanks and Regards,
> Harshana
> --
> Harshana Martin
> Senior Software Engineer
> Member, Management Committee - Development Technologies
> WSO2 Inc. : http://wso2.com ; http://wso2.org
> Mobile: +94 775 998 115
> Profile: https://www.google.com/profiles/harshana05
> Blog: http://harshana05.blogspot.com
> Twitter: http://twitter.com/harshana05
>
>
>

-- 
S.Uthaiyashankar
Director, Cloud Solutions
WSO2 Inc.
http://wso2.com/ - "lean . enterprise . middleware"

Phone: +94 714897591
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi Sanjeewa,
On Sep 5, 2012 12:36 AM, "Sanjeewa Malalgoda"  wrote:
>
> Hi,
> How if we obtain super tenant carbon context and then get TenantManager.
> if you have tenant manager then you can do same.

Is there a way to get the super tenants carbon context outside of a carbon
server?

We need to get it outside of server since we need this information to be
accessible to Dev Studio.

Thanks and Regards,
Harshana
>
> Thanks.
>
>
> On Tue, Sep 4, 2012 at 11:54 AM, Ajith Vitharana  wrote:
>>
>>
>>
>> On Tue, Sep 4, 2012 at 11:53 PM, Harshana Martin 
wrote:
>>>
>>> Hi All,
>>>
>>> Can someone explain $Subject?
>>>
>>> We need to get the Tenant Id for C-App deployment to Servers from Dev
Studio. Now that servers running in Service mode, C-App deployment also has
to be tenant specific. Therefore we need this.
>>>
>>> Is there any existing Admin Service we can reuse? If yes, can someone
point it to me?
>>
>>
>> Hi Harshana,
>>
>> AFAIK We don't expose (to outside ) tenant id using such a Admin Service.
>> However, you can get the tenant id using the  RealmService (OSGI
service).
>>
>> int tenantId = realmService.getTenantManager().getTenantId(tenantDomain);
>>
>> Thanks
>> Ajithn
>>
>>>
>>>
>>> Thanks and Regards,
>>> Harshana
>>> --
>>> Harshana Martin
>>> Senior Software Engineer
>>> Member, Management Committee - Development Technologies
>>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>>> Mobile: +94 775 998 115
>>> Profile: https://www.google.com/profiles/harshana05
>>> Blog: http://harshana05.blogspot.com
>>> Twitter: http://twitter.com/harshana05
>>>
>>>
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>
>>
>>
>> --
>> Ajith Vitharana.
>> WSO2 Inc. - http://wso2.org
>> Email  :  aji...@wso2.com
>> Mobile : +94714631794
>>
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>
>
>
> --
> Sanjeewa Malalgoda
> WSO2 Inc.
> Mobile : +14084122715 | +94713068779
>
> blog :http://sanjeewamalalgoda.blogspot.com/
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi Ajith,
On Sep 5, 2012 12:24 AM, "Ajith Vitharana"  wrote:
>
>
>
> On Tue, Sep 4, 2012 at 11:53 PM, Harshana Martin 
wrote:
>>
>> Hi All,
>>
>> Can someone explain $Subject?
>>
>> We need to get the Tenant Id for C-App deployment to Servers from Dev
Studio. Now that servers running in Service mode, C-App deployment also has
to be tenant specific. Therefore we need this.
>>
>> Is there any existing Admin Service we can reuse? If yes, can someone
point it to me?
>
>
> Hi Harshana,
>
> AFAIK We don't expose (to outside ) tenant id using such a Admin Service.
> However, you can get the tenant id using the  RealmService (OSGI service).
>
> int tenantId = realmService.getTenantManager().getTenantId(tenantDomain);
>
> Thanks
> Ajithn

I'll try to implement an admin service with the above code segment and try
to use it from Dev Studio.

Thanks and Regards,
Harshana
>
>>
>>
>> Thanks and Regards,
>> Harshana
>> --
>> Harshana Martin
>> Senior Software Engineer
>> Member, Management Committee - Development Technologies
>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>> Mobile: +94 775 998 115
>> Profile: https://www.google.com/profiles/harshana05
>> Blog: http://harshana05.blogspot.com
>> Twitter: http://twitter.com/harshana05
>>
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>
>
>
> --
> Ajith Vitharana.
> WSO2 Inc. - http://wso2.org
> Email  :  aji...@wso2.com
> Mobile : +94714631794
>
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Sanjeewa Malalgoda
Hi,
How if we obtain super tenant carbon context and then get TenantManager.
if you have tenant manager then you can do same.

Thanks.

On Tue, Sep 4, 2012 at 11:54 AM, Ajith Vitharana  wrote:

>
>
> On Tue, Sep 4, 2012 at 11:53 PM, Harshana Martin wrote:
>
>> Hi All,
>>
>> Can someone explain $Subject?
>>
>> We need to get the Tenant Id for C-App deployment to Servers from Dev
>> Studio. Now that servers running in Service mode, C-App deployment also has
>> to be tenant specific. Therefore we need this.
>>
>> Is there any existing Admin Service we can reuse? If yes, can someone
>> point it to me?
>>
>
> Hi Harshana,
>
> AFAIK We don't expose (to outside ) tenant id using such a Admin Service.
> However, you can get the tenant id using the  RealmService (OSGI service).
>
> int tenantId = realmService.getTenantManager().getTenantId(tenantDomain);
>
> Thanks
> Ajithn
>
>
>>
>> Thanks and Regards,
>> Harshana
>> --
>> Harshana Martin
>> Senior Software Engineer
>> Member, Management Committee - Development Technologies
>> WSO2 Inc. : http://wso2.com ; http://wso2.org
>> Mobile: +94 775 998 115
>> Profile: https://www.google.com/profiles/harshana05
>> Blog: http://harshana05.blogspot.com
>> Twitter: http://twitter.com/harshana05
>>
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Ajith Vitharana.
> WSO2 Inc. - http://wso2.org
> Email  :  aji...@wso2.com
> Mobile : +94714631794
>
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Sanjeewa Malalgoda*
WSO2 Inc.
Mobile : +14084122715 | +94713068779

 blog
:http://sanjeewamalalgoda.blogspot.com/
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Ajith Vitharana
On Tue, Sep 4, 2012 at 11:53 PM, Harshana Martin  wrote:

> Hi All,
>
> Can someone explain $Subject?
>
> We need to get the Tenant Id for C-App deployment to Servers from Dev
> Studio. Now that servers running in Service mode, C-App deployment also has
> to be tenant specific. Therefore we need this.
>
> Is there any existing Admin Service we can reuse? If yes, can someone
> point it to me?
>

Hi Harshana,

AFAIK We don't expose (to outside ) tenant id using such a Admin Service.
However, you can get the tenant id using the  RealmService (OSGI service).

int tenantId = realmService.getTenantManager().getTenantId(tenantDomain);

Thanks
Ajithn


>
> Thanks and Regards,
> Harshana
> --
> Harshana Martin
> Senior Software Engineer
> Member, Management Committee - Development Technologies
> WSO2 Inc. : http://wso2.com ; http://wso2.org
> Mobile: +94 775 998 115
> Profile: https://www.google.com/profiles/harshana05
> Blog: http://harshana05.blogspot.com
> Twitter: http://twitter.com/harshana05
>
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Ajith Vitharana.
WSO2 Inc. - http://wso2.org
Email  :  aji...@wso2.com
Mobile : +94714631794
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] How to get the Tenant Id using Tenant Domain from an External Application

2012-09-04 Thread Harshana Martin
Hi All,

Can someone explain $Subject?

We need to get the Tenant Id for C-App deployment to Servers from Dev
Studio. Now that servers running in Service mode, C-App deployment also has
to be tenant specific. Therefore we need this.

Is there any existing Admin Service we can reuse? If yes, can someone point
it to me?

Thanks and Regards,
Harshana
-- 
Harshana Martin
Senior Software Engineer
Member, Management Committee - Development Technologies
WSO2 Inc. : http://wso2.com ; http://wso2.org
Mobile: +94 775 998 115
Profile: https://www.google.com/profiles/harshana05
Blog: http://harshana05.blogspot.com
Twitter: http://twitter.com/harshana05
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev