[JBoss Portal] - Using JNDI datasource name in Hibernate
by advaittrivedi
I have created a datasource in Jboss Portal 2.6.1. My test server is windows 2003 and jdk 1.5
| <datasources>
| <local-tx-datasource>
| <jndi-name>jdbc/JbossDS</jndi-name> <connection-url>jdbc:mysql://localhost:3306/jbossportaldb</connection-url>
| <driver-class>com.mysql.jdbc.Driver</driver-class>
| <user-name>jbossportal</user-name>
| <password>jbossportal</password>
| </local-tx-datasource>
| </datasources>
|
I refer to this datasource in Hibernate.cfg.xml using this property:
| <property name="connection.datasource">java:/jdbc/JbossDS</property>
|
But when I run my app it is giving this exception:
javax.naming.NameNotFoundException: jdbc not bound
at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)
at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)
at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
at org.jnp.server.NamingServer.lookup(NamingServer.java:267)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:589)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at org.hibernate.connection.DatasourceConnectionProvider.configure(DatasourceConnectionProvider.java:52)
at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:124)
at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:56)
at org.hibernate.cfg.SettingsFactory.createConnectionProvider(SettingsFactory.java:397)
Also I want to use PortalDS in hibernate.cfg.xml how can I do that? what will be the value of connection.datasource property?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096373#4096373
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096373
18Â years, 9Â months
Re: Problem with page using param
by samkï¼ twinix.com
See Thread at: http://www.techienuggets.com/Detail?tx=14242 Posted on behalf of a User
Hello Nicolas,
I have the same problem as you, and saw that Pete gave you a solution.
But I can't see the reply in this thread...
Can you give some elements please?
my email:
yjusot(at)yahoo.fr
Thanks,
Yv
In Response To:
Hi Pete,
thanks for your help, this solved the problem.
Nicolas
18Â years, 9Â months
[Clustering/JBoss] - Shared bean in two different servers, instead of server1 to
by vijesh_a_v
Hi,
We have two different servers with some common reusable beans deployed in both.
serverA calls the GenericBean in serverB. Even though the look up is done specifying url of serverB, the invocation is happening on the local GenericBean available in the serverA!!!
Oddly, this behaviour is found only when the bean is clustered !!. Otherwise, the call reaches serverB as expected (in both default and all configuration).
InvokerInterceptor.hasLocalTarget returns true. i.e return Registry.lookup(invocation.getObjectName()) != null; is true.
Why is it happening only when the bean is clustered???.
We would expect the call to go to serverB in both clustered and non-clustered state.
JBoss 4.0.5
ejb 2.1
jdk 5
Default clustering/loadbalancing configurations
Same behaviour in single node and multi node clustering scenario
Hopes to get some hints
Regards,
Vijesh
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096364#4096364
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096364
18Â years, 9Â months
[Installation, Configuration & DEPLOYMENT] - Re: Creating a secure development environment
by adldev
We do the same as PeterJ mentioned in the last paragraph.
Our environment is an extremely secured area and network. Therefore they gave us a separate pc to go on the the secured network to view email within the corporate environment.
Our development PCs are on a separate isolated network with each of our own JBoss sandbox. We need our individual sandboxes to develop in, till we were able to interface our platform developments together. If we didn't we would be stepping on one anothers processes before we were ready to interface.
Ah, one more thing. That PC they gave me for my secured email, after 1 year I told them to get rid of it out of my cubicle and they did. I believe, if the only function of a PC is to run my email and produce nothing at the end of the day like my development machines do, it wasn't worth to keep.
That machine was so secured with software and hardware (and I could not even admin that PC for basic maintenance). I would come in every morning and see it on because the network admins ran remote scans and updates nightly. No wonder it burned up 2 hard drives. As far as my development PCs (two of them), they have ran great for 4 years no problems.:)
They took out that PC, 1 month ago when they noticed I had unplugged it and had it plastered it with post-its and taped class diagram pages on its PC monitor. I couldn't use the monitor for my other PCs because it was a security violation. Go figure.
Now I read my email at home with better security then I had at work.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4096363#4096363
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4096363
18Â years, 9Â months