Ammentos: hibernate alternative?

S

steve67

Hi,

I've developed for years with hibernate but I found it always too
complex (with its errors like lazy inizialization, mapping etc) and too
boring (make configuration file, sql dialect, etc).
For a new project I've done a research on internet about free java
persistence framework.
I found a free and opensource framework named Ammentos
(http://www.ammentos.org)
Ammentos used annotations, no configuration file, and it seems very very
very simple.
Has someone already tried to do something with this framework?

Thank you
Steve
 
L

Lew

steve67 said:
I've developed for years with hibernate but I found it always too
complex (with its errors like lazy inizialization, mapping etc) and too
boring (make configuration file, sql dialect, etc).
"Boring"?

For a new project I've done a research on internet about free java [sic]
persistence framework.

OpenJPA, Oracle TopLink/EclipseLink or another Java Persistence API
(JPA) framework.
I found a free and opensource framework named Ammentos
(http://www.ammentos.org)
Ammentos used annotations, no configuration file, and it seems very very
very simple.

No configuration file at all? How does it know its connection
parameters?

Hibernate, used as a JPA implementation, uses the Java-standard
'persistence.xml' file, which typically is quite short (about a dozen
lines of XML) and annotations.

The degree of HIbernate's configuration complexity depends directly on
the complexity of the application's needs. In a simple case, with
tables corresponding directly to domain entities and straightforward
foreign-key relationships, there is very little complexity to a
Hibernate implementation.

For more complex scenarios, assuming Ammentos can even handle it, the
framework's complexity of necessity must match the problem's.

Given that JPA is the standard now, I would recommend using a JPA
framework. In my use of it, I find JPA to be straightforward,
reliable and useful. And gives me no trouble with its lazy
initialization. It allows me to put together persistence-connected
functionality in a matter of a couple of hours with very little
fooferol.

I have no idea whether you'd find it "boring", though.
 
D

Donkey Hottie

steve67 said:
Hi,

I've developed for years with hibernate but I found it
always too complex (with its errors like lazy
inizialization, mapping etc) and too boring (make
configuration file, sql dialect, etc). For a new project I've done a
research on internet about
free java persistence framework.
I found a free and opensource framework named Ammentos
(http://www.ammentos.org)
Ammentos used annotations, no configuration file, and it
seems very very very simple.
Has someone already tried to do something with this
framework?

No. Personally I have worked only with JPA (as in EJB 3.0). It should work
everywhere as is, and is at least one of

- Hibernate
- Oracle TopLink / EclipseLink
- Apache OpenJPA

as its implementation provider.

Sticking with JPA you can create Application Server agnostic persistence
code, and when on JSE only projects, add any of those as the implementation
jars. Application Servers come with one of those preinstalled, and no jars
needed.

JPA has enough features for me.
 
S

steve67

On 10/08/2009 07:35 PM, Lew wrote:
[cut]
No configuration file at all? How does it know its connection
parameters?

I've read the Ammentos' guide and I've tried to do some examples.
IMHO is fantastic!
Ammentos doesn't need configuration file at all because it doesn't care
about connection and connection parameters.
You have to initialize it with your preferer DataSource with the
istrunction:
Ammentos.setDataSource( myDataSource );

I agree with you about JPA but IMHO mappings and quering are more
simpler with ammentos.
If you want, you can look at the guide here
http://ammentos.org/userguide.htm.

Thank you
Steve
 
L

Lew

steve67 said:
Ammentos doesn't need configuration file at all because it doesn't care
about connection and connection parameters.
You have to initialize it with your preferer DataSource with the
istrunction:
Ammentos.setDataSource( myDataSource );

That's not Ammentos, that's Java anywhere.

From
NOTE: The DataSource interface, new in the JDBC 2.0 API,
provides another way to connect to a data source.
The use of a DataSource object is the preferred means of
connecting to a data source.

And how do you define the data source?
I agree with you about JPA but IMHO mappings and quering are more
simpler with ammentos.
If you want, you can look at the guide herehttp://ammentos.org/userguide.htm.

You sound like a shill rather than an impartial observer.
 
A

Arved Sandstrom

steve67 said:
On 10/08/2009 07:35 PM, Lew wrote:
[cut]
No configuration file at all? How does it know its connection
parameters?

I've read the Ammentos' guide and I've tried to do some examples.
IMHO is fantastic!
Ammentos doesn't need configuration file at all because it doesn't care
about connection and connection parameters.
You have to initialize it with your preferer DataSource with the
istrunction:
Ammentos.setDataSource( myDataSource );

I agree with you about JPA but IMHO mappings and quering are more
simpler with ammentos.
If you want, you can look at the guide here
http://ammentos.org/userguide.htm.

Thank you
Steve

I took a look at the userguide. There is absolutely nothing there to
indicate that what Ammentos can do (a small subset of what JPA can do)
is accomplished with less effort and complexity than JPA.

And since the Ammentos annotations are non-standard, you're committed to
that implementation.

AHS
 
L

Lew

That's an obvious falsehood. Somehow it has to know the connection parameters
or it will not be able to connect.
You have to initialize it with your preferer [sic] DataSource with the
istrunction [sic]:
Ammentos.setDataSource( myDataSource );

And how do you configure the data source?

Don't duck the question this time - tell the truth.

If you're talking about javax.sql.DataSource, then you configure it through
some configuration interface that ultimately works out to some deployment
descriptor.

If you aren't talking about javax.sql.DataSource, then you need to tell us
what you are talking about.
I agree with you about JPA but IMHO mappings and quering [sic] are more
simpler [sic] with ammentos [sic].

Arved said:
I took a look at the userguide. There is absolutely nothing there to
indicate that what Ammentos can do (a small subset of what JPA can do)
is accomplished with less effort and complexity than JPA.

And since the Ammentos annotations are non-standard, you're committed to
that implementation.

Thanks, Arved. I suspected as much.

Speaking of telling the truth, "steve67", what is your business connection
with Ammentos?
 
L

Lew

Peter said:
I doubt it's a coincidence that a "traceroute ammentos.org" goes
through, and is hosted by, the same Internet servers and domain
"steve67" is using to post.

The utter dishonesty of the marketing approach, "I found a free and opensource
framework named Ammentos," is a deal killer. How in the world could I trust a
liar like that to make a worthy product?

Ammentos is off my list permanently for attempting to defraud us. Next time,
"steve67", don't be a dirty, rotten liar. You'd've had a much better chance
telling us the truth, you degenerate scammer.
 
S

steve67

On 10/09/2009 02:57 AM, Lew wrote:
[cut]
I doubt it's a coincidence that a "traceroute ammentos.org" goes
through, and is hosted by, the same Internet servers and domain
[cut]
The utter dishonesty of the marketing approach
[cut]

I honestly do not understand your accusations.
I apologize if I inadvertently caused a flame, it was not my intention.
I have no connection with ammentos and moreover I don't see how I could
earn from it.
About your investigation and my ip, I'm connected with an italian
provider named Tiscali that is one of the biggest internet provider in
italy.
That said, I found a project that seemed (IMHO) nice and I wanted to
suggest it and know your advice about it without any willingness to
raise a flame.

Anyway thanks for your advice
 
L

Lew

steve67 said:
I honestly do not understand your accusations.
I apologize if I inadvertently caused a flame, it was not my intention.
I have no connection with ammentos and moreover I don't see how I could
earn from it.
About your investigation and my ip, I'm connected with an italian
provider named Tiscali that is one of the biggest internet provider in
italy.
That said, I found a project that seemed (IMHO) nice and I wanted to
suggest it and know your advice about it without any willingness to
raise a flame.

OK, I believe you and retract my earlier comment..

I disagree with your characterization of Hibernate as "too complex",
and I am mystified at the characterization of it as "boring". I've
found Hibernate extremely easy to use, much easier than any of the pre-
JPA ORM frameworks I've used, much easier than rolling your own, and
much easier than some so-called "wrappers" for Hibernate that I've
seen. I advice one to stay away from non-JPA frameworks for Java at
this point.

I also worry about the false statement that Ammentos needs no
configuration to connect to a database and wonder why my questions
here on that subject remain unanswered.
 
L

Lew

Why would you ignore that possibility?  How would it even be relevant?

You've misstated the correct conclusion, providing a strawman rather than  
useful analysis.  If you are picking two particular people in the world at  
random, the odds of those two being siblings is so small as to be  
inconsequential.  You can in fact ignore the possibility that _those two_  
might be _each other's_ sibling (at least, for all but the most critical,  
life-and-death scenarios).

But, the question you introduce -- whether _anyone_ has a sibling -- is  
similar not to the question I raised originally, but rather to the  
question as to whether _anyone_ else uses the same ISP as our  
astroturfer.  And if we're going to be tangential, I'm happy to take as  
granted there's at least one other person using that same ISP.

But that's not the interesting question here; the interesting question is  
what the likelihood of some randomly selected person posting to Usenet  
using the same ISP as some other randomly selected person that first  
person is praising.

And in fact, the answer to that question is the same as the answer to the  
question of two randomly selected people being _each other's_ siblings.  
Which you've already pointed out, is inconsequentially small.

To carry that a step further, we're dealing not with the /a priori/
probability that two randomly chosen people in all of the world are
siblings, but with the conditional probability that person A who
praises person B *and* lives at the same address is a sibling of B or
is otherwise very closely related.
 
E

Eric Sosman

Peter said:
Why would you ignore that possibility? How would it even be relevant?

You've misstated the correct conclusion, providing a strawman rather
than useful analysis. If you are picking two particular people in the
world at random, the odds of those two being siblings is so small as to
be inconsequential. You can in fact ignore the possibility that _those
two_ might be _each other's_ sibling (at least, for all but the most
critical, life-and-death scenarios).

Exactly. I've offered a (blatant) parody of your fallacious
calculation. You opine that since there are LargeNumber ISP's in
the world, the chance of any two people/concerns/companies having
the same ISP is infinitessimal[sic]. I have offered a similar (and
similarly meaningless) calculation about siblings, to illustrate
the vacuousness of your estimate of "the odds." Both calculations
are utterly stupid, hence equally valid.

It is an error to assume statistical independence of events
that are mutually dependent. Our correspondent is Italian and
uses an Italian ISP. I note that you appear to use an Australian
ISP; may I conclude that you are probably associated with all
other companies and commercial concerns with iinet contracts?

Balderdash and bum-blast.
 
A

Andrew Thompson

...Has someone already tried to do something with this framework?

Yeah. You, apparently.

One of the advantages that Hibernate has
over Ammentos is that it has a large user
base, so when someone becomes stuck and
asks a question on a public forum, there
are likely people who have encountered and
solved the problem before.

Also, Hibernate does not sound like a breath
freshener (if you can consider that an advantage).
Not that something which conjures the image
of a sleeping bear is much better..

As an aside, my 'gut feeling' is that you
are a shill. Any product that requires such
promotion is barely worthy of consideration.
 
A

Arved Sandstrom

Kenneth said:
On Fri, 09 Oct 2009 23:47:51 -0700, Peter Duniho wrote:

[Snip]
In any case, if you want to believe that the OP has no prior connection
whatsoever to the Ammentos folks, be my guest. Horse, water, and all
that.

He said he wasn't. Given that it costs me nothing to believe him, why
not? I doesn't add any value to what he said. I'm still not interested
in a product that takes me away from standards to do something already
done well by the standard JPA architecture.

Just my 2 cents.

I'm inclined to believe the guy. Your earlier argument isn't a bad one -
I for one am more likely to be aware of software being churned out in
the Canadian Atlantic provinces than a developer outside this region
would be. If I were inclined to tout software (I'm not normally so
inclined) then the chances of me mentioning a local app aren't all that
low. It might look suspicious but there'd be no reason to believe I'm
connected with the makers of the software.

And as you said, I might have both objective and subjective reasons to
mention local products.

I might also note that on a Google search for "java persistence
frameworks" that the very first link is
http://java-source.net/open-source/persistence, and Ammentos figures on
that page. I personally have been stuck on
Hibernate/Toplink/EclipseLink/JPA for some years now, on the Java side
(*) but I'd be hesitant to claim that this is what many or most
developers do. If I looked at a page like the link above, and was
somewhat new in the field, I don't know as how JPA providers would
immediately leap out at me.

AHS

* LINQ and NHibernate on the .NET side. I don't claim to have done any
significant research as to what to use - these seemed somewhat obvious.
 
L

Lew

Arved said:
I might also note that on a Google search for "java persistence
frameworks" that the very first link is
http://java-source.net/open-source/persistence, and Ammentos figures on
that page. I personally have been stuck on
Hibernate/Toplink/EclipseLink/JPA for some years now, on the Java side
(*) but I'd be hesitant to claim that this is what many or most
developers do. If I looked at a page like the link above, and was
somewhat new in the field, I don't know as how JPA providers would
immediately leap out at me.

They should, since JPA constitutes the second, third and fourth references
from that search. Anyone who ignores all but the first hit has unduly weak
Google-fu. Anybody who stops learning after the first two sentences is doomed
to be an unduly weak programmer. Any responsible practitioner knows this and
digs more than a millimeter deep.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top