Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Access ICache's via separate ICacheManager available from HazelcastInstance #8434

Merged

Conversation

vbekiaris
Copy link
Contributor

@vbekiaris vbekiaris commented Jun 21, 2016

Access to ICache instances is now available via separate ICacheManager interface which is accessible from HazelcastInstance.getCacheManager.
Fixes #8352 .
An EE counterpart is required.
Also provides a new utility method CacheUtil.getDistributedObjectName (in a separate commit).

@devOpsHazelcast
Copy link
Collaborator

Test PASSed.

1 similar comment
@devOpsHazelcast
Copy link
Collaborator

Test PASSed.

* Hazelcast's {@link javax.cache.spi.CachingProvider#getDefaultClassLoader()})
* @return the name of the {@link ICache} distributed object corresponding to given arguments.
*/
public static String getDistributedObjectName(String cacheName, URI uri, ClassLoader classLoader) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor comment: Since generally URI and ClassLoader parameters are null, it might be good if we support also String getDistributedObjectName(String cacheName) version of this method.

@serkan-ozal
Copy link
Contributor

👍 minor comment

*
* @see ICacheManager
*/
public class HazelcastClientInstanceCacheManager implements ICacheManager {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need the Hazelcast prefix? Why not call it ClientICacheManager?

…returned by HazelcastInstance.getCacheManager()
@vbekiaris vbekiaris force-pushed the fixes/master/get-cache-indirectly branch from 8120a2b to bfd2037 Compare June 22, 2016 12:35
@vbekiaris
Copy link
Contributor Author

Thanks @serkan-ozal & @pveentjer for the quick review. Your comments have been addressed; with regards to class naming, since there are already a few *CacheManagers in the codebase, I prepended the ICacheManager implementations with HazelcastInstance/HazelcastClientInstance name to demonstrate the relationship (you get the ICacheManager from the related HazelcastInstance), however obviously this led to a huge unwieldy class name, so I adopted @pveentjer's proposed name.

@pveentjer
Copy link
Contributor

👍 once green

@devOpsHazelcast
Copy link
Collaborator

Test PASSed.

@vbekiaris vbekiaris merged commit eca7cec into hazelcast:master Jun 22, 2016
@vbekiaris vbekiaris deleted the fixes/master/get-cache-indirectly branch June 22, 2016 13:22
@mmedenjak mmedenjak added the Source: Internal PR or issue was opened by an employee label Apr 13, 2020
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

NoClassDefFoundError: javax/cache/Cache when mocking HazelcastInstance with 3.7
5 participants