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

ClassNotFound in CacheProviderImpl when using 3.12 #1

Closed
bpaskin-ibm opened this issue Dec 27, 2018 · 9 comments
Closed

ClassNotFound in CacheProviderImpl when using 3.12 #1

bpaskin-ibm opened this issue Dec 27, 2018 · 9 comments
Milestone

Comments

@bpaskin-ibm
Copy link

bpaskin-ibm commented Dec 27, 2018

When pulling down the latest Hazelcast bundle and compiling some of the classes of been changed or removed. The 'CacheProviderImpl' class imports com.hazelcast.client.osgi.HazelcastClientOSGiService, but that would seem to have been moved to com.hazelcast.osgi.HazelcastOSGiService or removed. Updating the class to reflect this causes another issue with the configuration:
Incompatible types: com.hazelcast.client.config.ClientConfig cannot be converted to com.hazelcast.config.Config on the line hazelcastClientInstance = hazelcastClientOSGIService.newHazelcastInstance(config);'

I have not looked into the config issue yet, but I suspect it is not the exact same or has changed.

Brian

@emre-aydin
Copy link
Contributor

@bpaskin-ibm I had added the HazelcastClientOSGiService in my own fork here: https://github.com/emre-aydin/hazelcast/tree/bundle

You would need to build from that branch to make it work. IIRC it was not working fully and also note that it is for an old version of Hazelcast (3.8).

@bpaskin-ibm
Copy link
Author

Hi, thanks for the info. I am receiving an error on the mvn build. It would seem that the Hazelcast-client-protocol 1.3 snapshot is missing from the sonatype.

[ERROR] Failed to execute goal on project hazelcast: Could not resolve dependencies for project com.hazelcast:hazelcast:jar:3.8-BUNDLE: Could not find artifact com.hazelcast:hazelcast-client-protocol:jar:1.3.0-SNAPSHOT in snapshot-repository (https://oss.sonatype.org/content/repositories/snapshots) -> [Help 1]

Thanks, Brian

@emre-aydin
Copy link
Contributor

I guess you could try client protocol version 1.3.0, I don't remember I have needed any changes to the client protocol for it to work.

@bpaskin-ibm
Copy link
Author

Hi, I am just running maven with the POM provided. I did try others and it fails in various parts.

@mesutcelik
Copy link
Contributor

Hi @bpaskin-ibm ,
We implemented the integration almost 2 years ago and did not touch it at all since then. I think we need to revisit it and update it to work with 3.12.

Just out of curiosity, what is your use case with hazelcast-dynacache integration and where do you plan to use it?

@bpaskin-ibm
Copy link
Author

Hi, a customer is moving from tWAS to Liberty and was using the distributed Object Cache in tWAS, which is not available in Liberty. They do not want to change their code, so they were looking for a way to do it with a third party library. This is were Hazelcast comes in with this feature. I don't know the statistics of usage, but it is an important app for the customer.

Thanks Brian

@mesutcelik
Copy link
Contributor

Thanks for the info. We will be looking into the issue.

Can we talk about this in detail on a call or in email? I would like to understand the details of the integration.
My email address is mesut at hazelcast dot com

@alparslanavci
Copy link

@bpaskin-ibm; as a workaround, you can use the .esa file in the latest release directly to connect to 3.11 cluster. It is working as expected, since it contains Hazelcast 3.8 client which can work with 3.11 clusters. You can find this file here: hazelcast-dynacache-0.2.esa Please install it to your Liberty installation as a feature, and then it will be available for using.

The issue with the bundle branch is that it uses hazelcast-client-protocol version 1.3-SNAPSHOT and it is not compatible any of the stable releases. The branch should be merged to a recent version, such as 3.11.

@googlielmo
Copy link
Contributor

Fixed by #2, where HazelcastClientOSGiService was moved to this module and dependencies were updated.

@degerhz degerhz added this to the 0.3 milestone Mar 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants