You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by ysc751206 <yu...@g2.nctu.edu.tw> on 2018/07/02 18:13:27 UTC

Thin client doesn't support Expiry Policies.

Hi, 

We are currently using Ignite 2.1/C# in our application and considering to
use Ignite 2.5/C# because of thin client feature. But we notice that thin
client doesn't support to cache value with expiry policy. We use that
feature heavily in our application.

May I ask if you are going to support that in the near future or if there is
any workaround about this? 

Thanks

Edison



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by ysc751206 <yu...@g2.nctu.edu.tw>.
Thanks for opening the ticket.

Edison



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by Igor Sapego <is...@apache.org>.
I have not found any tickets for this feature, so there must be no current
plans to implement it from any community member.

However, I've created a ticket for this feature [1] so anyone may pick it up
now. Also, you can easily track this ticket now.

[1] - https://issues.apache.org/jira/browse/IGNITE-9033

Best Regards,
Igor


On Tue, Jul 17, 2018 at 10:58 PM ysc751206 <yu...@g2.nctu.edu.tw>
wrote:

> Thanks for the reply. Really appreciated.
>
> Based on our usage, it seems not practical to have different pre-configured
> expiry policy for each cache on server node. Because that means each time
> when we create a cache with new expiry policy then we need to update our
> server node.
>
> Do you know if thin client will support to get cache with expiry policy in
> the near future?
>
> Thanks,
> Edison
>
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Thin client doesn't support Expiry Policies.

Posted by ysc751206 <yu...@g2.nctu.edu.tw>.
Thanks for the reply. Really appreciated.

Based on our usage, it seems not practical to have different pre-configured
expiry policy for each cache on server node. Because that means each time
when we create a cache with new expiry policy then we need to update our
server node.

Do you know if thin client will support to get cache with expiry policy in
the near future?

Thanks,
Edison





--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by Igor Sapego <is...@apache.org>.
You should call  IIgniteClient.GetCache(cacheName) to get specific cache.
You can get multiple caches using single client.

Best Regards,
Igor


On Tue, Jul 17, 2018 at 7:51 PM ysc751206 <yu...@g2.nctu.edu.tw>
wrote:

> Yes, I know we can specify many caches with different expiryPolicyFactory
> on
> server node, but on thin client side, there is no way to specify which
> cache
> you want to use. All we have are host and port. Do you mean we need to use
> different host or port for each cache having different
> expiryPolicyFactory?
>
> If that is the case, then it will be quite inconvenient.
>
> Thanks,
> Edison
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Thin client doesn't support Expiry Policies.

Posted by ysc751206 <yu...@g2.nctu.edu.tw>.
Yes, I know we can specify many caches with different expiryPolicyFactory on
server node, but on thin client side, there is no way to specify which cache
you want to use. All we have are host and port. Do you mean we need to use
different host or port for each cache having different expiryPolicyFactory? 

If that is the case, then it will be quite inconvenient.

Thanks,
Edison



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by Igor Sapego <is...@apache.org>.
You should configure server nodes, not clients for that, if you use
C# servers, so see IgniteConfigurationSection.xsd for that. Using
it you can specify cache name and expiryPolicyFactory for any
cache.

Best Regards,
Igor


On Mon, Jul 16, 2018 at 10:37 PM ysc751206 <yu...@g2.nctu.edu.tw>
wrote:

> Does that mean we can only support one expiry policy? In our application,
> depending on the situation, some of cached object use absolute expiry
> policy
> but some of them may use sliding expiry policy. If it is possible to create
> many cache with different expiry policy, how to get them from thin client?
>
> Based on schema IgniteClientConfigurationSection.xsd, I am not sure how to
> specify which cache I want to use. There is no field to specify cache name.
>
> If there is no workaround to support different expiry policies, is there a
> plan to support it in the near feature?
>
> Thanks,
> Edison
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Thin client doesn't support Expiry Policies.

Posted by ysc751206 <yu...@g2.nctu.edu.tw>.
Does that mean we can only support one expiry policy? In our application,
depending on the situation, some of cached object use absolute expiry policy
but some of them may use sliding expiry policy. If it is possible to create
many cache with different expiry policy, how to get them from thin client?

Based on schema IgniteClientConfigurationSection.xsd, I am not sure how to
specify which cache I want to use. There is no field to specify cache name.

If there is no workaround to support different expiry policies, is there a
plan to support it in the near feature? 

Thanks,
Edison



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by Igor Sapego <is...@apache.org>.
You understand it correctly. Currently you can not dynamically start
cache from thin client with expiry policy. Still, you can configure
static cache with whatever expiry policy you want, using Spring Config
and then get it from the thin client. Would that do for you?

Best Regards,
Igor


On Thu, Jul 5, 2018 at 3:56 AM ysc751206 <yu...@g2.nctu.edu.tw>
wrote:

> For exampe, in Interface ICache<TK, TV>, there is method called
> WithExpiryPolicy(IExpiryPolicy) to create a cache with expiry policy. The
> cached object will be outdated based on the expiry policy.
>
> But for Interface ICache​Client<TK, TV>, there is no corresponding method.
> Please let me know if it is still not clear or I misunderstand something.
>
> Thanks,
> Edison
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: Thin client doesn't support Expiry Policies.

Posted by ysc751206 <yu...@g2.nctu.edu.tw>.
For exampe, in Interface ICache<TK, TV>, there is method called
WithExpiryPolicy(IExpiryPolicy) to create a cache with expiry policy. The
cached object will be outdated based on the expiry policy. 

But for Interface ICache​Client<TK, TV>, there is no corresponding method.
Please let me know if it is still not clear or I misunderstand something. 

Thanks,
Edison



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Thin client doesn't support Expiry Policies.

Posted by Igor Sapego <is...@apache.org>.
I'm not sure if I understand you, but expiry policy is a cache
configuration attribute and does not relate to client.

What do you need exactly? Do you want to be able to create
caches dynamically with expiry policy using thin client?

Best Regards,
Igor


On Mon, Jul 2, 2018 at 9:13 PM ysc751206 <yu...@g2.nctu.edu.tw>
wrote:

> Hi,
>
> We are currently using Ignite 2.1/C# in our application and considering to
> use Ignite 2.5/C# because of thin client feature. But we notice that thin
> client doesn't support to cache value with expiry policy. We use that
> feature heavily in our application.
>
> May I ask if you are going to support that in the near future or if there
> is
> any workaround about this?
>
> Thanks
>
> Edison
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>