/[cvs]/nfo/perl/libs/Data/Storage.pm
ViewVC logotype

Diff of /nfo/perl/libs/Data/Storage.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by joko, Sun Oct 27 18:35:07 2002 UTC revision 1.14 by joko, Thu Dec 19 16:27:59 2002 UTC
# Line 4  Line 4 
4  #  #
5  # See COPYRIGHT section in pod text below for usage and distribution rights.  # See COPYRIGHT section in pod text below for usage and distribution rights.
6  #  #
7  #################################  ############################################
8  #  #
9  #  $Log$  #  $Log$
10    #  Revision 1.14  2002/12/19 16:27:59  joko
11    #  - moved 'sub dropDb' to Data::Storage::Handler::DBI
12    #
13    #  Revision 1.13  2002/12/17 21:54:12  joko
14    #  + feature when using Tangram:
15    #    + what? each object created should delivered with a globally(!?) unique identifier (GUID) besides the native tangram object id (OID)
16    #        + patched Tangram::Storage (jonen)
17    #        + enhanced Data::Storage::Schema::Tangram (joko)
18    #        + enhanced Data::Storage::Handler::Tangram 'sub getObjectByGuid' (jonen)
19    #    + how?
20    #        + each concrete (non-abstract) class gets injected with an additional field/property called 'guid' - this is done (dynamically) on schema level
21    #        + this property ('guid') gets filled on object creation/insertion from 'sub Tangram::Storage::_insert' using Data::UUID from CPAN
22    #        + (as for now) this property can get accessed by calling 'getObjectByGuid' on the already known storage-handle used throughout the application
23    #
24    #  Revision 1.12  2002/12/12 02:50:15  joko
25    #  + this now (unfortunately) needs DBI for some helper functions
26    #  + TODO: these have to be refactored to another scope! (soon!)
27    #
28    #  Revision 1.11  2002/12/11 06:53:19  joko
29    #  + updated pod
30    #
31    #  Revision 1.10  2002/12/07 03:37:23  joko
32    #  + updated pod
33    #
34    #  Revision 1.9  2002/12/01 22:15:45  joko
35    #  - sub createDb: moved to handler
36    #
37    #  Revision 1.8  2002/11/29 04:48:23  joko
38    #  + updated pod
39    #
40    #  Revision 1.7  2002/11/17 06:07:18  joko
41    #  + creating the handler is easier than proposed first - for now :-)
42    #  + sub testAvailability
43    #
44    #  Revision 1.6  2002/11/09 01:04:58  joko
45    #  + updated pod
46    #
47    #  Revision 1.5  2002/10/29 19:24:18  joko
48    #  - reduced logging
49    #  + added some pod
50    #
51  #  Revision 1.4  2002/10/27 18:35:07  joko  #  Revision 1.4  2002/10/27 18:35:07  joko
52  #  + added pod  #  + added pod
53  #  #
# Line 23  Line 64 
64  #  Revision 1.1  2002/10/10 03:43:12  cvsjoko  #  Revision 1.1  2002/10/10 03:43:12  cvsjoko
65  #  + new  #  + new
66  #  #
67  #################################  ############################################
68    
 # aim_V1: should encapsulate Tangram, DBI, DBD::CSV and LWP:: to access them in an unordinary way ;)  
 # aim_V2: introduce a generic layered structure, refactor *SUBLAYER*-stuff, make (e.g.) this possible:  
 #               - Perl Data::Storage[DBD::CSV]  ->  Perl LWP::  ->  Internet HTTP/FTP/*  ->  Host Daemon  ->  csv-file  
