This week's book giveaway is in the Artificial Intelligence forum.
We're giving away four copies of Pragmatic AI and have Noah Gift on-line!
See this thread for details.
Win a copy of Pragmatic AI this week in the Artificial Intelligence forum!

David Byron

Rancher
+ Follow
since Jan 20, 2009
David likes ...
Clojure Java Linux
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
13
Received in last 30 days
0
Total given
1
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Rancher Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by David Byron

It was a good thread and quite on point. I appreciate your help.
2 years ago
Thanks for your reply. This question was intended for the authors visiting the forum in relation to the book promotion/giveaway.
2 years ago
One of the newer features in Clojure, transducers, offers an additional means of higher-order abstraction. As I understand it-- which is not (yet) well!-- a transducer automates converting one algorithm to another (say, evolving one mapper or reducer or collector into another of the same kind).

Does your book cover the purpose and idiomatic usage of transducers, or did it reach press before that feature entered the language? If you do touch on transducers, can you offer an example that would make clear, especially for the imperatively-minded Clojure wannabe, what sort of use case or problem would call for that capability?

Thanks for contributing to the forum!
2 years ago
When you instantiate the class directly rather than redirecting to it through the framework, the lifecycle events provided by the framework have no opportunity to occur. (If you bypass the interceptors in this way, what will invoke your setter?) As a result, the session map is null when you attempt to call a method on it.

Try redirecting to the other action or, better yet, keeping interrelated methods together in a single cohesive action or service class.

4 years ago
In addition to all the preceding, JavaScript is now regarded as an important compilation target for languages such as ClojureScript and CoffeeScript (among many others).
4 years ago
According to this stack trace, you have a class, hbtest.Student, which you have annotated with @Entity (or which you have configured in xml). The problem is that it lacks an Id field with an @Id annotation (or the corresponding assignment in xml).
Ok, a follow-up question, then. ;)

You were already well informed when you undertook the task of writing this guide. (It's hard to imagine that you'd have taken on the task otherwise.)

Often the process of teaching a subject helps us to understand it in a fresh or different way.

What did you learn or newly recognize about Java enterprise architecture from the process of figuring out how best to teach it?
I understand that your book contains many sample questions in a multiple-choice format. One difficulty in writing test question is that the issues of enterprise architecture intersect and interweave in complex ways. The "wrong" answers must be demonstrably less preferable than the right one(s), and yet the question must not make the "right" answer too obvious. So some ambiguity may be needed in crafting a question... but not too much!

Was there one topic in particular for which it seemed more difficult to craft effective multiple choice questions?
Another interesting option is Squish.
6 years ago

Roel De Nijs wrote:I want to add another one:
f) use logging extensively if you have to communicate with a 3rd party library or application. It will give you valuable information when the performance of your application is questioned.


That's a good one.

Premature Optimization: bad
Premature Vindication: smart!
For the project, I included no logging (though I used some along the way).

For real work, if I'm feeling particularly energetic, I:
(a) log exceptions with a lot of detail useful for debugging
(b) do not log every single entry and exit into every method
(c) do log entry into the methods that kick off logical phases or discrete operations
(d) log passage through legal but uncommon pathways
(e) log notable validation results
I checked the Magic Cookie, read the schema from the file, and then validated the remainder of the file against the schema. Validation checked total file size, correctness of flag on each record, and record count.

The schema-reading and validation were just about the first methods I wrote, and I used them mainly to check whether I was corrupting the database file as I developed the app. (I worked against the file directly rather than via a cache.) When the time came to submit my project, I saw no reason not to leave them as they were.