|
using OJBThis section presents the Tutorial Application's components that differ with storage mechanism choice. This page is about using OJB storage. Tutorial Application's common parts are shown in Tutorial Application page of this site. Because of the highly generic BERSERK architecture, the only difference programmers feel is the configuration. All the developing is done calling the very same methods of the very same objects. BERSERK itself is responsible to use the appropriate storage object. For details on BERSERK's configuration, please see the berserk.properties page of User Documentation section. Please remember that you still must specify IdInternals to BERSERK's entities (filters, chains and services) when using OJB configuration. configuration differencesIn this deploy OJB storage and transactions were used for BERSERK’s filters and services configurations. The berserk.properties file was deployed as follows: storageBroker=pt.utl.ist.berserk.storage.ojb.StorageBrokerOJB #storageBroker=pt.utl.ist.berserk.storage.digester.StorageBrokerDigester berserk.databaseName=BERSERK_OJB #berserk.filterDefinitions=fd.xml #berserk.serviceDefinitions=sd.xml #berserk.filterChainsDefinitions=fcd.xml berserk.transactionManager = pt.utl.ist.berserk.storage.ojb.TransactionBrokerOJB application.transactionManager=pt.utl.ist.berserk.storage.empty.TransactionBrokerEmpty This tells BERSERK to use the built in storage and transaction broker to access
filter and services configurations and to use no transactions when executing
services. The TransactionBrokerEmpty implements the ITransactionBroker
interface, but does absolutely nothing.
insert into service_definition values (1, 'StdoutWriter', 'services.StdoutWriter', '', 0); insert into filter_definition values (1, 'OnlyIntegers', 'filters.RequesterIsIntegerFilter', '...', 0); insert into filter_definition values (2, 'LogAccess', 'filters.AccessLogger', 'Writes accesses to a file', 0); insert into filter_chain values (1,'AccessControl','OnlyIntegers','...','filters.AccessControlFilter',1); insert into filter_chain values (2, 'Logger', 'LogAccess', 'Logger Chain','filters.LoggingFilter', 2); insert into service_filterchain values (1,1); insert into service_filterchain values (1,2); |