69    
70  BEGIN {  BEGIN {
71  $Data::Storage::VERSION = 0.01;    $Data::Storage::VERSION = 0.02;
72  }  }
73    
74    
75  =head1 NAME  =head1 NAME
76    
77  Data::Storage - Interface for accessing various Storage implementations for Perl in an independent way    Data::Storage - Interface for accessing various Storage implementations for Perl in an independent way
78    
79    
80    =head1 AIMS
81    
82      - should encapsulate Tangram, DBI, DBD::CSV and LWP:: to access them in an unordinary (more convenient) way ;)
83      - introduce a generic layered structure, refactor *SUBLAYER*-stuff, make (e.g.) this possible:
84        Perl Data::Storage[DBD::CSV]  ->  Perl LWP::  ->  Internet HTTP/FTP/*  ->  Host Daemon  ->  csv-file
85      - provide generic synchronization mechanisms across arbitrary/multiple storages based on ident/checksum
86        maybe it's possible to have schema-, structural- and semantical modifications synchronized???
87    
88    
89  =head1 SYNOPSIS  =head1 SYNOPSIS
90    
91    ... the basic way:  =head2 BASIC ACCESS
92    
93    =head2 ADVANCED ACCESS
94    
95    ... via inheritance:    ... via inheritance:
96        
# Line 58  Data::Storage - Interface for accessing Line 108  Data::Storage - Interface for accessing
108      $self->{storage}->insert($proxyObj);      $self->{storage}->insert($proxyObj);
109    
110    
111    =head2 SYNCHRONIZATION
112    
113      my $nodemapping = {
114        'LangText' => 'langtexts.csv',
115        'Currency' => 'currencies.csv',
116        'Country'  => 'countries.csv',
117      };
118    
119      my $propmapping = {
120        'LangText' => [
121          [ 'source:lcountrykey'  =>  'target:country' ],
122          [ 'source:lkey'         =>  'target:key' ],
123          [ 'source:lvalue'       =>  'target:text' ],
124        ],
125        'Currency' => [
126          [ 'source:ckey'         =>  'target:key' ],
127          [ 'source:cname'        =>  'target:text' ],
128        ],
129        'Country' => [
130          [ 'source:ckey'         =>  'target:key' ],
131          [ 'source:cname'        =>  'target:text' ],
132        ],
133      };
134    
135      sub syncResource {
136    
137        my $self = shift;
138        my $node_source = shift;
139        my $mode = shift;
140        my $opts = shift;
141        
142        $mode ||= '';
143        $opts->{erase} ||= 0;
144        
145        $logger->info( __PACKAGE__ . "->syncResource( node_source $node_source mode $mode erase $opts->{erase} )");
146      
147        # resolve metadata for syncing requested resource
148        my $node_target = $nodemapping->{$node_source};
149        my $mapping = $propmapping->{$node_source};
150        
151        if (!$node_target || !$mapping) {
152          # loggger.... "no target, sorry!"
153          print "error while resolving resource metadata", "\n";
154          return;
155        }
156        
157        if ($opts->{erase}) {
158          $self->_erase_all($node_source);
159        }
160      
161        # create new sync object
162        my $sync = Data::Transfer::Sync->new(
163          storages => {
164            L => $self->{bizWorks}->{backend},
165            R => $self->{bizWorks}->{resources},
166          },
167          id_authorities        =>  [qw( L ) ],
168          checksum_authorities  =>  [qw( L ) ],
169          write_protected       =>  [qw( R ) ],
170          verbose               =>  1,
171        );
172        
173        # sync
174        # todo: filter!?
175        $sync->syncNodes( {
176          direction       =>  $mode,                 # | +PUSH | +PULL | -FULL | +IMPORT | -EXPORT
177          method          =>  'checksum',            # | -timestamp | -manual
178          source          =>  "L:$node_source",
179          source_ident    =>  'storage_method:id',
180          source_exclude  =>  [qw( id cs )],
181          target          =>  "R:$node_target",
182          target_ident    =>  'property:oid',
183          mapping         =>  $mapping,
184        } );
185    
186      }
187    
188    
189  =head2 NOTE  =head2 NOTE
190    
191  This module heavily relies on DBI and Tangram, but adds a lot of additional bugs and quirks.    This module heavily relies on DBI and Tangram, but adds a lot of additional bugs and quirks.
192  Please look at their documentation and this code for additional information.    Please look at their documentation and/or this code for additional information.
193    
194    
195    =head1 REQUIREMENTS
196    
197      For full functionality:
198        DBI              from CPAN
199        DBD::mysql       from CPAN
200        Tangram 2.04     from CPAN         (hmmm, 2.04 won't do in some cases)
201        Tangram 2.05     from http://...   (2.05 seems okay but there are also additional patches from our side)
202        Class::Tangram   from CPAN
203        DBD::CSV         from CPAN
204        MySQL::Diff      from http://adamspiers.org/computing/mysqldiff/
205        ... and all their dependencies
206    
207  =cut  =cut
208    
209  # The POD text continues at the end of the file.  # The POD text continues at the end of the file.
# Line 75  use strict; Line 215  use strict;
215  use warnings;  use warnings;
216    
217  use Data::Storage::Locator;  use Data::Storage::Locator;
218    use Data::Dumper;
219    
220    # TODO: wipe out!
221    use DBI;
222    
223    # TODO: actually implement level (integrate with Log::Dispatch)
224    my $TRACELEVEL = 0;
225    
226  # get logger instance  # get logger instance
227  my $logger = Log::Dispatch::Config->instance;  my $logger = Log::Dispatch::Config->instance;
# Line 83  sub new { Line 230  sub new {
230    my $invocant = shift;    my $invocant = shift;
231    my $class = ref($invocant) || $invocant;    my $class = ref($invocant) || $invocant;
232    #my @args = normalizeArgs(@_);    #my @args = normalizeArgs(@_);
233      
234    my $arg_locator = shift;    my $arg_locator = shift;
235    my $arg_options = shift;    my $arg_options = shift;
236      
237    #my $self = { STORAGEHANDLE => undef, @_ };    #my $self = { STORAGEHANDLE => undef, @_ };
238    my $self = { STORAGEHANDLE => undef, locator => $arg_locator, options => $arg_options };    my $self = { STORAGEHANDLE => undef, locator => $arg_locator, options => $arg_options };
239    $logger->debug( __PACKAGE__ . "[$self->{locator}->{type}]" . "->new(@_)" );    #$logger->debug( __PACKAGE__ . "[$self->{locator}->{type}]" . "->new(@_)" );
240      $logger->debug( __PACKAGE__ . "[$arg_locator->{type}]" . "->new(@_)" );
241    return bless $self, $class;    return bless $self, $class;
242  }  }
243    
# Line 100  sub AUTOLOAD { Line 248  sub AUTOLOAD {
248    #     - Deep recursion on subroutine "Data::Storage::AUTOLOAD"    #     - Deep recursion on subroutine "Data::Storage::AUTOLOAD"
249    #     - Deep recursion on subroutine "Data::Storage::Handler::Abstract::AUTOLOAD"    #     - Deep recursion on subroutine "Data::Storage::Handler::Abstract::AUTOLOAD"
250    #     - Deep recursion on anonymous subroutine at [...]    #     - Deep recursion on anonymous subroutine at [...]
251    # we also might filter log messages caused by logging itself in "advanced logging of AUTOLOAD calls"    # we also might filter log messages caused by logging to itself in "advanced logging of AUTOLOAD calls"
252        
253    my $self = shift;    my $self = shift;
254    our $AUTOLOAD;    our $AUTOLOAD;
# Line 111  sub AUTOLOAD { Line 259  sub AUTOLOAD {
259    my $method = $AUTOLOAD;    my $method = $AUTOLOAD;
260    $method =~ s/^.*:://;    $method =~ s/^.*:://;
261    
262    # advanced logging of AUTOLOAD calls    # advanced logging of AUTOLOAD calls ...
263      my $logstring = "";    # ... nice but do it only when TRACING (TODO) is enabled
264      $logstring .= __PACKAGE__ . "[$self->{locator}->{type}]" . "->" . $method;      if ($TRACELEVEL) {
265      #print "count: ", $#_, "\n";        my $logstring = "";
266      #$logstring .= Dumper(@_) if ($#_ != -1);        $logstring .= __PACKAGE__ . "[$self->{locator}->{type}]" . "->" . $method;
267      my $tabcount = int( (80 - length($logstring)) / 10 );        #print "count: ", $#_, "\n";
268      $logstring .= "\t" x $tabcount . "(AUTOLOAD)";        #$logstring .= Dumper(@_) if ($#_ != -1);
269      # TODO: only ok if logstring doesn't contain        my $tabcount = int( (80 - length($logstring)) / 10 );
270      #            e.g. "Data::Storage[Tangram]->insert(SystemEvent=HASH(0x5c0034c))          (AUTOLOAD)"        $logstring .= "\t" x $tabcount . "(AUTOLOAD)";
271      # but that would be way too specific as long as we don't have an abstract handler for this  ;)        # TODO: only ok if logstring doesn't contain
272      $logger->debug( $logstring );        #            e.g. "Data::Storage[Tangram]->insert(SystemEvent=HASH(0x5c0034c))          (AUTOLOAD)"
273          # but that would be _way_ too specific as long as we don't have an abstract handler for this  ;)
274    # filtering AUTOLOAD calls        $logger->debug( $logstring );
275          #print join('; ', @_);
276        }
277        
278      # filtering AUTOLOAD calls and first-time-touch of the actual storage impl
279    if ($self->_filter_AUTOLOAD($method)) {    if ($self->_filter_AUTOLOAD($method)) {
280        #print "_accessStorage\n";
281      $self->_accessStorage();      $self->_accessStorage();
282      $self->{STORAGEHANDLE}->$method(@_);      $self->{STORAGEHANDLE}->$method(@_);
283    }    }
# Line 155  sub normalizeArgs { Line 308  sub normalizeArgs {
308  sub _accessStorage {  sub _accessStorage {
309    my $self = shift;    my $self = shift;
310    # TODO: to some tracelevel!    # TODO: to some tracelevel!
311    $logger->debug( __PACKAGE__ .  "[$self->{locator}->{type}]" . "->_accessStorage()" );    if ($TRACELEVEL) {
312        $logger->debug( __PACKAGE__ .  "[$self->{locator}->{type}]" . "->_accessStorage()" );
313      }
314    if (!$self->{STORAGEHANDLE}) {    if (!$self->{STORAGEHANDLE}) {
315      $self->_createStorageHandle();      $self->_createStorageHandle();
316    }    }
# Line 163  sub _accessStorage { Line 318  sub _accessStorage {
318    
319  sub _createStorageHandle {  sub _createStorageHandle {
320    my $self = shift;    my $self = shift;
   
321    my $type = $self->{locator}->{type};    my $type = $self->{locator}->{type};
322    $logger->debug( __PACKAGE__ .  "[$type]" . "->_createStorageHandle()" );    $logger->debug( __PACKAGE__ .  "[$type]" . "->_createStorageHandle()" );
323    
324    my $pkg = "Data::Storage::Handler::" . $type . "";    my $pkg = "Data::Storage::Handler::" . $type . "";
325        
326    # propagate args to handler    # try to load perl module at runtime
327    # needs some more thoughts! (not only "dbi" to Tangram, when (in future) db is not more the common case)    my $evalstr = "use $pkg;";
328    if ($type eq 'DBI') {    eval($evalstr);
329      use Data::Storage::Handler::DBI;    if ($@) {
330      #my @args = %{$self->{locator}->{dbi}};      $logger->error( __PACKAGE__ .  "[$type]" . "->_createStorageHandle(): $@" );
331      my @args = %{$self->{locator}};      return;
     # create new storage handle  
     $self->{STORAGEHANDLE} = $pkg->new( @args );  
   }  
   if ($type eq 'Tangram') {  
     use Data::Storage::Handler::Tangram;  
     #$self->{STORAGEHANDLE} = $pkg->new( dsn => $self->{locator}->{dbi}->{dsn} );  
     #my @args = %{$self->{locator}->{dbi}};  
     my @args = %{$self->{locator}};  
     # create new storage handle  
     $self->{STORAGEHANDLE} = $pkg->new( @args );  
   
     #$self->{STORAGEHANDLE_UNDERLYING} = $self->{STORAGEHANDLE}->getUnderlyingStorage();  
     #$self->{STORAGEHANDLE_UNDERLYING}->_configureCOREHANDLE();  
332    }    }
333        
334      # build up some additional arguments to pass on
335      #my @args = %{$self->{locator}};
336      my @args = ();
337    
338      # - create new storage handle object
339      # - propagate arguments to handler
340      # - pass locator by reference to be able to store status- or meta-information in it
341      $self->{STORAGEHANDLE} = $pkg->new( locator => $self->{locator}, @args );
342    
343  }  }
344    
345  sub addLogDispatchHandler {  sub addLogDispatchHandler {
# Line 221  sub addLogDispatchHandler { Line 371  sub addLogDispatchHandler {
371  }  }
372    
373  sub removeLogDispatchHandler {  sub removeLogDispatchHandler {
374      my $self = shift;
375        my $self = shift;    my $name = shift;
376        my $name = shift;    #my $logger = shift;
377        #my $logger = shift;    $logger->remove($name);
   
       $logger->remove($name);  
   
378  }  }
379    
380  sub getDbName {  sub getDbName {
# Line 238  sub getDbName { Line 385  sub getDbName {
385    return $database_name;    return $database_name;
386  }  }
387    
388  sub testDsn {  sub testAvailability {
389    my $self = shift;    my $self = shift;
390    my $dsn = $self->{locator}->{dbi}->{dsn};    my $status = $self->testDsn();
391    my $result;    $self->{locator}->{status}->{available} = $status;
392    if ( my $dbh = DBI->connect($dsn, '', '', {    return $status;
                                                       PrintError => 0,  
                                                       } ) ) {  
     $dbh->disconnect();  
     return 1;  
   } else {  
     $logger->error( __PACKAGE__ .  "[$self->{locator}->{type}]" . "->testDsn(): " . "DBI-error: " . $DBI::errstr );  
   }  
393  }  }
394    
395  sub createDb {  sub isConnected {
396    my $self = shift;    my $self = shift;
397    my $dsn = $self->{locator}->{dbi}->{dsn};    # TODO: REVIEW!
398      return 1 if $self->{STORAGEHANDLE};
   $logger->debug( __PACKAGE__ .  "->createDb( dsn $dsn )" );  
   
   $dsn =~ s/database=(.+?);//;  
   my $database_name = $1;  
   
   my $ok;  
     
   if ( my $dbh = DBI->connect($dsn, '', '', {  
                                                       PrintError => 0,  
                                                       } ) ) {  
     if ($database_name) {  
       if ($dbh->do("CREATE DATABASE $database_name;")) {  
         $ok = 1;  
       }  
     }  
     $dbh->disconnect();  
   }  
     
   return $ok;  
     
399  }  }
400    
401  sub dropDb {  sub testDsn {
402    my $self = shift;    my $self = shift;
403    my $dsn = $self->{locator}->{dbi}->{dsn};    my $dsn = $self->{locator}->{dbi}->{dsn};
404      my $result;
   $logger->debug( __PACKAGE__ .  "->dropDb( dsn $dsn )" );  
   
   $dsn =~ s/database=(.+?);//;  
   my $database_name = $1;  
   
   my $ok;  
     
405    if ( my $dbh = DBI->connect($dsn, '', '', {    if ( my $dbh = DBI->connect($dsn, '', '', {
406                                                        PrintError => 0,                                                        PrintError => 0,
407                                                        } ) ) {                                                        } ) ) {
408      if ($database_name) {      
409        if ($dbh->do("DROP DATABASE $database_name;")) {      # TODO: REVIEW
         $ok = 1;  
       }  
     }  
410      $dbh->disconnect();      $dbh->disconnect();
411        
412        return 1;
413      } else {
414        $logger->warning( __PACKAGE__ .  "[$self->{locator}->{type}]" . "->testDsn(): " . "DBI-error: " . $DBI::errstr );
415    }    }
     
   return $ok;  
 }  
   
 sub isConnected {  
   my $self = shift;  
   return 1 if $self->{STORAGEHANDLE};  
416  }  }
417    
418  1;  1;
# Line 314  __END__ Line 421  __END__
421    
422  =head1 DESCRIPTION  =head1 DESCRIPTION
423    
424  Data::Storage is module for a accessing various "data structures" stored inside  =head2 Data::Storage
 various "data containers". It sits on top of DBI and/or Tangram.  
425    
426      Data::Storage is a module for accessing various "data structures / kinds of structured data" stored inside
427      various "data containers".
428      We tried to use the AdapterPattern (http://c2.com/cgi/wiki?AdapterPattern) to implement a wrapper-layer
429      around core CPAN modules (Tangram, DBI).
430    
431    =head2 Why?
432    
433      You will get a better code-structure (not bad for later maintenance) in growing Perl code projects,
434      especially when using multiple database connections at the same time.
435      You will be able to switch between different _kinds_ of implementations used for storing data.
436      Your code will use the very same API to access these storage layers.
437          ... implementation has to be changed for now
438      Maybe you will be able to switch "on-the-fly" without changing any bits in code in the future....
439          ... but that's not the focus
440    
441  =head1 AUTHORS / COPYRIGHT  =head2 What else?
442    
443      Having this, we were able to do implement a generic data synchronization module more easy,
444      please look at Data::Transfer.
445    
 The Data::Storage module is Copyright (c) 2002 Andreas Motl.  
 All rights reserved.  
446    
447  You may distribute it under the terms of either the GNU General Public  =head1 AUTHORS / COPYRIGHT
448  License or the Artistic License, as specified in the Perl README file.  
449      The Data::Storage module is Copyright (c) 2002 Andreas Motl.
450      All rights reserved.
451      You may distribute it under the terms of either the GNU General Public
452      License or the Artistic License, as specified in the Perl README file.
453    
454    
455  =head1 ACKNOWLEDGEMENTS  =head1 ACKNOWLEDGEMENTS
456    
457  Larry Wall and the C<perl5-porters> for Perl,    Larry Wall for Perl, Tim Bunce for DBI, Jean-Louis Leroy for Tangram and Set::Object,
458  Tim Bunce for DBI, Jean-Louis Leroy for Tangram and Set::Object,    Sam Vilain for Class::Tangram, Jochen Wiedmann and Jeff Zucker for DBD::CSV & Co.,
459  Sam Vilain for Class::Tangram.    Adam Spiers for MySQL::Diff and all contributors.
460    
461    
462  =head1 SUPPORT / WARRANTY  =head1 SUPPORT / WARRANTY
463    
464  Data::Storage is free software. IT COMES WITHOUT WARRANTY OF ANY KIND.    Data::Storage is free software. IT COMES WITHOUT WARRANTY OF ANY KIND.
465    
466    
467  =head1 TODO  =head1 TODO
468    
469    
470  =head2 Handle the following errors/cases:  =head2 BUGS
471    
472    "DBI-Error [Tangram]: DBD::mysql::st execute failed: Unknown column 't1.requestdump' in 'field list'"
473    
474  =head3 "DBI-Error [Tangram]: DBD::mysql::st execute failed: Unknown column 't1.requestdump' in 'field list'"    ... occours when operating on object-attributes not introduced yet:
475      this should be detected and appended/replaced through:
476      "Schema-Error detected, maybe (just) an inconsistency.
477      Please check if your declaration in schema-module "a" matches structure in database "b" or try to run"
478      db_setup.pl --dbkey=import --action=deploy
479    
     ... occours when operating on object-attributes not introduced yet:  
     this should be detected and appended/replaced through:  
     "Schema-Error detected, maybe (just) an inconsistency.  
     Please check if your declaration in schema-module "a" matches structure in database "b" or try to run"  
     db_setup.pl --dbkey=import --action=deploy  
480    
481  =head3 Compare schema (structure diff) with database ...  Compare schema (structure diff) with database ...
482    
483    ... when issuing "db_setup.pl --dbkey=import --action=deploy"    ... when issuing "db_setup.pl --dbkey=import --action=deploy"
484    on a database with an already deployed schema, use an additional "--update" then    on a database with an already deployed schema, use an additional "--update" then
# Line 373  Data::Storage is free software. IT COMES Line 499  Data::Storage is free software. IT COMES
499      R retrieve  ->  no, not subject of this aspect since it is about deployment only      R retrieve  ->  no, not subject of this aspect since it is about deployment only
500      U update    ->  yes, just by user-interaction; maybe automatically if it can be determined that data wouldn't be lost      U update    ->  yes, just by user-interaction; maybe automatically if it can be determined that data wouldn't be lost
501      D delete    ->  yes, just by user-interaction      D delete    ->  yes, just by user-interaction
502    It's all about not to be able to loose data simply while this is in alpha stage.    
503      It's all about not to be able to loose data simply while this is in pre-alpha stage.
504      And loosing data by being able to modify and redeploy schemas easily is definitely quite easy.
505      
506      As we can see, creations of Classes and new Class variables is handled
507      automatically and this is believed to be the most common case under normal circumstances.
508    
509    
510  =head2 Introduce some features:  =head2 FEATURES
511    
512    Get this stuff together with UML (Unified Modeling Language) and/or standards from ODMG.    - Get this stuff together with UML (Unified Modeling Language) and/or standards from ODMG.
513    Make it possible to load/save schemas in XMI (XML Metadata Interchange),    - Make it possible to load/save schemas in XMI (XML Metadata Interchange),
514    which seems to be most commonly used today, perhaps handle objects with OIFML.      which seems to be most commonly used today, perhaps handle objects with OIFML.
515    Integrate/bundle this with a web-/html-based UML modeling tool or      Integrate/bundle this with a web-/html-based UML modeling tool or
516    some other interesting stuff like the "Co-operative UML Editor" from Uni Darmstadt. (web-/java-based)      some other interesting stuff like the "Co-operative UML Editor" from Uni Darmstadt. (web-/java-based)
517    Enable Round Trip Engineering. Keep code and diagrams in sync. Don't annoy/bother the programmer.    - Enable Round Trip Engineering. Keep code and diagrams in sync. Don't annoy/bother the programmers.
518      - Add support for some more handlers/locators to be able to
519         access the following standards/protocols/interfaces/programs/apis transparently:
520        +  DBD::CSV (via Data::Storage::Handler::DBI)
521       (-) Text::CSV, XML::CSV, XML::Excel
522        -  MAPI
523        -  LDAP
524        -  DAV (look at PerlDAV: http://www.webdav.org/perldav/)
525        -  Mbox (use formail for seperating/splitting entries/nodes)
526        -  Cyrus (cyrdeliver - what about cyrretrieve (export)???)
527        -  use File::DiffTree, use File::Compare
528        -  Hibernate
529        -  "Win32::UserAccountDb"
530        -  "*nix::UserAccountDb"
531        -  .wab - files (Windows Address Book)
532        -  .pst - files (Outlook Post Storage?)
533        -  XML (e.g. via XML::Simple?)
534      - Move to t3, look at InCASE
535      - some kind of security layer for methods/objects
536        - acls (stored via tangram/ldap?) for functions, methods and objects (entity- & data!?)
537        - where are the hooks needed then?
538          - is Data::Storage & Co. okay, or do we have to touch the innards of DBI and/or Tangram?
539          - an attempt to start could be:
540             - 'sub getACLByObjectId($id, $context)'
541             - 'sub getACLByMethodname($id, $context)'
542             - 'sub getACLByName($id, $context)'
543                ( would require a kinda registry to look up these very names pointing to arbitrary locations (code, data, ...) )
544      - add more hooks and various levels
545      - better integrate introduced 'getObjectByGuid'-mechanism from Data::Storage::Handler::Tangram
546    
547    
548  =head3 Links:  =head3 LINKS / REFERENCES
549    
550      Specs:
551      UML 1.3 Spec: http://cgi.omg.org/cgi-bin/doc?ad/99-06-08.pdf      UML 1.3 Spec: http://cgi.omg.org/cgi-bin/doc?ad/99-06-08.pdf
552      XMI 1.1 Spec: http://cgi.omg.org/cgi-bin/doc?ad/99-10-02.pdf      XMI 1.1 Spec: http://cgi.omg.org/cgi-bin/doc?ad/99-10-02.pdf
553      XMI 2.0 Spec: http://cgi.omg.org/docs/ad/01-06-12.pdf      XMI 2.0 Spec: http://cgi.omg.org/docs/ad/01-06-12.pdf
554      ODMG: http://odmg.org/      ODMG: http://odmg.org/
555      OIFML: http://odmg.org/library/readingroom/oifml.pdf      OIFML: http://odmg.org/library/readingroom/oifml.pdf
     Co-operative UML Editor: http://www.darmstadt.gmd.de/concert/activities/internal/umledit.html  
556    
557    further readings:    CASE Tools:
558        Rational Rose (commercial): http://www.rational.com/products/rose/
559        Together (commercial): http://www.oi.com/products/controlcenter/index.jsp
560        InCASE - Tangram-based Universal Object Editor
561        Sybase PowerDesigner: http://www.sybase.com/powerdesigner
562      
563      UML Editors:
564        Fujaba (free, university): http://www.fujaba.de/
565        ArgoUML (free): http://argouml.tigris.org/
566        Poseidon (commercial): http://www.gentleware.com/products/poseidonDE.php3
567        Co-operative UML Editor (research): http://www.darmstadt.gmd.de/concert/activities/internal/umledit.html
568        Metamill (commercial): http://www.metamill.com/
569        Violet (university, research, education): http://www.horstmann.com/violet/
570        PyUt (free): http://pyut.sourceforge.net/
571        (Dia (free): http://www.lysator.liu.se/~alla/dia/)
572        UMLet (free, university): http://www.swt.tuwien.ac.at/umlet/index.html
573        Voodoo (free): http://voodoo.sourceforge.net/
574        Umbrello UML Modeller: http://uml.sourceforge.net/
575    
576      UML Tools:
577        http://www.objectsbydesign.com/tools/umltools_byPrice.html
578    
579      Further readings:
580      http://www.google.com/search?q=web+based+uml+editor&hl=en&lr=&ie=UTF-8&oe=UTF-8&start=10&sa=N      http://www.google.com/search?q=web+based+uml+editor&hl=en&lr=&ie=UTF-8&oe=UTF-8&start=10&sa=N
581      http://www.fernuni-hagen.de/DVT/Aktuelles/01FHHeidelberg.pdf      http://www.fernuni-hagen.de/DVT/Aktuelles/01FHHeidelberg.pdf
582      http://www.enhyper.com/src/documentation/      http://www.enhyper.com/src/documentation/
# Line 403  Data::Storage is free software. IT COMES Line 584  Data::Storage is free software. IT COMES
584      http://citeseer.nj.nec.com/vilain00diagrammatic.html      http://citeseer.nj.nec.com/vilain00diagrammatic.html
585      http://archive.devx.com/uml/articles/Smith01/Smith01-3.asp      http://archive.devx.com/uml/articles/Smith01/Smith01-3.asp
586    
   maybe useful for / to be integrated with:  
     ArapXML: http://xml.coverpages.org/ni2001-09-24-b.html  

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.14

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed