On 7 Jan 2013, at 5:03 PM, Sanne Grinovero <sa...@hibernate.org> wrote:

> I've tried hard to find an agreement on this, but it seems we're
> wasting time without making progress.
> I'm not happy in ignoring a strong recommendation from any of you,
> very hard choice :-(

In the end it is your call. I tried to give arguments for my position, but we 
seem
to have general disagreement on how to develop/evolve an interface.

If you want to have a specific method for deletion I recommend:

String getShardIdentifierForAddition(Class<?> entityType, Serializable id, 
String idAsString, Document document);
String getShardIdentifierDeletion(Class<?> entityType, Serializable id, String 
idAsString);

So I would re-add the suffixes 'ForAddition' and 'ForDeletion'. Also I'd change 
the return type of
getShardIdentifierDeletion.

I test would be nice as well. Maybe if we see an actual example coded out we 
would have a better ground 
for discussion. 

Also, what are the concerns here? Performance, because I target all shards for 
deletion or security, aka
a deletion is send to a shard which potentially belongs to a different 
customer. 

What is the actual performance gain between the two different scenarios? A 
factor of 2, 4, 10?

> I'm inclined to add the method back, so that it's the users choice to pick 
> his battle.

A poor choice imo.

> Of course our template implementation could provide a sensible default
> method, so all users looking for simplicity don't need to bother too
> much about the extra method.

So now we use the abstract template class as an excuse to have a mediocre 
interface. If anything this
is a reason for me to dislike the template implementation even more.

--Hardy


_______________________________________________
hibernate-dev mailing list
hibernate-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/hibernate-dev

Reply via email to