I want to write a custom Trigger (base on CronTrigger) for scheduling my tasks.
In Spring's reference, it only contains the use of "task" namespace for XML-based configuration. However, task...
Type: Posts; User: adrianshum; Keyword(s):
I want to write a custom Trigger (base on CronTrigger) for scheduling my tasks.
In Spring's reference, it only contains the use of "task" namespace for XML-based configuration. However, task...
I didn't expect the transaction type can be the cause of problem, as Spring 3.1 provide the xml-less JPA bootstrapping, and, in my past project, I used to use LOCAL_RESOURCES transaction type in...
After some further trial-and-error, here is the actual problem:
1) I can move almost all settings from persistence.xml to Spring's config, leaving only the <persistence-unit name="foo"...
A "Good" news: Using persistence.xml, as what @Marten suggested, is working.
It seems that even I am having almost identical properties set directly on LocalContainerEntityManager vs in...
@Marten: May I know if you are declaring all your mapped class in persistence.xml explicitly? One of the reason for me not to use persistence.xml is the newly added packageToScan feature in...
Just a little update: I tried to inject EntityManager to my service by @PersistenceContext, and use JPA directly instead of going through Spring Data JPA. Same things happens: Unless I flush the...
I have also suspected that my @Transactional is not setup correctly. However when I am using the combination with CMTTransactionFactory as factory_class (i.e. cases with transaction active, but no...
I am wrong on what I have told:
Only certain combinations of properties in jpaPropertyMap give me "no-auto-flushing" behavior. Other combination simply tell me there is no transaction in progress...
I only extract out suspicious snippet to avoid having a huge xml that no one is going to read :) I am using annotation-driven tx. It seems working fine if I am manually flushing the entity manager...
(I am asking the same question at StackOverflow too:
http://stackoverflow.com/questions/12889462/auto-flush-not-working-for-spring-3-1-localentitymanagerfactorybean-hibernate )
I have did a lot...
Nothing special.
Will it be more constructive if you can tell us what problem you have faced?
good, lemme try the JNDI way out. One of the reasons that I am avoiding system properties is, more than one app may be deployed to one container. It will be much better if profile setting is...
Suddenly I guess I overlooked something.
Though I am yet to try it out, can someone verify if my understanding is correct?
This in fact means Spring will lookup from all mentioned Property...
Thanks Marten,
However, afaik, we are not supposed to pass system variable if we are running inside a JEE container. The appropriate way is to pass "variables" as JNDI entry, as we can never know...
I have an app that aims to deploy on 2 (or more) containers.
I want to try out Profile in Spring 3.1 to see if it can help to solve my problem, but am stucked.
I have a app ctx xml like this:
...
I am having a little POC project using both of them.
Thanks Marten,
I have got the result by combining what you said and the answer from StackOverflow (http://stackoverflow.com/a/11271644/395202):
1) yes I should use @RequestBody
2) I should...
(This question is posted on Stackoverflow too, http://stackoverflow.com/questions/11240803/how-to-perform-jaxb2-marshalling-of-input-request-in-rest-with-spring-mvc3)
I am new to Spring MVC...
JobParameters.parameters is in fact a Map<String, JobParameter>
Your unchecked code "allows" you to put an obj of incorrect type as value, but it will sure cause problem when accessing it.
I bet...
I am new to Spring Integration, and I try to make an Remote-Paritioning POC with JMS, base on the VanillaIntegrationTest of the spring-batch-integration unit test. Here is my resulting config, can...
Why don't simply make a job with 2 steps?
having a dedicate child app ctx for each job execution, and have the shared data as one plain spring bean in the job and inject into that 2 step artifacts
I would want to know if Spring Batch 1.1.x works with Spring 3.0?
I planned to upgrade to Spring 3.0, however our usage of Spring Batch is a bit too difficult to migrate the Spring Batch 2 for the...
Sometimes "no state persistence for restartability" is exactly what I want. I have some jobs that with 1 step prepare some data (e.g. a complicated lookup table) which will be used by several other...
Oh bcos in your previous post, you said "chunk listener is moving out from transaction". So only afterChunk() is moving out of txn?
In fact I have used chunk listener for some trick in my...
Seems the "Run job in a separate child context" feature is added in 2.x already, am I right?
classes like ClassPathXmlJobRegistry etc