1 / 25

caCORE SDK 4.1

caCORE SDK 4.1. Satish Patel. SDK 4.1 Features - Iteration 1. Code Generation improvements Abstract classes Marker Interfaces Implicit Inheritance. SDK 4.1 Features - Iteration 1(contd..). [#4150] WS does not handle inheritance properly

cecily
Download Presentation

caCORE SDK 4.1

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. caCORE SDK 4.1 Satish Patel

  2. SDK 4.1 Features - Iteration 1 • Code Generation improvements • Abstract classes • Marker Interfaces • Implicit Inheritance

  3. SDK 4.1 Features - Iteration 1(contd..) • [#4150] WS does not handle inheritance properly • [#4153] WS does not support comma separated nested search paths • [#8951] GetHTML query syntax does not support slashes in the criteria • [#9282] Association to a class in a different package does not work in XSD • [#9392] Uppercase association names generate error in WS • [#9602] Validation error in testing association to a class in a different package • [#9618] The SDK Test Model KEY table causes an SQLException in MySQL • [#10639] Associations in related packages are not checked • [#11189] Search Object drop down is not populated with the correct classnames • [#11191] Generation of inefficient subqueries results in slow performance and timeouts • [#11866] ApplicationService methods do not allow casting of results • [#12454] camel case error • [#12539] inheritance across package results in incorrect hibernate mapping • [#12636] Eager loaded objects are not proxied correctly • [#13110] associations to the child class in the table per hierarchy with leaf in separate table not being validated • [#13111] Super class in separate package generates incorrect HBM files • [#13133] Missing id attribute error in Castor mapping file generation • [#13144] WS getTotalNumberOfRecords returns incorrect number • [#13295] isJoinedSubclass() test in NestedCriteria2HQL is causing query criteria to be ignored • [#13365] Implicit polymorphism: Associations from root class are attributed to subclasses • [#13481] Unmarshalling test for remote client throws exception • [#13577] Interfaces (in a different package) displaced with realization classes in the same package on the web interface

  4. SDK 4.1 Features - Iteration 2 • Code Generation improvements • Primary key generators • Cascade styles • Eager load • Writeable API • CRUD operations • Batch operations • Transaction support

  5. SDK 4.1 Features - Iteration 2 (contd..) • Security expansion • Writable API security • Group level security • CLM Integration • Validator support

  6. SDK 4.1 Features - Iteration 3

  7. Code Generation

  8. Primary Key Generator • Requirement: • Allow users to specify primary key generator per root class • Specification: • Global setting for primary key generator will be specified in configuration file (deploy.properties) • Class level setting will be specified in the UML model • Assume global setting for any class which does not have a specific primary key generator assigned • SDK will perform validation on the generator and the database combination to make sure they are suitable per hibernate specification

  9. Primary Key Generator (contd…)

  10. Cascade Settings • Requirement: • Allow user to specify the combination of cascade setting on the association • Specification: • Cascade setting will be specified on the association in the UML model • SDK will perform validity check on the cascade setting value • SDK will assume cascade setting of “none” if the user has not specified any particular setting

  11. Eager Load Settings • Requirement: • Allow user to specify option of eagerly loading a particular association • Specification: • Eager load setting will be specified on the association in the UML model • SDK will assume associations are to be lazily loaded if eager load setting is not specified

  12. Java API

  13. Delete Object • Requirement: • Allow users to delete object from the database • Basic sequence of operation to be fulfilled • Client provides details of the object to be deleted • SDK deletes the object • SDK returns void • Hibernate takes care of updating the associations based on cascade and inverse-of settings

  14. Create/Insert Operation • Requirement: • Allow users to insert object (create record) in the database. • Basic sequence of operation to be fulfilled • Create a object • Save the object • Return result object to the user

  15. Update Operation • Requirement: • Allow user to perform update operation on object • Basic sequence of operation to be fulfilled • Get a object • Update attributes/associations of the fetched object • Save the object • Return result to the user

  16. DML Style Operations • Insert/Update/Delete Operation • Client specifies the DML operation in HQL syntax • SDK executes the HQL • SDK returns void • Hibernate takes care of updating the associations based on cascade and inverse-of settings • Problem with security enforcement

  17. Batch Operation • Requirement: • Allow users to specify more than one operations in single call • Basic sequence of operation to be fulfilled • Client prepares a list of query operations • Client invokes SDK’s service with query list • SDK iterates through the list and executes all the queries one after other • SDK returns batch response with status for all items

  18. Security Configuration • Security to be enforced on each and every operations • Client can specify who can perform CREATE/UPDATE/DELETE on the domain objects using CSM configuration • Instance and Attribute level security can not be enforced on the writable API in current form

  19. CLM Integration • CLM based auditing can be enabled on writable API with a flag in configuration file • SDK will insert log statements whenever an object is modified through the query • User can perform security configuration using CSM to authorize access on the CLM logs

  20. Validation

  21. Validation of Data • Hibernate Validator • No dependency on using Hibernate and can be used easily in business layer • Annotations in the Java beans for the validation rules • CDE information to be used to determine validation logic • Initially limited to list of valid value only i.e. enumerated value domains • Flexible to handle custom validation logic • Inserted in the SDK service layer using AOP • Custom validation logic • Can be inserted in SDK using AOP as well as Hibernate Validator

  22. Validation Workflow SDK Code Generator (Stage 1) caDSR API Client caDSR API Server Validator Config XMI SDK Code Generator (Stage 2) SDK Middleware System Annotated Java Bean

  23. Configuration File <entry key="pattern"> <bean class="gov.nih.nci.codegen.validator.HibernateValidatorAttribute"> <constructor-arg value="pattern" /> <constructor-arg index="1"> <list> <bean class="gov.nih.nci.codegen.validator.HibernateValidatorConstraint"> <constructor-arg value="org.hibernate.validator.Pattern" /> <constructor-arg index="1"> <map> <entry key="regex" value='"(DEPT|BLDG|FL|RM|APT|STE)"' /> </map> </constructor-arg> </bean> </list> </constructor-arg> </bean> </entry>

  24. Code Example @Pattern(regex="(DEPT|BLDG|FL|RM|APT|STE)") private String pattern; /** * Retrieves the value of the pattern attribute * @return pattern **/ public String getPattern(){ return pattern; } /** * Sets the value of pattern attribute **/ public void setPattern(String pattern){ this.pattern = pattern; }

  25. Questions

More Related