All posts in Sparx Enterprise Architect

The first Maven snapshot of TRIMM 1.0.1 with TrimmMongo is available from our Maven Repository.

The TrimmMongo project has in this first version a Listener (dk.tigerteam.trimm.mdsd.mongo.SpringDataMongoGeneratorListener) that based on stereotypes can use Spring Data Mongo mapping annotation to save your model in MongDB instance.

There’s also an TrimmMongo example project available called TrimmMongoExample

Short introduction to TrimmMongo modeling

In this first version of the SpringDataMongoGeneratorListener there is support for following annotations for mappings of objects to documents. The listener Stereotypes and Tag values to drive the mapping metadata:

  • @Id – applied at the field level to mark the field used for identiy purpose. STEREOTYPE: DOCUMENT_ID
  • @Document – applied at the class level to indicate this class is a candidate for mapping to the database. You can specify the name of the collection where the database will be stored. STEREOTYPE: DOCUMENT
  • @DBRef – applied at the field to indicate it is to be stored using a com.mongodb.DBRef. STEREOTYPE: DBREF
  • @Indexed – applied at the field level to describe how to index the field. STEREOTYPE: INDEX & UNIQUEINDEX
  • @Transient – by default all private fields are mapped to the document, this annotation excludes the field where it is applied from being stored in the database STEREOTYPE: TRANSIENT

Read more

* Updated the 25th of October to include information on CreateCommand vs. Command stereotype handling for the TrimmCQRS plugin.

The first Maven snapshot of TRIMM 1.0.1 is available from our Maven Repository.

The changes in the core API revolve around enhancements the MetaModel and CodeModel, no breaking API changes.

The biggest change is the addition of the TrimmCQRS which supports Model Driven code generating of AxonFramework (a Java based CQRS framework) based CQRS code.

TrimmCQRS comes with a matching TrimmCQRSMavenPlugin that can be used to drive the codegeneration.

There’s also an TrimmCQRS example project available called TrimmCQRSAxonAddressBookExample which models and generates code that implement the same features and structure of the Axon AddressBook example.
Read more

TRIMM JPA will leave table and column names up to the default JPA rules, unless you instruct it to specify @Table, @JoinTable, @Column, @JoinColumn, et, e.g. using the addTableAndColumnNames parameter in the JPA YAML configuration.

It can sometimes be useful to control the table and column names if the default names (which follows the JPA default naming standard) collide with database reserved words or if you use a “modern” database like Oracle which still limits names to 30 characters 😉
Read more

Introduction

In the first tutorial, we looked at how to develop the TrimmWS Profile containing the Web Service modeling elements for use by the TigerTeam Trimm Model Generator and how to save it as a Profile that can be imported into EA. In the second tutorial we looked into how to make the Profile and its content more usable by combining it with a Toolbox and a Diagram into an MDG.

This tutorial describes how to add our own Datatypes to the TigerTeam TrimmWS MDG and how to automatically make them available to our modeling elements.
Read more

Introduction

In the first tutorial, we looked at how to develop the Profile containing the Web Service modeling elements for use by the TigerTeam Trimm Model Generator and how to save it as a Profile that can be imported into EA. In this second tutorial we will look into how we can make the Profile and its content more usable by combining it with a Toolbox and a Diagram into an MDG.

Why do we want to combine those and introduce the MDG when the profile already seem to do the trick? The simple answer is ease of use compared to using just the Profile. By adding a Toolbox and a Diagram, we can make our Profile act like any other built in feature and make it a lot easier to use.
Read more