The document discusses the steps for migrating an existing project to Wonder, including:
1) Moving the codebase to Git version control for branching during the migration process.
2) Preparing the codebase by adding packages, creating custom subclasses for components like the editing context and direct actions, and renaming any enum collisions.
3) Starting the actual wonderization by importing Wonder frameworks and removing duplicate jars.
This document provides instructions for using a web page to play YouTube videos in a random, continuous playlist. It includes:
1) Directions to download and view the web page files in a browser.
2) An explanation of the web page's functions like playing all videos, adding new videos, and saving an updated playlist.
3) An overview of the programming and JavaScript functions used to retrieve video data and play videos randomly.
This document discusses various open source Android libraries and tools that can be used to build Android applications more efficiently. It summarizes RoboGuice for dependency injection, ActionBarSherlock for action bar support, libraries like HTTP Request and GSON, and tools like ViewPagerIndicator, Robotium for testing, the Android Maven plugin, and fragments. It encourages leveraging these libraries and tools to build more with less code through reuse and integration of existing components.
The document discusses using a Node.js framework called Connect to build mobile web applications. Connect allows assembling reusable code blocks called middleware to handle common tasks like logging, parsing request bodies, caching, and serving static files. It also provides a simple interface using HTML, CSS, JavaScript, and network protocols like HTTP. Connect makes mobile app development light, networked, and in real-time by reusing pre-built middleware blocks and deploying to browsers for free with an open workflow.
The document discusses using Node.js for real-time web applications by allowing persistent connections and high concurrency. It introduces Connect, a Node.js framework that allows building reusable middleware blocks to handle tasks like logging, caching, compression etc. Examples of common middleware modules like method-override and response-time are provided. The challenges of writing scalable non-blocking servers and handling thousands of concurrent connections are addressed.
JavaScript is a versatile programming language that can be used to add interactivity to web pages. The document provides examples of common JavaScript concepts like variables, functions, objects, loops, and DOM manipulation. It also discusses best practices like minimizing DOM access, controlling scope, and using closures and modules to organize code. Overall, the document serves as a high-level introduction to JavaScript syntax and programming concepts.
The document discusses Android Architecture Components (AAC) including Lifecycles, LiveData, ViewModel, and Room. It provides an example of building a timer application using these components. A TimerListener observes the Android lifecycle and manages a countdown timer. A TimerLiveData observes the timer and notifies observers of changes. A TimerViewModel exposes the timer data and methods to start/stop it. An Activity observes the TimerLiveData to update the UI and handle timer events.
This document provides instructions for using a web page to play YouTube videos in a random, continuous playlist. It includes:
1) Directions to download and view the web page files in a browser.
2) An explanation of the web page's functions like playing all videos, adding new videos, and saving an updated playlist.
3) An overview of the programming and JavaScript functions used to retrieve video data and play videos randomly.
This document discusses various open source Android libraries and tools that can be used to build Android applications more efficiently. It summarizes RoboGuice for dependency injection, ActionBarSherlock for action bar support, libraries like HTTP Request and GSON, and tools like ViewPagerIndicator, Robotium for testing, the Android Maven plugin, and fragments. It encourages leveraging these libraries and tools to build more with less code through reuse and integration of existing components.
The document discusses using a Node.js framework called Connect to build mobile web applications. Connect allows assembling reusable code blocks called middleware to handle common tasks like logging, parsing request bodies, caching, and serving static files. It also provides a simple interface using HTML, CSS, JavaScript, and network protocols like HTTP. Connect makes mobile app development light, networked, and in real-time by reusing pre-built middleware blocks and deploying to browsers for free with an open workflow.
The document discusses using Node.js for real-time web applications by allowing persistent connections and high concurrency. It introduces Connect, a Node.js framework that allows building reusable middleware blocks to handle tasks like logging, caching, compression etc. Examples of common middleware modules like method-override and response-time are provided. The challenges of writing scalable non-blocking servers and handling thousands of concurrent connections are addressed.
JavaScript is a versatile programming language that can be used to add interactivity to web pages. The document provides examples of common JavaScript concepts like variables, functions, objects, loops, and DOM manipulation. It also discusses best practices like minimizing DOM access, controlling scope, and using closures and modules to organize code. Overall, the document serves as a high-level introduction to JavaScript syntax and programming concepts.
The document discusses Android Architecture Components (AAC) including Lifecycles, LiveData, ViewModel, and Room. It provides an example of building a timer application using these components. A TimerListener observes the Android lifecycle and manages a countdown timer. A TimerLiveData observes the timer and notifies observers of changes. A TimerViewModel exposes the timer data and methods to start/stop it. An Activity observes the TimerLiveData to update the UI and handle timer events.
This document discusses iOS application architecture and REST client implementation. It covers common iOS concepts like MVC, UIKit, table views and their data sources. It also describes a Comet architecture using a REST API and database to retrieve and display product data in a table. The controller implements the table view data source and delegate methods to display the data and handle user interactions like tapping rows.
This document discusses enabling SOAP web services using ERJaxWS in WebObjects. It provides examples of how to create a SOAP service from Java classes or a WSDL, call an external SOAP service, handle data mapping and custom types, define web faults, create stateful services, add security, and troubleshoot SOAP services. Resources for further information on JAX-WS, JAXB, and SOAP are also included.
This document discusses various tools and techniques for building and deploying software, including Git, Git hooks, Puppet, native packages, and Maven. It provides examples of using post-receive Git hooks to deploy code to servers, configuring Puppet modules to install packages and configure services, creating native packages with tools like fpm and Ant, and bundling deployment scripts within packages.
The document discusses WOUnit, a unit testing framework for Wonder. It provides features like mocking the editing context, creating dummy objects to bypass validations, and spying on objects. Sample tests are shown to test validation rules and relationships. WOUnit aims to make testing simple, fast and support Wonder features like editing contexts through assertions and annotations like @Rule, @Dummy and @Spy.
This document discusses filtering data in Direct to Web (D2W) by limiting the visibility of data based on the current user or company. It presents two solutions:
1. Modifying fetch specifications at the editing context level to add relationship qualifiers restricting results to the current company. This works but is low-level.
2. Using query and relationship components in D2W that call business logic to generate the appropriate qualifiers and restricted data sources. This provides a cleaner, more reusable approach compared to the first solution.
The document also discusses enhancing relationship components to support restricting fetch specifications to simplify generating qualifiers across different entities and relationships. In summary, it focuses on programmatically filtering data in D2
This document discusses using iOS apps as clients for ERREST servers. It provides an example architecture of an iOS app connecting to an ERREST backend using REST calls. It also includes code snippets showing how to make REST requests using classes like PLRestful and CometAPI that handle the network requests and JSON parsing. The document is intended to explain how to build iOS clients for existing ERREST backends rather than how to code the iOS apps themselves.
Using Nagios to monitor your WO systemsWO Community
Nagios is an open source monitoring tool that has been available since 1999. It is commonly used to monitor servers, services, and applications. The document discusses how to install and configure Nagios on various platforms like CentOS, Ubuntu, and Mac OS X. It also provides examples of how to monitor common services like HTTP, MySQL, disk space, and custom applications using Nagios plugins. Graphing and alerting capabilities are discussed as well. The presentation concludes with a demonstration and Q&A section.
Chaining the Beast - Testing Wonder Applications in the Real WorldWO Community
This document discusses the importance of testing applications in the real world. It covers various types of testing including catching regressions, checking new features, and addressing issues like incorrect data or slow page responses. Specific testing methodologies are mentioned, like verifying models and business logic. The importance of usability testing is also covered, such as checking the appearance and interactivity of applications. Automated testing tools like Selenium are recommended for testing functionality across different browsers. Building invariant test pages can help find faults and browser-specific problems.
Apache Cayenne is an open source object-relational mapping framework for Java. It has been an Apache project since 2006 and has over 17 committers and 9 project management committee members. Cayenne provides tools for mapping database schemas to Java objects and vice versa, as well as tools for querying, caching query results, and handling object lifecycles. It aims to simplify working with relational databases for Java developers in a similar way to how Enterprise Objects Framework simplified it for Objective-C developers.
This document discusses alternatives to using WebObjects for developing web applications. It summarizes the key aspects of a stack that could satisfy former WebObjects developers, including:
- Dependency injection frameworks like Spring and Google Guice that allow loose coupling between classes.
- HTML frameworks like Tapestry that are similar to WebObjects in allowing infinitely nestable page components.
- JAX-RS as a REST framework specification implemented by libraries like Jersey that maps HTTP requests to Java methods.
- Migrating from WebObjects by keeping its philosophies but rewriting code from scratch using these new frameworks, with tools to import existing data models and port components like DirectToWeb and DirectToJavaClient.
The document discusses the WOver, a small mobile robot built using a Raspberry Pi single board computer connected via serial interface to control an Asuro driving module. It provides instructions to connect to its WiFi network and control interface webpage to drive the robot. Details are given on the hardware components used, including the Raspberry Pi, Asuro driving module, and custom operating system on the module to receive motor control commands from the Raspberry Pi. Potential next steps discussed include adding database, games, sensors, power management, camera, and benchmarks.
The document discusses stateful controllers in Direct To Web (D2W) applications built with WebObjects. It provides background on D2W and how controllers were traditionally implemented using ERDBranchDelegate and NextPageDelegate. Stateful controllers improve upon this by allowing controller classes to be reused across multiple pages while maintaining state between pages. This is done by overriding branchChoicesForContext to programmatically define branch choices and storing necessary objects like the editing context. The document provides examples of how stateful controllers can implement common page flows and interactions through utility methods while keeping code DRY and reusable.
This document provides an overview and demonstrations of advanced Apache Cayenne concepts including:
1. Reusing Cayenne and service code between admin apps and discussing object context management.
2. Lifecycle events can be received via callbacks or listeners, with callbacks used for simple initialization and listeners for more complex workflows.
3. Caching in Cayenne includes object caching of entities by ID and query caching of result lists by generated keys, with local caching at the context level and shared caching at the domain level.
4. Demonstrations of object caching, query caching, and turning off cross-context synchronization, using query caching with expiration policies, and considering optimistic locking for performance.
This document discusses deploying WebObjects applications on Windows. It covers setting up the Windows and WebObjects prerequisites, configuring the basic WOStart application launcher and WOSetup, demoing the setup process, and using JavaMonitor and WOTaskD to manage multiple applications across hosts. It also discusses potential issues like debugging WOStart and the WOAdaptor, using IIS or Apache as the web server, and common pitfalls in a Windows deployment. URLs are provided for downloading needed tools and components.
The document discusses various strategies for achieving high availability of web applications and databases. It covers evaluating business requirements, DNS configuration, using cloud infrastructure or owning hardware, basic setups with application and database servers, database replication and clustering options, load balancing tools for Linux and cloud environments, auto scaling features, and monitoring. The key strategies presented include replicating databases, load balancing web traffic, auto-scaling cloud resources, and configuring failover between redundant application and database servers.
This document describes KAAccessControl, a framework for managing user access control and permissions. It provides concise summaries in 3 sentences or less that provide the high level and essential information from the document.
The framework allows defining roles, profiles, lists and managing user permissions through annotations and configuration files. It handles authentication but does not provide the authentication mechanism. The framework manages the current user's profile and permissions and allows impersonating other users through its user service class. Components check permissions by annotating allowed roles and querying the framework's access control services.
This document discusses the "Framework Principal" pattern which allows optimizing resource usage across multiple applications by initializing shared services and configurations in a single starter class. The Framework Principal runs very early and can be used to launch services independently of any application based on configuration properties. It provides examples of how to configure different applications to use the same Framework Principal by specifying different property files and user names for production vs sandbox environments. This allows launching shared services only once across multiple applications rather than separately in each one.
The document describes an in-memory OLAP engine created by Samuel Pelletier to enable fast querying of multidimensional data with millions of facts. It loads data into memory as plain old Java objects (POJOs) for faster access compared to entity objects or SQL queries. Dimensions are modeled as classes to index the facts and compute summarized results. The engine is multithreaded and designed for simplicity and minimal dependencies.
Back to the future with Java 7 (Geekout June/2011)Martijn Verburg
This document provides a summary of Martijn Verburg's presentation titled "Back to the Future with Java 7". The presentation covered several new features in Java 7 including Project Coin additions like strings in switch statements, try-with-resources, and diamond syntax. It also discussed NIO.2 improvements to I/O, invokedynamic, Fork/Join framework, and method handles. The presentation noted that while Java the language has been quiet, the community and platform have grown. It predicted the Java SE future looks stable while JEE and Java ME futures are less certain. The document closed with discussions on the Oracle v. Google lawsuit and the future of JavaFX.
The document discusses using Groovy to improve Java testing. Groovy allows writing tests more concisely using features like closures, native list/map syntax, and dynamic proxies. It also enables mocking collaborators without external libraries. Groovy integrates fully with JUnit and TestNG and helps test exceptions, databases using DbUnit, and drive functional UI tests more easily.
This session of The Ajax Experience 2008 takes a look at the latest features in both Prototype and script.aculo.us, including custom events and how to leverage them, method wrapping for AOP-style programming, sprockets, the refactorings and improvements on Ajax, scheduling and the DOM, the new effects engine, and more.
We wrap up with an overview of the community landscape for these libraries, looking at major helpful resources, prominent peripheral frameworks, and seeing what the future looks like for both Prototype and script.aculo.us.
The document describes GrooScript, a library and tool that converts Groovy code to JavaScript code. Some key points:
- GrooScript is an Apache 2 licensed Java library and command line tool that converts Groovy to equivalent JavaScript code.
- It supports many Groovy features like classes, closures, collections, and basic Groovy syntax but does not support all Java features or complex Groovy features.
- The converted code works with the grooscript.js library and can be used in JavaScript projects or environments like Grails and Gradle.
This document discusses iOS application architecture and REST client implementation. It covers common iOS concepts like MVC, UIKit, table views and their data sources. It also describes a Comet architecture using a REST API and database to retrieve and display product data in a table. The controller implements the table view data source and delegate methods to display the data and handle user interactions like tapping rows.
This document discusses enabling SOAP web services using ERJaxWS in WebObjects. It provides examples of how to create a SOAP service from Java classes or a WSDL, call an external SOAP service, handle data mapping and custom types, define web faults, create stateful services, add security, and troubleshoot SOAP services. Resources for further information on JAX-WS, JAXB, and SOAP are also included.
This document discusses various tools and techniques for building and deploying software, including Git, Git hooks, Puppet, native packages, and Maven. It provides examples of using post-receive Git hooks to deploy code to servers, configuring Puppet modules to install packages and configure services, creating native packages with tools like fpm and Ant, and bundling deployment scripts within packages.
The document discusses WOUnit, a unit testing framework for Wonder. It provides features like mocking the editing context, creating dummy objects to bypass validations, and spying on objects. Sample tests are shown to test validation rules and relationships. WOUnit aims to make testing simple, fast and support Wonder features like editing contexts through assertions and annotations like @Rule, @Dummy and @Spy.
This document discusses filtering data in Direct to Web (D2W) by limiting the visibility of data based on the current user or company. It presents two solutions:
1. Modifying fetch specifications at the editing context level to add relationship qualifiers restricting results to the current company. This works but is low-level.
2. Using query and relationship components in D2W that call business logic to generate the appropriate qualifiers and restricted data sources. This provides a cleaner, more reusable approach compared to the first solution.
The document also discusses enhancing relationship components to support restricting fetch specifications to simplify generating qualifiers across different entities and relationships. In summary, it focuses on programmatically filtering data in D2
This document discusses using iOS apps as clients for ERREST servers. It provides an example architecture of an iOS app connecting to an ERREST backend using REST calls. It also includes code snippets showing how to make REST requests using classes like PLRestful and CometAPI that handle the network requests and JSON parsing. The document is intended to explain how to build iOS clients for existing ERREST backends rather than how to code the iOS apps themselves.
Using Nagios to monitor your WO systemsWO Community
Nagios is an open source monitoring tool that has been available since 1999. It is commonly used to monitor servers, services, and applications. The document discusses how to install and configure Nagios on various platforms like CentOS, Ubuntu, and Mac OS X. It also provides examples of how to monitor common services like HTTP, MySQL, disk space, and custom applications using Nagios plugins. Graphing and alerting capabilities are discussed as well. The presentation concludes with a demonstration and Q&A section.
Chaining the Beast - Testing Wonder Applications in the Real WorldWO Community
This document discusses the importance of testing applications in the real world. It covers various types of testing including catching regressions, checking new features, and addressing issues like incorrect data or slow page responses. Specific testing methodologies are mentioned, like verifying models and business logic. The importance of usability testing is also covered, such as checking the appearance and interactivity of applications. Automated testing tools like Selenium are recommended for testing functionality across different browsers. Building invariant test pages can help find faults and browser-specific problems.
Apache Cayenne is an open source object-relational mapping framework for Java. It has been an Apache project since 2006 and has over 17 committers and 9 project management committee members. Cayenne provides tools for mapping database schemas to Java objects and vice versa, as well as tools for querying, caching query results, and handling object lifecycles. It aims to simplify working with relational databases for Java developers in a similar way to how Enterprise Objects Framework simplified it for Objective-C developers.
This document discusses alternatives to using WebObjects for developing web applications. It summarizes the key aspects of a stack that could satisfy former WebObjects developers, including:
- Dependency injection frameworks like Spring and Google Guice that allow loose coupling between classes.
- HTML frameworks like Tapestry that are similar to WebObjects in allowing infinitely nestable page components.
- JAX-RS as a REST framework specification implemented by libraries like Jersey that maps HTTP requests to Java methods.
- Migrating from WebObjects by keeping its philosophies but rewriting code from scratch using these new frameworks, with tools to import existing data models and port components like DirectToWeb and DirectToJavaClient.
The document discusses the WOver, a small mobile robot built using a Raspberry Pi single board computer connected via serial interface to control an Asuro driving module. It provides instructions to connect to its WiFi network and control interface webpage to drive the robot. Details are given on the hardware components used, including the Raspberry Pi, Asuro driving module, and custom operating system on the module to receive motor control commands from the Raspberry Pi. Potential next steps discussed include adding database, games, sensors, power management, camera, and benchmarks.
The document discusses stateful controllers in Direct To Web (D2W) applications built with WebObjects. It provides background on D2W and how controllers were traditionally implemented using ERDBranchDelegate and NextPageDelegate. Stateful controllers improve upon this by allowing controller classes to be reused across multiple pages while maintaining state between pages. This is done by overriding branchChoicesForContext to programmatically define branch choices and storing necessary objects like the editing context. The document provides examples of how stateful controllers can implement common page flows and interactions through utility methods while keeping code DRY and reusable.
This document provides an overview and demonstrations of advanced Apache Cayenne concepts including:
1. Reusing Cayenne and service code between admin apps and discussing object context management.
2. Lifecycle events can be received via callbacks or listeners, with callbacks used for simple initialization and listeners for more complex workflows.
3. Caching in Cayenne includes object caching of entities by ID and query caching of result lists by generated keys, with local caching at the context level and shared caching at the domain level.
4. Demonstrations of object caching, query caching, and turning off cross-context synchronization, using query caching with expiration policies, and considering optimistic locking for performance.
This document discusses deploying WebObjects applications on Windows. It covers setting up the Windows and WebObjects prerequisites, configuring the basic WOStart application launcher and WOSetup, demoing the setup process, and using JavaMonitor and WOTaskD to manage multiple applications across hosts. It also discusses potential issues like debugging WOStart and the WOAdaptor, using IIS or Apache as the web server, and common pitfalls in a Windows deployment. URLs are provided for downloading needed tools and components.
The document discusses various strategies for achieving high availability of web applications and databases. It covers evaluating business requirements, DNS configuration, using cloud infrastructure or owning hardware, basic setups with application and database servers, database replication and clustering options, load balancing tools for Linux and cloud environments, auto scaling features, and monitoring. The key strategies presented include replicating databases, load balancing web traffic, auto-scaling cloud resources, and configuring failover between redundant application and database servers.
This document describes KAAccessControl, a framework for managing user access control and permissions. It provides concise summaries in 3 sentences or less that provide the high level and essential information from the document.
The framework allows defining roles, profiles, lists and managing user permissions through annotations and configuration files. It handles authentication but does not provide the authentication mechanism. The framework manages the current user's profile and permissions and allows impersonating other users through its user service class. Components check permissions by annotating allowed roles and querying the framework's access control services.
This document discusses the "Framework Principal" pattern which allows optimizing resource usage across multiple applications by initializing shared services and configurations in a single starter class. The Framework Principal runs very early and can be used to launch services independently of any application based on configuration properties. It provides examples of how to configure different applications to use the same Framework Principal by specifying different property files and user names for production vs sandbox environments. This allows launching shared services only once across multiple applications rather than separately in each one.
The document describes an in-memory OLAP engine created by Samuel Pelletier to enable fast querying of multidimensional data with millions of facts. It loads data into memory as plain old Java objects (POJOs) for faster access compared to entity objects or SQL queries. Dimensions are modeled as classes to index the facts and compute summarized results. The engine is multithreaded and designed for simplicity and minimal dependencies.
Back to the future with Java 7 (Geekout June/2011)Martijn Verburg
This document provides a summary of Martijn Verburg's presentation titled "Back to the Future with Java 7". The presentation covered several new features in Java 7 including Project Coin additions like strings in switch statements, try-with-resources, and diamond syntax. It also discussed NIO.2 improvements to I/O, invokedynamic, Fork/Join framework, and method handles. The presentation noted that while Java the language has been quiet, the community and platform have grown. It predicted the Java SE future looks stable while JEE and Java ME futures are less certain. The document closed with discussions on the Oracle v. Google lawsuit and the future of JavaFX.
The document discusses using Groovy to improve Java testing. Groovy allows writing tests more concisely using features like closures, native list/map syntax, and dynamic proxies. It also enables mocking collaborators without external libraries. Groovy integrates fully with JUnit and TestNG and helps test exceptions, databases using DbUnit, and drive functional UI tests more easily.
This session of The Ajax Experience 2008 takes a look at the latest features in both Prototype and script.aculo.us, including custom events and how to leverage them, method wrapping for AOP-style programming, sprockets, the refactorings and improvements on Ajax, scheduling and the DOM, the new effects engine, and more.
We wrap up with an overview of the community landscape for these libraries, looking at major helpful resources, prominent peripheral frameworks, and seeing what the future looks like for both Prototype and script.aculo.us.
The document describes GrooScript, a library and tool that converts Groovy code to JavaScript code. Some key points:
- GrooScript is an Apache 2 licensed Java library and command line tool that converts Groovy to equivalent JavaScript code.
- It supports many Groovy features like classes, closures, collections, and basic Groovy syntax but does not support all Java features or complex Groovy features.
- The converted code works with the grooscript.js library and can be used in JavaScript projects or environments like Grails and Gradle.
Modeling Patterns for JavaScript Browser-Based GamesRay Toal
This document proposes JavaScript patterns for modeling browser-based game objects and types without using frameworks. It describes challenges for browser games and recent advances in JavaScript. Patterns are presented for modules, types, and inheritance using prototypes instead of classes. A root game object type and projectile subtype are implemented as examples. The patterns were applied in an HTML5 game and several JavaScript game engines are surveyed.
AD1387: Outside The Box: Integrating with Non-Domino Apps using XPages and Ja...panagenda
Users don’t care where their data lives. They just want to get their work done quickly and efficiently. They would prefer to do their work without opening three different applications and five different browser tabs. That means your applications need to share data and work well with other applications. So what can you do? Use XPages and Java, of course!
Kathy and Julian will give you integration tips and examples of connecting your XPages apps to both IBM and non IBM technologies. Walk away with a head full of knowledge and a sample database full of working code. NOTE: this session is geared towards XPages and Java developers, beginners welcome!
A presentation from Julian Robichaux (panagenda) and Kathy Brown (PSC Group).
This document discusses best practices for developing useful APIs. It recommends treating all reusable code as an API and following principles like using minimal dependencies and packaging code appropriately. It also provides examples of API design patterns at the module, class, and method level, such as using dependency injection, builder patterns, and exception handling conventions. The goal is to make APIs easy to read, use, extend, and hard to misuse by learning from open source projects and following trends in API design.
The document discusses how Groovy can boost testing productivity. It provides an overview of Groovy and how it can simplify testing through features like mocking, integrated support for testing frameworks, and easier database and functional testing. Examples are given of using Groovy for testing exceptions, taglibs, and databases. Frameworks like JUnit, TestNG, DbUnit, Canoo WebTest, and EasyB are highlighted for testing with Groovy.
Boosting Your Testing Productivity with GroovyJames Williams
The document discusses how Groovy can boost testing productivity. It provides an overview of Groovy and how it can simplify testing through features like mocking, exceptions handling, and integration with testing frameworks. It also describes how to test databases, taglibs, and applications through techniques like DbUnit, FEST, and BDD tools like Easyb that can be used with Groovy.
This document introduces GrooScript, an open source library that converts Groovy code to JavaScript. It provides examples of Groovy code and the corresponding JavaScript output. Key points covered include:
- GrooScript allows continued development in Groovy while outputting JavaScript that can be used in browsers.
- It supports common Groovy features like closures, meta programming and types while making the code more JavaScript friendly.
- The library can be used directly, or with Gradle and Grails plugins to facilitate conversion of Groovy code to JavaScript.
- While not a perfect translation, GrooScript enables continued use of the Groovy development experience for client-side code. The author provides several
Webinar: MongoDB Persistence with Java and MorphiaMongoDB
MongoDB is the leading noSQL database and as with any new technology, some of the biggest questions are about tools and integration. This webinar will cover how to use MongoDB from a Java application and introduce Morphia, the object document mapping library. It will cover the essential features of the framework with examples before moving on to some of the more advanced and upcoming features such as text search and aggregation framework support.
Understanding bytecode and what bytecode is likely to be generated by a Java compiler helps the Java programmer in the same way that knowledge of assembler helps the C or C++ programmer. Java bytecode is the form of instructions that Java virtual machine executes. This knowledge is crucial when debugging and doing performance and memory usage tuning. The presenter will share his knowledge on what bytecode means for your platform and how to create compiler while using some awesome tools.
A re introduction to webpack - reactfoo - mumbaiPraveen Puglia
I gave a talk at ReactFoo Mumbai about the history of how we arrived at the module bundlers we have today, specifically webpack. We walked through a live coding demo where I built a working webpack configuration for a working Vue application and then talked about the future of webpack.
Java Universal super class java.lang.Object is discussed comprehensively with code snippets.
Also covers:
a) Why we need inheritance and dynamic method dispatch
b) Need of a universal parent
c) Delegation and proxies
d) toString(), clone(), equals(), notify()
The document discusses test-driven development (TDD) and refactoring. It provides examples of unit test fixtures, exercising the system under test (SUT), and verifying results. It also discusses refactoring code to remove smells like duplicated code through techniques like extracting methods. The goal is to use TDD to write code that works and is clean through small, incremental changes while ensuring it continues to work by passing all tests.
Similar to Migrating existing Projects to Wonder (20)
Localizing your apps for multibyte languagesWO Community
This document discusses considerations for localizing apps to support multibyte languages. It covers setting the encoding in Eclipse, Ant builds, and database connections to UTF-8. It also discusses features of Japanese like reading direction from right to left, lack of word spacing, and the different character sets of kanji, hiragana, katakana and their encodings. The document recommends converting all characters to single byte widths before storing in databases for ease of use and searching.
WOdka is a WebObjects framework that was originally developed in Japan. It includes several frameworks like AuditTrail, JQueryMobileD2W, and ModernistD2W. WOdka has a unified dashboard for developers and administrators. It provides features like logical delete, roles and permissions, and integration with NotificationCenter. WOdka supports modern techniques like CSS3, multi-language, and REST. It is actively developed and maintained by developers in Japan and internationally.
The document discusses jQuery ThemeRoller templates for DirectToWeb (D2W) applications. D2W uses rules and templates to generate user interfaces from data models with minimal code. The jQuery ThemeRoller templates provide a complete renovation of D2W templates using jQuery UI components and themes. This allows user interfaces to be easily branded by generating new themes with jQuery ThemeRoller. The templates utilize reusable jQuery components in a component model to build custom components. Setting up an application to use the themes involves including jQuery resources and assigning a theme class.
The document outlines an agenda for a workshop on understanding and using Git held on July 2, 2012 in Montreal. The workshop objectives are to gain a better understanding of Git and get hands-on experience using it. The topics to be covered include an introduction to Git, its history and concepts, environment setup, and demos of hands-on Git scenarios.
The document proposes forming a new association to address problems facing a minority organization competing against a larger competitor. It identifies issues like membership, workforce, and lack of awareness. The association would have a president, committees, and work to improve academic value, identity, direction, and execution. It would seek non-profit status and tax benefits while defining goals to legitimize the organization and increase publication and recruitment.
This document outlines an agenda for a WebObjects optimization conference on June 30 - July 2, 2012 in Montreal. The sessions will cover optimizing WebObjects applications from the browser to the database including techniques like caching, batch fetching, SQL monitoring and more. Chuck Hill from Global Village Consulting will discuss strategies for optimizing applications beyond the end-of-model including tools like ERXEnterpriseObjectCache and ERXBatchingDisplayGroup. Time will also be spent on database tuning, avoiding unnecessary relationships in models and leveraging raw rows when appropriate.
This document discusses different types of components in WebObjects, including standard components, non-synchronizing components, stateless components, and dynamic components. It provides examples of how to implement each type of component by subclassing the appropriate base classes and overriding specific methods. The document also includes information on performance considerations for each type of component and recommendations for when each type should be used.
This document outlines an agenda for a REST API training session occurring June 30 - July 2, 2012 in Montreal. It will cover the basics of REST including concepts like URLs, HTTP verbs, statelessness and representations. It will demonstrate building a basic blog REST service in ERRest including setting routes, controllers, formats and filters. The training will cover adding basic CRUD routes, using query arguments, and advanced topics like HTML routes.
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
“An Outlook of the Ongoing and Future Relationship between Blockchain Technologies and Process-aware Information Systems.” Invited talk at the joint workshop on Blockchain for Information Systems (BC4IS) and Blockchain for Trusted Data Sharing (B4TDS), co-located with with the 36th International Conference on Advanced Information Systems Engineering (CAiSE), 3 June 2024, Limassol, Cyprus.
zkStudyClub - Reef: Fast Succinct Non-Interactive Zero-Knowledge Regex ProofsAlex Pruden
This paper presents Reef, a system for generating publicly verifiable succinct non-interactive zero-knowledge proofs that a committed document matches or does not match a regular expression. We describe applications such as proving the strength of passwords, the provenance of email despite redactions, the validity of oblivious DNS queries, and the existence of mutations in DNA. Reef supports the Perl Compatible Regular Expression syntax, including wildcards, alternation, ranges, capture groups, Kleene star, negations, and lookarounds. Reef introduces a new type of automata, Skipping Alternating Finite Automata (SAFA), that skips irrelevant parts of a document when producing proofs without undermining soundness, and instantiates SAFA with a lookup argument. Our experimental evaluation confirms that Reef can generate proofs for documents with 32M characters; the proofs are small and cheap to verify (under a second).
Paper: https://eprint.iacr.org/2023/1886
Essentials of Automations: The Art of Triggers and Actions in FMESafe Software
In this second installment of our Essentials of Automations webinar series, we’ll explore the landscape of triggers and actions, guiding you through the nuances of authoring and adapting workspaces for seamless automations. Gain an understanding of the full spectrum of triggers and actions available in FME, empowering you to enhance your workspaces for efficient automation.
We’ll kick things off by showcasing the most commonly used event-based triggers, introducing you to various automation workflows like manual triggers, schedules, directory watchers, and more. Plus, see how these elements play out in real scenarios.
Whether you’re tweaking your current setup or building from the ground up, this session will arm you with the tools and insights needed to transform your FME usage into a powerhouse of productivity. Join us to discover effective strategies that simplify complex processes, enhancing your productivity and transforming your data management practices with FME. Let’s turn complexity into clarity and make your workspaces work wonders!
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...Neo4j
Leonard Jayamohan, Partner & Generative AI Lead, Deloitte
This keynote will reveal how Deloitte leverages Neo4j’s graph power for groundbreaking digital twin solutions, achieving a staggering 100x performance boost. Discover the essential role knowledge graphs play in successful generative AI implementations. Plus, get an exclusive look at an innovative Neo4j + Generative AI solution Deloitte is developing in-house.
Threats to mobile devices are more prevalent and increasing in scope and complexity. Users of mobile devices desire to take full advantage of the features
available on those devices, but many of the features provide convenience and capability but sacrifice security. This best practices guide outlines steps the users can take to better protect personal devices and information.
A tale of scale & speed: How the US Navy is enabling software delivery from l...sonjaschweigert1
Rapid and secure feature delivery is a goal across every application team and every branch of the DoD. The Navy’s DevSecOps platform, Party Barge, has achieved:
- Reduction in onboarding time from 5 weeks to 1 day
- Improved developer experience and productivity through actionable findings and reduction of false positives
- Maintenance of superior security standards and inherent policy enforcement with Authorization to Operate (ATO)
Development teams can ship efficiently and ensure applications are cyber ready for Navy Authorizing Officials (AOs). In this webinar, Sigma Defense and Anchore will give attendees a look behind the scenes and demo secure pipeline automation and security artifacts that speed up application ATO and time to production.
We will cover:
- How to remove silos in DevSecOps
- How to build efficient development pipeline roles and component templates
- How to deliver security artifacts that matter for ATO’s (SBOMs, vulnerability reports, and policy evidence)
- How to streamline operations with automated policy checks on container images
GridMate - End to end testing is a critical piece to ensure quality and avoid...ThomasParaiso2
End to end testing is a critical piece to ensure quality and avoid regressions. In this session, we share our journey building an E2E testing pipeline for GridMate components (LWC and Aura) using Cypress, JSForce, FakerJS…
In his public lecture, Christian Timmerer provides insights into the fascinating history of video streaming, starting from its humble beginnings before YouTube to the groundbreaking technologies that now dominate platforms like Netflix and ORF ON. Timmerer also presents provocative contributions of his own that have significantly influenced the industry. He concludes by looking at future challenges and invites the audience to join in a discussion.
UiPath Test Automation using UiPath Test Suite series, part 6DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 6. In this session, we will cover Test Automation with generative AI and Open AI.
UiPath Test Automation with generative AI and Open AI webinar offers an in-depth exploration of leveraging cutting-edge technologies for test automation within the UiPath platform. Attendees will delve into the integration of generative AI, a test automation solution, with Open AI advanced natural language processing capabilities.
Throughout the session, participants will discover how this synergy empowers testers to automate repetitive tasks, enhance testing accuracy, and expedite the software testing life cycle. Topics covered include the seamless integration process, practical use cases, and the benefits of harnessing AI-driven automation for UiPath testing initiatives. By attending this webinar, testers, and automation professionals can gain valuable insights into harnessing the power of AI to optimize their test automation workflows within the UiPath ecosystem, ultimately driving efficiency and quality in software development processes.
What will you get from this session?
1. Insights into integrating generative AI.
2. Understanding how this integration enhances test automation within the UiPath platform
3. Practical demonstrations
4. Exploration of real-world use cases illustrating the benefits of AI-driven test automation for UiPath
Topics covered:
What is generative AI
Test Automation with generative AI and Open AI.
UiPath integration with generative AI
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Full-RAG: A modern architecture for hyper-personalizationZilliz
Mike Del Balso, CEO & Co-Founder at Tecton, presents "Full RAG," a novel approach to AI recommendation systems, aiming to push beyond the limitations of traditional models through a deep integration of contextual insights and real-time data, leveraging the Retrieval-Augmented Generation architecture. This talk will outline Full RAG's potential to significantly enhance personalization, address engineering challenges such as data management and model training, and introduce data enrichment with reranking as a key solution. Attendees will gain crucial insights into the importance of hyperpersonalization in AI, the capabilities of Full RAG for advanced personalization, and strategies for managing complex data integrations for deploying cutting-edge AI solutions.
2. • Existing application of some complexity
• Using perhaps custom frameworks, but not yet Wonder
• Want to use Wonder for several reasons, but uncertain where to
start and how to manage the migration process
The Task
Samstag, 22. Juni 13
3. Goals
• Make the switch at a chosen, planned point in time
• Being able to switch back to the non-Wonder version if
problems come up in production
• Identify which steps to do when, and how
Samstag, 22. Juni 13
4. The Big Steps
• Move to Git (if you haven‘t already)
• Prepare the code base ahead of the actual wonderization
• Create a wonderization branch
• Wonderize in that branch, periodically merge new stuff from
your main branch
• Release and celebrate
Samstag, 22. Juni 13
5. Prep step: Move to Git
• You‘ll need branches during the migration
• Wonder is Git-based anyway
• It just makes everything easier
• Plan some time to get up to speed using Git first
• Use Sourcetree
Samstag, 22. Juni 13
6. Prep step: Move to Git
Time
release branches
masterdevelop hotfixes
feature
branches
Feature
for future
release
Tag
1.0
Major
feature for
next release
From this point on,
“next release”
means the release
after 1.0
Severe bug
fixed for
production:
hotfix 0.2
Bugfixes from
rel. branch
may be
continuously
merged back
into develop
Tag
0.1
Tag
0.2
Incorporate
bugfix in
develop
Only
bugfixes!
Start of
release
branch for
1.0
Author: Vincent Driessen
Samstag, 22. Juni 13
7. Prep step: Move to Git
Time
release branches
masterdevelop hotfixes
feature
branches
Feature
for future
release
Major
feature for
next release
Severe bug
fixed for
production:
hotfix 0.2
Tag
0.1
Tag
0.2
Incorporate
bugfix in
develop
Start ofSamstag, 22. Juni 13
8. Prep step: Move to Git
release
Tag
1.0
From this point on,
“next release”
means the release
after 1.0
Bugfixes from
rel. branch
may be
Tag
0.2
Incorporate
bugfix in
develop
Only
bugfixes!
Start of
release
branch for
1.0
Samstag, 22. Juni 13
9. Prep step: Move to Git
Tag
1.0
From this point on,
“next release”
means the release
after 1.0
Bugfixes from
rel. branch
may be
continuously
merged back
into develop
Only
bugfixes!
Start of
release
branch for
1.0
Samstag, 22. Juni 13
10. Managing Wonderization in Git
first wonderized release
second wonderized release
conventional version as fallback
conventional version as fallback
wonderized version merged into main
1.0
1.0
develop wonderize
1.1
feature
1.2
1.2
1.3
1.3
2.0
1.2
Samstag, 22. Juni 13
11. Prep step: Java packages
• You can‘t inherit from packaged classes if your classes aren‘t in
packages, too
• So if you haven‘t already, create packages and move all your
sources into them
• Benefit: clarified namespaces for your stuff
Samstag, 22. Juni 13
12. Java packages gotchas
• Getters and setters in components need to be(come) public
• Check class.getName() calls to become class.getSimpleName()
• Class.forName() needs full packaged path
• Overridden methods in enums become unreachable code in WO
bindings
Samstag, 22. Juni 13
13. public enum ContentType {
! literature {
! ! @Override public String cssClassName() { return "read"; }
! },
! film {
! ! @Override public String cssClassName() { return "watch"; }
! },
! music {
! ! @Override public String cssClassName() { return "listen"; }
! };
!
! public abstract String cssClassName();
! public boolean isAvailable() { return true; }
}
Packages: overriding enum methods
Samstag, 22. Juni 13
14. Packages: overriding enum methods
public enum ContentType {
! literature {
! ! @Override public String cssClassName() { return "read"; }
! },
! film {
! ! @Override public String cssClassName() { return "watch"; }
! },
! music {
! ! @Override public String cssClassName() { return "listen"; }
! },
! pr0n {
! ! @Override public String cssClassName() {
! ! ! return getUser().isAdult() ? "watch" : "nothingForYou";
! ! }
! };
!
! public abstract String cssClassName();
}
Samstag, 22. Juni 13
16. Packages: overriding enum methods
public enum ContentType implements NSKeyValueCoding {
! literature {
! ! @Override public String cssClassName() { return "read"; }
! },
! film {
! ! @Override public String cssClassName() { return "watch"; }
! },
! music {
! ! @Override public String cssClassName() { return "listen"; }
! },
! pr0n {
! ! @Override public String cssClassName() {
! ! ! return getUser().isAdult() ? "watch" : "nothingForYou";
! ! }
! };
! !
! public abstract String cssClassName();
! @Override public void takeValueForKey( Object obj, String s ) { return; }
! @Override public Object valueForKey( String s ) {
! ! try {
! ! ! return this.getClass().getMethod( s, (Class<?>[]) null ).invoke( this, (Object[]) null );
! ! } catch( Exception e ) {
! ! ! throw new RuntimeException( e );
! ! }
! }
}
Samstag, 22. Juni 13
17. Prep step: own EC class
• You gain a lot of flexibility by using your own EOEditingContext
subclass
• example: logging on saveChanges() or invalidateAllObjects()
• example: undoManager().removeAllActions() after saves
• Changing the superclass later to ERXEC becomes easy
Samstag, 22. Juni 13
18. Prep step: own DA class
• Create a common superclass between concrete DirectAction
classes and WODirectAction
• Changing the superclass later to ERXDirectAction becomes easy
Samstag, 22. Juni 13
19. Prep step: own logging class
• Create your own org.apache.log4j.Logger subclass
• Changing the superclass later to ERXLogger becomes easy
Samstag, 22. Juni 13
20. import org.apache.log4j.Logger;
public class MyLogger extends Logger {
! public MyLogger( String name ) {
! ! super( name );
! }
! public static Factory factory = null;
! static {
! ! String factoryClassName = MyLogger.Factory.class.getName();
! ! try {
! ! ! MyLogger.factory = (Factory) Class.forName( factoryClassName ).newInstance();
! ! } catch( Exception ex ) {
! ! ! System.err.println( "Exception while creating logger factory of class " + factoryClassName + ": " + ex );
! ! }
! }
! public static class Factory implements org.apache.log4j.spi.LoggerFactory {
! ! @Override
! ! public Logger makeNewLoggerInstance( String name ) {
! ! ! return new MyLogger( name );
! ! }
! ! public void loggingConfigurationDidChange() {
! ! }
! }
Your own logging class (1/2)
Samstag, 22. Juni 13
21. ! public static MyLogger getMyLogger( String name ) {
! ! Logger logger = MyLogger.getLogger( name );
! ! if( logger != null && ! (logger instanceof MyLogger) ) {
! ! ! throw new RuntimeException(
! ! ! ! "Can't load Logger for ""
! ! ! ! + name
! ! ! ! + "" because it is not of class MyLogger but ""
! ! ! ! + logger.getClass().getName()
! ! ! ! + "". Check if there is a "log4j.loggerFactory=er.extensions.Logger$Factory" line in your properties."
! ! ! );
! ! }
! ! return (MyLogger) logger;
! }
! public static Logger getLogger( String name ) {
! ! return Logger.getLogger( name, MyLogger.factory );
! }
! public static MyLogger getMyLogger( Class clazz ) {
! ! return MyLogger.getMyLogger( clazz.getName() );
! }
! public static Logger getLogger( Class clazz ) {
! ! return MyLogger.getMyLogger( clazz );
! }
}
Your own logging class (2/2)
Samstag, 22. Juni 13
22. Prep step: rename enums
• ERXKey constants in new templates could collide with enum
names
• Common collision pattern: uppercase enum with same name as
EO attribute
• Eclipse refactoring tools are your friend
• Make this a separate commit
Samstag, 22. Juni 13
23. public class MyFlightRoute extends _MyFlightRoute {
! public static enum STATUS {
! ! obsolete,
! ! current,
! ! preliminary,
! ! deleted;
! }
! public void setStatus( STATUS status ) {
! ! super.setStatus( status.name() );
! }
}
enum renames
Samstag, 22. Juni 13
24. public class MyFlightRoute extends _MyFlightRoute {
! public static enum STATUS {
! ! obsolete,
! ! current,
! ! preliminary,
! ! deleted;
! }
! public void setStatus( STATUS status ) {
! ! super.setStatus( status.name() );
! }
}
public abstract class _MyFlightRoute extends MyEOGenericRecord {
! public static final ERXKey<String> STATUS = new ERXKey<String>("status");
! public static final String STATUS_KEY = STATUS.key();
}
enum renames
Samstag, 22. Juni 13
25. public class MyFlightRoute extends _MyFlightRoute {
! public static enum STATUS {
! ! obsolete,
! ! current,
! ! preliminary,
! ! deleted;
! }
! public void setStatus( STATUS status ) {
! ! super.setStatus( status.name() );
! }
}
public abstract class _MyFlightRoute extends MyEOGenericRecord {
! public static final ERXKey<String> STATUS = new ERXKey<String>("status");
! public static final String STATUS_KEY = STATUS.key();
}
enum renames
Samstag, 22. Juni 13
26. public class MyFlightRoute extends _MyFlightRoute {
! public static enum FRSTATUS {
! ! obsolete,
! ! current,
! ! preliminary,
! ! deleted;
! }
! public void setStatus( FRSTATUS status ) {
! ! super.setStatus( status.name() );
! }
}
public abstract class _MyFlightRoute extends MyEOGenericRecord {
! public static final ERXKey<String> STATUS = new ERXKey<String>("status");
! public static final String STATUS_KEY = STATUS.key();
}
enum renames
Samstag, 22. Juni 13
28. Wonderization: Frameworks
• Now is the time to start the actual wonderization
• Start by the usual way to import Wonder into Eclipse
• Then add ERJars, ERExtensions,WOOgnl and Wonder‘s
JavaWOExtensions to your project
• And ERPrototypes if you want to use them
• Remove log4j and potentially other jars that are contained in
ERJars (check version compatibilities)
Samstag, 22. Juni 13
29. Properties file
• Wonder manages nearly all settings through Properties
• Live in file Resources/Properties
• You have to create at least a minimal file to start with
Samstag, 22. Juni 13
31. Application.java
• Requirement: subclass ERXApplication
• If you subclassed a custom base class instead of WOApplication,
you can either make that inherit ERXApplication, or copy the
methods you need over to your Application class.
Samstag, 22. Juni 13
32. public class Application extends ERXApplication {
! public static void main( String[] argv ) {
! ! ERXApplication.main( argv, Application.class );
! }
Application.java (1/2)
Samstag, 22. Juni 13
33. public class Application extends ERXApplication {
! public static void main( String[] argv ) {
! ! ERXApplication.main( argv, Application.class );
! }
! public Application() {
! ! WOMessage.setDefaultEncoding( "UTF-8" );
! ! ERXMessageEncoding.setDefaultEncodingForAllLanguages( "UTF-8" );
! ! // ...and whatever else you need to have here, but not more.
! ! log.info( "######### Application startup complete #########" );
! }
Application.java (1/2)
Samstag, 22. Juni 13
34. public class Application extends ERXApplication {
! public static void main( String[] argv ) {
! ! ERXApplication.main( argv, Application.class );
! }
! public Application() {
! ! WOMessage.setDefaultEncoding( "UTF-8" );
! ! ERXMessageEncoding.setDefaultEncodingForAllLanguages( "UTF-8" );
! ! // ...and whatever else you need to have here, but not more.
! ! log.info( "######### Application startup complete #########" );
! }
! // everything that can be deferred better goes here instead
! @Override public void didFinishLaunching() {
! ! new ERXShutdownHook() {
! ! ! @Override public void hook() {
! ! ! ! // cleanup that needs to run when application is shut down
! ! ! }
! ! };
! ! // example for project-specific stuff
! ! taskManager = new BackgroundTaskManager();
! ! taskManager.newRecurringTask( new MySystemState.SystemStateUpdaterTask(), 60 );
! ! super.didFinishLaunching();
! ! log.info( "######### post-startup sequence complete #########" );
! }
Application.java (1/2)
Samstag, 22. Juni 13
35. public class Application extends ERXApplication {
! public static void main( String[] argv ) {
! ! ERXApplication.main( argv, Application.class );
! }
! public Application() {
! ! WOMessage.setDefaultEncoding( "UTF-8" );
! ! ERXMessageEncoding.setDefaultEncodingForAllLanguages( "UTF-8" );
! ! // ...and whatever else you need to have here, but not more.
! ! log.info( "######### Application startup complete #########" );
! }
! // everything that can be deferred better goes here instead
! @Override public void didFinishLaunching() {
! ! new ERXShutdownHook() {
! ! ! @Override public void hook() {
! ! ! ! // cleanup that needs to run when application is shut down
! ! ! }
! ! };
! ! // example for project-specific stuff
! ! taskManager = new BackgroundTaskManager();
! ! taskManager.newRecurringTask( new MySystemState.SystemStateUpdaterTask(), 60 );
! ! super.didFinishLaunching();
! ! log.info( "######### post-startup sequence complete #########" );
! }
Application.java (1/2)
Samstag, 22. Juni 13
37. ! // instead of using a Property, this switches gzip on/off based on system type
! @Override public boolean responseCompressionEnabled() {
! ! switch( systemType() ) {
! ! ! case TESTING! ! : return true;
! ! ! case DEVELOPMENT! : return true;
! ! default!! ! ! : return false; // gzip done by load balancer
! ! }
! }
! @Override protected void migrationsWillRun( ERXMigrator migrator ) {
! ! log.info( "Starting migrations" );
! }
!
! @Override protected void migrationsDidRun( ERXMigrator migrator ) {
! ! log.info( "Finished migrations" );
! }
}
Application.java (2/2)
Samstag, 22. Juni 13
38. ! // instead of using a Property, this switches gzip on/off based on system type
! @Override public boolean responseCompressionEnabled() {
! ! switch( systemType() ) {
! ! ! case TESTING! ! : return true;
! ! ! case DEVELOPMENT! : return true;
! ! default!! ! ! : return false; // gzip done by load balancer
! ! }
! }
! // the default context logging for exceptions is a bit too bulky for my taste, so strip that down a bit
! @Override public NSMutableDictionary extraInformationForExceptionInContext( Exception e, WOContext context ) {
! ! NSMutableDictionary<String,Object> extraInfo = ERXRuntimeUtilities.informationForException( e );
! ! // copy informatinForContext() from ERXApplication, override and strip down
! ! extraInfo.addEntriesFromDictionary( informationForContext( context ) );
! ! extraInfo.addEntriesFromDictionary( ERXRuntimeUtilities.informationForBundles() );
! ! return extraInfo;
! }
! @Override protected void migrationsWillRun( ERXMigrator migrator ) {
! ! log.info( "Starting migrations" );
! }
!
! @Override protected void migrationsDidRun( ERXMigrator migrator ) {
! ! log.info( "Finished migrations" );
! }
}
Application.java (2/2)
Samstag, 22. Juni 13
39. Session.java
• Requirement: subclass ERXSession
• No code to show, nothing special to adapt
• Except when you had used MultiECLockManager
• If you did and you want to switch to ERXEC autolocking,
remove any code related to MultiECLockManager from your
Session class
Samstag, 22. Juni 13
40. MyEditingContext.java
• Recommendation: subclass ERXEC
• You need to implement a factory
• You can have multiple factories, like one that produces
autolocking contexts, and another for manual locking, without
having different classes.
Samstag, 22. Juni 13
48. autolock vs. manual
• In general, autolocking is the right choice for almost everything
• Consider using manual locking for db-intensive background tasks
• Main autolocking tradeoff: looots of lock/unlock calls that could
become a significant overhead, depending on what you‘re doing
Samstag, 22. Juni 13
51. ERXGenericRecord
• Requirement: subclass ERXGenericRecord
• With EOGenerator, simply change your template‘s superclass
declaration and import statements
• Of course you can change them to your own MyGenericRecord
class instead, and let that extend ERXGenericRecord
• If you had a delegate in your EC to do stuff before saves, you can
now use ERXGenericRecord.willUpdate() and .willInsert()
instead
Samstag, 22. Juni 13
52. EO Templates
• Use Wonder templates from WOLips
• There‘s a wiki page with all sorts of alternatives
• In any case, take one that defines proper ERXKey constants
Samstag, 22. Juni 13
65. Information sources
• Wiki page „Project Wonder Installation“
• Wiki page „Integrate Wonder into an Existing Application“
• Wiki page „EOGenerator Templates and Additions“
• Wiki page „UTF-8 Encoding Tips“
• projectlombok.org
Samstag, 22. Juni 13