[Tomcat, HTTPD, Servlets & JSP] - Re: Apache workers.properties help please.
by AndrewBoyd
I was looking at my mod-jk.conf:
| # Load mod_jk module
| # Specify the filename of the mod_jk lib
| LoadModule jk_module modules/mod_jk.so
|
| # Where to find workers.properties
| JkWorkersFile conf/workers.properties
|
| # Where to put jk logs
| JkLogFile logs/mod_jk.log
|
| # Set the jk log level [debug/error/info]
| JkLogLevel info
|
| # Select the log format
| JkLogStampFormat "[%a %b %d %H:%M:%S %Y]"
|
| # JkOptions indicates to send SSK KEY SIZE
| JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
|
| # JkRequestLogFormat
| JkRequestLogFormat "%w %V %T"
|
| # Mount your applications
| JkMount /application/* loadbalancer
|
| # You can use external file for mount points.
| # It will be checked for updates each 60 seconds.
| # The format of the file is: /url=worker
| # /examples/*=loadbalancer
| JkMountFile conf/uriworkermap.properties
|
| # Add shared memory.
| # This directive is present with 1.2.10 and
| # later versions of mod_jk, and is needed for
| # for load balancing to work properly
| JkShmFile logs/jk.shm
|
| # Add jkstatus for managing runtime data
| <Location /jkstatus/>
| JkMount status
| Order deny,allow
| Deny from all
| Allow from 127.0.0.1
| </Location>
|
This line looks like it is not correct:
| # Mount your applications
| JkMount /application/* loadbalancer
|
I don't have a /application/ directory does anyone know if this is wrong or what I should have this set to?
Thanks,
Andrew
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3969705#3969705
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3969705
19 years, 7 months
[Persistence, JBoss/CMP, Hibernate, Database] - Mapping String to NVARCHAR2
by alex1234567890
Hi,
I have entities with Memebers of type String. I try to persist these entities in a Oracle database.
persistence.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <persistence>
| <persistence-unit name="test">
| <jta-data-source>java:/testDS</jta-data-source>
| <properties>
| <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle9Dialect"/>
| <property name="hibernate.hbm2ddl.auto" value="validate"/>
| <property name="hibernate.cache.provider_class" value="org.jboss.ejb3.entity.TreeCacheProviderHook"/>
| <property name="hibernate.treecache.mbean.object_name" value="jboss.cache:service=EJB3EntityTreeCache"/>
| <property name="hibernate.cache.use_query_cache" value="true" />
| <property name="hibernate.show_sql" value="true" />
| <property name="jboss.entity.manager.jndi.name" value="java:/EntityManager/classes"/>
| <property name="jboss.entity.manager.factory.jndi.name" value="java:/managedEntityFactories/classes"/>
| </properties>
| </persistence-unit>
| </persistence>
|
The tables in the database are already created. At the start of the JBoss I get the following Exception:
| org.hibernate.HibernateException: Wrong column type: sName, expected: varchar2(255 char)
|
The colum sName has the type nvarchar2 to support unicode. I tried to use a jbosscmp-jdbc.xml to create my own type mapping:
<jbosscmp-jdbc>
|
| <defaults>
| <datasource>java:/testDS</datasource>
| <datasource-mapping>mymapping</datasource-mapping>
| </defaults>
|
| <type-mappings>
| <type-mapping>
| <name>mymapping</name>
| ...
| <mapping>
| <java-type>java.lang.String</java-type>
| <jdbc-type>VARCHAR</jdbc-type>
| <sql-type>NVARCHAR2(255)</sql-type>
| </mapping>
| </type-mapping>
| </type-mappings>
| </jbosscmp-jdbc>
In my datasource configuration I use this type mapping:
| <datasources>
| <local-tx-datasource>
| <jndi-name>testDS</jndi-name>
| <connection-url>...</connection-url>
| <driver-class>oracle.jdbc.driver.OracleDriver</driver-class>
| <!-- The login and password -->
| <user-name>...</user-name>
| <password>...</password>
|
| <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
|
| <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
|
| <metadata>
| <type-mapping>mymapping</type-mapping>
| </metadata>
| <max-pool-size>50</max-pool-size>
| </local-tx-datasource>
| </datasources>
|
Why Hybernate don't map java.util.String to NVARCHAR2 with these configuration?
Waht is to do to map String to NVARCHAR2?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3969703#3969703
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3969703
19 years, 7 months
[Persistence, JBoss/CMP, Hibernate, Database] - LazyInitializationException with Spring/Hibernate
by atlanta_al
Hi!
After setting up all my hibernate mappings I can't get rid of the following exception:
ERROR [LazyInitializationException] could not initialize proxy - the owning Session was closed
org.hibernate.LazyInitializationException: could not initialize proxy - the owning Session was closed
at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:60)
at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:102)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.intercept(CGLIBLazyInitializer.java:160)
at .......bo.AppointmentBO$$EnhancerByCGLIB$$b3086c3e_4.toString()
....................
The application is able to fetch the records from the database but as soon as I try to iterate over the PersistentSet it throws the exception stated above.
I read on the Internet that I should use org.springframework.aop.framework.ProxyFactoryBean which takes care of HibernateSession handling.
My *.hbm.xml files do not contain lazy="true" tags. Can someone help me out?
Your help will be greatly appreciated!
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3969701#3969701
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3969701
19 years, 7 months
[Installation, Configuration & Deployment] - JDK compatibility + migration JBPM 2 -> JBPM 3
by sax@sin.com
Hi,
two issues but somehow related.
I have to develop WF application that is beeing deployed on BEA WL 7 that runs JDK1.3. I'm almost sure I read before that jbpm 3.0 could be run on jdk 1.3 but now the documentation talks about jdk 1.4.2+.
I read some posts that speak about compiling for 1.3 and all mentioned source (jbpm, but also hibernate and dependant libraries) tweeking. I tried to figure it out myself, but got several errors (especialy on hibernate side) and gave up.
So, Is it working with 1.3?
If not (and I'm quite conviced so), I'll have to fall back to jbpm 2. If I do so will I be able to migrate to 3.1 when my deploy platform upgrades to jdk1.4? I saw documentation about migratin process definition and it seems it can be done, but is it possible to upgrade the database as well?
I mean, if I have active processes running under jbpm2, will I be able to migrate them to jbpm3?
Thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3969699#3969699
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3969699
19 years, 7 months