Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Software Quality Analysis with Alitheia Core

467 views

Published on

Talk given at the 2010 Free software community conference, May 2010.

  • Be the first to comment

  • Be the first to like this

Software Quality Analysis with Alitheia Core

  1. 1. Ανάλυση Ποιότητας Λογισμικού με το Alitheia Core Γεώργιος ΓούσιοςΟικονομικό Πανεπιστήμιο Αθηνών (atm: ΚΕΠΥΕΣ)
  2. 2. Τι είναι η ΠοιοτηταΛογισμικού?
  3. 3. Από τηνπλευρά του χρήστη
  4. 4. Από τηνπλευρά του χρήστη
  5. 5. Πολυπλοκότητα
  6. 6. Παραβιάσεις της αρχής DRY
  7. 7. Κακές οσμές
  8. 8. External quality characteristics are those parts of a productthat face its users, where internal quality characteristics arethose that do not Steve Mc Connell a products quality is a function of how much it changes the world for the better. Tom DeMarco
  9. 9. PortabilityFunctionality MaintainabilityReliability ISO 9126 Usability Efficiency
  10. 10. Μηχανική Λογισμικού (software engineering)
  11. 11. Μπορούμε ναβελτιώσουμε μόνο ότι αξιολογούμε
  12. 12. Welcome, to the real world RCS CVS SVN Darcs Bugzilla Git SF.net Tracker Hg Jira Postfix Gnats MailMan Marc
  13. 13. Welcome, to the real world 400 300GB 200 Others 100 KDE 0 700 projects LSE (2003-2006) GenBank Dataset
  14. 14. Alitheia Core
  15. 15. http://demo.sqo-oss.org/web/proxy/metrics/by-id/28/ { "metric":{ "id":28, "metrictype":{ "id":1, "type":"SOURCE_FILE" }, "mnemonic":"HD", "description":"Halstead Difficulty Level" } }
  16. 16.                                                                                                                                                                                                                                     
  17. 17. Μεταδεδομένα
  18. 18. CPUStage 1: Raw data to metadata
  19. 19. CPUStage 2: Metadata Relationship Inference
  20. 20. Μετρικές
  21. 21. CPU
  22. 22. public interface AlitheiaPlugin { String getVersion(); String getAuthor(); Date getDateInstalled(); String getName(); String getDescription(); String getUniqueKey(); List<Result> getResultIfAlreadyCalculated(DAObject o, List<Metric> l) throws MetricMismatchException; List<Result> getResult(DAObject o, List<Metric> l) throws MetricMismatchException, AlreadyProcessingException, Exception; void run(DAObject o) throws MetricMismatchException, AlreadyProcessingException, Exception; boolean update(); boolean install(); boolean remove(); boolean cleanup(DAObject sp); List<Metric> getAllSupportedMetrics(); List<Metric> getSupportedMetrics(Class<? extends DAObject> activationType); Set<Class<? extends DAObject>> getActivationTypes(); List<Class<? extends DAObject>> getMetricActivationTypes (Metric m); Set<PluginConfiguration> getConfigurationSchema(); Set<String> getDependencies(); Map<MetricType.Type, SortedSet<Long>> getObjectIdsToSync(StoredProject sp, Metric m) throws MetricActivationException;}
  23. 23. public void run(ProjectFile pf) { // We do not support directories if (pf.getIsDirectory()) { return; } InputStream in = fds.getFileContents(pf); if (in == null) { return; } // Create an input stream from the project files content try { // Measure the number of lines in the project file LineNumberReader lnr = new LineNumberReader(new InputStreamReader(in)); int lines = 0; while (lnr.readLine() != null) { lines++; } lnr.close(); // Store the results Metric metric = Metric.getMetricByMnemonic("LOC"); ProjectFileMeasurement locm = new ProjectFileMeasurement(); locm.setMetric(metric); locm.setProjectFile(pf); locm.setWhenRun(new Timestamp(System.currentTimeMillis())); locm.setResult(String.valueOf(lines)); db.addRecord(locm); } catch (IOException e) { log.error(this.getClass().getName() + " IO Error <" + e + "> while measuring: " + pf.getFileName()); } }
  24. 24. public List<Result> getResult(ProjectFile a, Metric m) { return getResult(a, ProjectFileMeasurement.class, m, Result.ResultType.INTEGER);}
  25. 25. @MetricDeclarations(metrics = { @MetricDecl(mnemonic="TEST", descr="", activators={ProjectFile.class})})public class TestabilityImplementation extends AbstractMetric { private static final String MNEMONIC_NCASES = "TEST"; public TestabilityImplementation(BundleContext bc) { super(bc); }}
  26. 26. Ενεργοποίηση μετρικών
  27. 27. Απόδοση
  28. 28. New cluster node connects
  29. 29. Χρήσεις
  30. 30. Custom tool integration
  31. 31. Research platform
  32. 32. Σας ευχαριστώ!http://www.sqo-oss.org Georgios Gousios gousiosg@aueb.gr

×