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

Java based configuration #25

Open
GoogleCodeExporter opened this issue Nov 27, 2015 · 5 comments
Open

Java based configuration #25

GoogleCodeExporter opened this issue Nov 27, 2015 · 5 comments

Comments

@GoogleCodeExporter
Copy link

It would be nice to have java based configuration like 
"org.springframework.cache.annotation.EnableCaching". 

Original issue reported on code.google.com by [email protected] on 22 Jan 2014 at 1:22

@GoogleCodeExporter
Copy link
Author

Yes it will be a nice and useful feature. I'll will think how it can be 
implemented. Do you have an idea what exactly should be configured and how 
using java based configuration? My concern is how to distinguish between 
spymemcached and xmemcached providers without merging everything to one module. 

Original comment by [email protected] on 23 Jan 2014 at 7:31

@GoogleCodeExporter
Copy link
Author

I am not familiar with your library very much but there are good example about 
this java configuration. For example, you can look at Spring Security Project. 
They have extensive java configuration support. If you need some more help, I 
would give a try a basic example.  

Yesterday I tried to use your library for a hello world cache example and It 
was working nice. Here is the gist for the configuration: 
https://gist.github.com/cemo/45f3988825aa752872a9  

Original comment by [email protected] on 23 Jan 2014 at 9:10

@GoogleCodeExporter
Copy link
Author

Thanks! So basically java based configuration works for SSM, right? The only 
thing that I should get rid of is the required import statement: <import 
resource="simplesm-context.xml" /> then SSM can be configured using java. Am I 
right or miss something?
Can I use your example in documentation?


Original comment by [email protected] on 24 Jan 2014 at 9:03

@GoogleCodeExporter
Copy link
Author

Yes, this is a very basic working example for Spring annotations. But there is 
a MemcacheConfiguration which is our internal class. It must be changed to 
according to needs. Of course you can use this but as I said it needs to be a 
little bid polished.

Also simplesm-context.xml can be provided with @ImportResource(value = 
"simplesm-context.xml"). A hybrid solution will also work nicely. 

But your libary has great potential with java configuration more than this. 
Java configuration can reveal hidden gems easily. I will try to provide a 
comprehensive configuration after learning your library.  

I think that a maven javaconfig module might be added as spring-security 
project. Spring-security had such a module then It was merged with core module. 
 But I need some time to learn your library before giving a try.  :)      

Original comment by [email protected] on 24 Jan 2014 at 9:32

@GoogleCodeExporter
Copy link
Author

This issue has been moved to github: 
https://github.com/ragnor/simple-spring-memcached/issues/25

Original comment by [email protected] on 24 Feb 2014 at 5:50

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant