Hi Andre,
I took a quick look. Annotating the metrics as real MSE properties is definitely the way
to go. We should integrate that in FAMIX-Extensios. I did not take a closer look, but from
a distance I also like the visitor solution for exporting a filtered model.
Now, I would like to provide a bit of feedback for the way you implemented this:
- You created a complete new repository that is specific to this task. This is a problem
because afterwards, this repository will die because it does not really contain a project.
For spike implementations like this, I would suggest to either use MoosePlayground, or
have your own in which you play with multiple smaller tasks. This makes it easier to track
the changes.
- To affect the changes on the FAMIX classes you copied the methods in your package. This
means that when I load your package, I will override my methods. This makes it hard and
error-prone to integrate them afterwards. Instead, you should have simply published the
FAMIX-Extensions package in your repository and apply changes on that one. Afterwards,
merging would have been straightforward. Could you try that?
- You created 2 packages in Monticello:
'Fame-ImportExport-Extensions'
'Fame-ImportExport-Extensions-MSE'
The problem is that when you will have both loaded in the image and you will try to save
'Fame-ImportExport-Extensions', you will also save in the same package the code
from the ''Fame-ImportExport-Extensions-MSE' category. That is because
Monticello relies on string pattern matching to map image categories to packages (bad
thing, but that is what we have now).
So, the rule of thumb is: never nest categories with '-'
Cheers,
Doru
On 14 Jul 2011, at 13:51, Andre Hora wrote:
Hello,
Just returning to this topic.
As most of the metrics are not described at the Fame level we are losing this information
when we export a model to MSE in Moose. We know that most of the metrics can be
recalculated in the model, but in some cases they cannot.
For example, when exporting in Moose a Java (VerveineJ) model we lose the metrics
cyclomaticComplexity (CYCLO) and numberOfStatements (NOS) and we cannot recalculate them.
So, to avoid it, I changed some metrics (some I think are important, but we can change
them if we integrate in Moose) to be described at the Fame level and like that we can
export them into a MSE. In this case, as the we could have a huge MSE, I implemented a
filter and you can select the metrics to be exported through a wizard. It solves, for
example, the lose of information with VerveineJ if you decide to export CYCLO and NOS.
To try you can run the script below and the right-click in a MooseModel and: Import /
Export -> Export model to MSE with metrics. Use the last version of Merlin.
Gofer new
squeaksource: 'FameImportExportEx';
package: 'Fame-ImportExport-Extensions';
package: 'Fame-ImportExport-Extensions-MSE';
load.
regards,
On Thu, Jun 23, 2011 at 3:32 PM, Stéphane Ducasse <stephane.ducasse(a)inria.fr>
wrote:
At one point metrics were described in the
meta-model but then MSE files were very large, slow to export (because you have to compute
all metrics), and slow to load (this was a long time ago). We decided to remove them from
the Smalltalk MSE export (although the MSE importer can still handle metrics and other
data, like for example when importing from infusion/verveinej).
but even in Smalltalk you need to keep loc
Now is the interface to select what to
export/import functional?
I do not know but this is something you we should definitively do
: select what to save
: select the format
-> tab separated, mse, xml
That would be the way to go. Then describe
metrics as part of a Fame package 'Metrics', then we can select group of data by
package. I would still like to be able to not export metrics in the MSE file.
On 22 juin 2011, at 15:27, Stéphane Ducasse wrote:
Hi guys
I could not find metrics in the saved MSE metrics like LOC that cannot be computed by
moose.
Are metrics saved? I remember writing tests to make sure that this was correct.
In addition it would be good to be able to select some metrics to be exported to other
formats.
Stef
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
Simon Denier
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
Andre Hora
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
"We can create beautiful models in a vacuum.
But, to get them effective we have to deal with the inconvenience of reality."