Win a copy of Micro Frontends in Action this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

Exception while deploying an application

 
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Im using the JBoss 5.0.0 CR2 application server. I want to use Sybase SQLAnywhere 10 as the Database. I have done the following configuration in persistence.xml and sample-ds.xml:

1. persistence.xml:
-------------------


2. sample-ds.xml:
-----------------


When I tried to deploy the application, Im getting the following error:
---------------------------------------------------------------------------
01:10:33,609 ERROR [AbstractKernelController] Error installing to Start: name=pe
rsistence.unit:unitName=#LoginCountApp state=Create
javax.persistence.PersistenceException: [PersistenceUnit: LoginCountApp] Unable
to build EntityManagerFactory
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Con
figuration.java:677)
at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFa
ctory(HibernatePersistence.java:132)
at org.jboss.jpa.deployment.PersistenceUnitDeployment.start(PersistenceU
nitDeployment.java:281)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(Reflec
tionUtils.java:59)
at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(
ReflectMethodInfoImpl.java:150)
at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethod
JoinPoint.java:66)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$Joi
npointDispatchWrapper.execute(KernelControllerContextAction.java:241)
at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(Executio
nWrapper.java:47)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dis
patchExecutionWrapper(KernelControllerContextAction.java:109)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dis
patchJoinPoint(KernelControllerContextAction.java:70)
at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInte
rnal(LifecycleAction.java:221)
at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction
(InstallsAwareAction.java:54)
at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction
(InstallsAwareAction.java:42)
at org.jboss.dependency.plugins.action.SimpleControllerContextAction.sim
pleInstallAction(SimpleControllerContextAction.java:62)
at org.jboss.dependency.plugins.action.AccessControllerContextAction.ins
tall(AccessControllerContextAction.java:71)
at org.jboss.dependency.plugins.AbstractControllerContextActions.install
(AbstractControllerContextActions.java:51)
at org.jboss.dependency.plugins.AbstractControllerContext.install(Abstra
ctControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractContr
oller.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(Abstra
ctController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(Abstr
actController.java:1062)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(Abstr
actController.java:984)
at org.jboss.dependency.plugins.AbstractController.install(AbstractContr
oller.java:774)
at org.jboss.dependency.plugins.AbstractController.install(AbstractContr
oller.java:540)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(B
eanMetaDataDeployer.java:124)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(B
eanMetaDataDeployer.java:51)
at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.i
nternalDeploy(AbstractSimpleRealDeployer.java:62)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(
AbstractRealDeployer.java:50)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(Deployer
Wrapper.java:169)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(Deployer
sImpl.java:1285)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFi
rst(DeployersImpl.java:1003)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFi
rst(DeployersImpl.java:1024)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(Deployers
Impl.java:944)
at org.jboss.dependency.plugins.AbstractControllerContext.install(Abstra
ctControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractContr
oller.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(Abstra
ctController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(Abstr
actController.java:1062)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(Abstr
actController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractContro
ller.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractContro
ller.java:553)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(Deployers
Impl.java:627)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeploye
rImpl.java:541)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDSca
nner.java:290)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScan
ner.java:221)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:44
1)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java
:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
access$101(ScheduledThreadPoolExecutor.java:98)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
runPeriodic(ScheduledThreadPoolExecutor.java:181)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
run(ScheduledThreadPoolExecutor.java:205)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExec
utor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.hibernate.HibernateException: Hibernate Dialect must be explicitl
y set for database: SQL Anywhere

at org.hibernate.dialect.DialectFactory.determineDialect(DialectFactory.
java:85)
at org.hibernate.dialect.DialectFactory.buildDialect(DialectFactory.java
:62)
at org.hibernate.cfg.SettingsFactory.determineDialect(SettingsFactory.ja
va:460)
at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:
155)
at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2101
)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.jav
a:1325)
at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(Annotat
ionConfiguration.java:867)
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Con
figuration.java:669)
... 55 more
01:10:33,875 WARN [HDScanner] Failed to process changes
org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incompl
ete deployments (SEE PREVIOUS ERRORS FOR DETAILS):

*** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual Stat
e}

jboss.j2ee:ear=LoginCountApp.jar,jar=LoginCountApp.jar,name=LoginValidator,servi
ce=EJB3
-> <UNKNOWN jboss.j2ee:ear=LoginCountApp.jar,jar=LoginCountApp.jar,name=LoginVa
lidator,service=EJB3>{Described:** UNRESOLVED Demands 'persistence.unit:unitName
=#LoginCountApp' **}


*** CONTEXTS IN ERROR: Name -> Error

persistence.unit:unitName=#LoginCountApp -> org.hibernate.HibernateException: Hi
bernate Dialect must be explicitly set for database: SQL Anywhere

<UNKNOWN jboss.j2ee:ear=LoginCountApp.jar,jar=LoginCountApp.jar,name=LoginValida
tor,service=EJB3> -> ** UNRESOLVED Demands 'persistence.unit:unitName=#LoginCoun
tApp' **


at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(Dep
loyersImpl.java:709)
at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainD
eployerImpl.java:661)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDSca
nner.java:291)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScan
ner.java:221)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:44
1)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java
:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
access$101(ScheduledThreadPoolExecutor.java:98)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
runPeriodic(ScheduledThreadPoolExecutor.java:181)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
run(ScheduledThreadPoolExecutor.java:205)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExec
utor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:908)
at java.lang.Thread.run(Thread.java:619)
---------------------------------------------------------------------------

Can you kindly guide me through this one.

-Kind Regards,
Rakesh.R
 
Ranch Hand
Posts: 364
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator



1. persistence.xml:
-------------------




This looks wrong. The property name to use is "hibernate.dialect".
 
author
Posts: 580
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rakesh,

Try this:

<property name="hibernate.dialect" value="org.hibernate.dialect.SybaseAnywhereDialect" />.

Not really sure what you were trying with "update".

Regards,
Reza
 
Ranch Hand
Posts: 215
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This might be not answer but worth to check...
Have you put Sybase driver in ther server's directory?
 
Rakesh Rajagopalan
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you so much Reza! That's the exact step that I was missing!! Thanks to Edvins and Rahul too for replying.
[ November 21, 2008: Message edited by: Rakesh Rajagopalan ]
reply
    Bookmark Topic Watch Topic
  • New Topic