]> asedeno.scripts.mit.edu Git - cl-protobufs.git/commit
Tsunami framework + use tsunami in customer profiles
authorSergey Vasilyev <svas@google.com>
Fri, 14 Sep 2012 18:24:30 +0000 (18:24 +0000)
committerSergey Vasilyev <svas@google.com>
Fri, 14 Sep 2012 18:24:30 +0000 (18:24 +0000)
commit48aa0eee4fb74f30125d0d7fbda9eb59ae6768b1
treec9eb513785e966cca63f912a6b0226673fcc5d96
parente50238a355b6e64bc5ab863e2c6e90dba394fc47
Tsunami framework + use tsunami in customer profiles

 Testing : precheckin --full (both against Oracle and against megastore for customers)
 Reviewer: eschwartz

 JTB impact: n
 Ops impact: n
 Security impact: n

 Change to config                        : n
 Change to XML schema                    : Y (XMLREQ bug 120820)
 Change to DB schema                     : Y (DBREQ bug 119801)
 Change to transport (timeouts, headers) : n
 Any change (or new use) of OAQs         : n
 Change to inter-component transactions  : sort of (use megastore in development-only environments)
 Depends on any other checkin / bug      : n

 Tests that will verify : tsunami and megastore unit tests + existing customer profile tests

Tsunami is a new layer that sits between business logic code and the
persistence logic. The main manifestation of this layer is
define-domain-class macro that defines an interface to a domain
class. You can then define how to perist in various implementations,
e.g. using define-quake-db-class-bindings for quake and
define-proto-binding & define-megastore-proto-binding for megastore.

Tsunami framework is still a work in progress, and there is a bunch of
outstanding tasks/issues.

As the first application, I refactored customer profile code to use
the tsunami framework. This enables storing of customer profiles in
megastore (or other data stores in the future), while everything else
is stored in Oracle.

Here is the list of other miscellaneous/harder-to-understand changes:

- I changed @id attribute of ContactInfo objects to use the actual
  numeric ID, rather than passing it through encode-record-locator (in
  qres-dev schema only). This required changing XML schema type from
  typeBasicLocatorString to typeBasicID.

- Drop quake/relationships.lisp. Use a more straightforward way to
  associated ADO agencies to customer profiles.

- Customer usernames are now stored as lowercase strings (this means
  that I don't need a separate field in megastore protobuf to
  implement case-insensitive index).

- agency-id permission attribute is now the agency-key (serialized to
  string), not the agency's record ID. This way you don't need to load
  agency to do permission check when all you have is the agency-key

- moved agency-key from core/agencies.lisp to
  lisp/core/agency-types.lisp, so that agency-key type can be used in
  permissions

- add when* test handler that takes a random Lisp expression (as
  opposed to the existing when that takes a variable name and looks at
  whether it is empty)

- remove cc-deleted-error -- there is no such thing as deleting
  cc-info

- refactored cc-information, so that it is used as a value object (ie
  a mostly-immutable object with no identity) in the application. When
  saving to Oracle database, it is saved in the central
  tbl_cc_information table with appropriately populated ownership
  columns (pointing to the customer, journey,
  accountable_doc_container, etc)

- drop unneeded tbl_cc_transaction columns that were caching cc_info
  values

git-svn-id: http://svn.internal.itasoftware.com/svn/ita/trunk/qres/lisp/libs/cl-protobufs@562275 f8382938-511b-0410-9cdd-bb47b084005c
define-proto.lisp
printer.lisp