gopal krishnan

Greenhorn
+ Follow
since Dec 17, 2007
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by gopal krishnan

I tried to locate "http://localhost:8080" in the browser, but i am getting the message the server is start up using glass fisher, i had stopped it, event uninstalled it restarted the PC, but still getting the below message. any help on this.. i am getting this problem today, i was using it on last Friday and it was working without any issues.

Actually there seems no glass fish server, but it pretends to be the server.

message

Glass Fish Server 3.1.2 Your server is now running
12 years ago
hey the problem got resovled, after i had modified, the following..

1) applicationContext with mapping for the bean "productManager" with ref productDao
2) ProductManager interface with new method call getProducts(), then implemenent in the SimpleProductManager and which call the ProductDao.getProducts(), where the sql query is being defined.
12 years ago
thanks, i had changed the getter method now, but still getting the same error...

error
----
Error occurred during deployment: Exception while loading the app : java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'productManager' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Instantiation of bean failed; nested exception is java.lang.ExceptionInInitializerError. Please see server.log for more details.




also i had modified the Controller and springapp-servlet.xml as below..

springapp-servlet.xml
---------------------------

<bean name="/hello.htm" class="HelloController">
<property name="simpleProductManager" ref="simpleProductManager"/>
</bean>


HelloController.java
-------------------------

12 years ago
i had earlier created the spring framework, then replaced with the database connection, but there is problem in creating the beans.

also receiving the below error during the deployment.

Error


deploy?DEFAULT=C:\Users\gopc\Documents\NetBeansPro jects\HelloSpringJDBC\build\web&name=HelloSpringJD BC&contextroot=/HelloSpringJDBC&force=true failed on GlassFish Server 3.1.2 Error occurred during deployment: Exception while loading the app : java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'productManager' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyExcep tion: Invalid property 'productDao' of bean class [SimpleProductManager]: Bean property 'productDao' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?. Please see server.log for more details. C:\Users\gopc\Documents\NetBeansProjects\HelloSpri ngJDBC\nbproject\build-impl.xml:1029: The module has not been deployed. See the server log for details.

Source

applicationContext.xml



spirngapp-servlet.xml





JdbcProductDao.java



SimpleProductManager.java



HelloController.java


12 years ago
Thanks for your reply, it's just the order of parsing in the xml to json being changed..
i got the problem being resolved..

following are the step's i did it..

1) in the springapp-context.xml (dispacher ), i add the below

<bean id="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
<property name="basename" value="messages"/>
</bean>

2) second, i placed the messages.properties file inside the /WEB-INF/classes. make sure that after clean and deploy the file stills exits.
12 years ago
i have the xml file, i need to convert into the json. the json output is the partial convert of the xml, not whole xml is converted..

Reason you can find the output of the json, only partial is being converted. remaining portion is omitted.


OUTPUT
============




INPUT XML FILE
=============






i am trying to set the value from the springapp-servlet.xml and it fails to set the property by giving error message

Failed to convert property value of type [java.lang.String] to required type [ProductManager] for property 'productManager'; nested exception is java.lang.IllegalArgumentException: Cannot convert value of type [java.lang.String] to required type [ProductManager] for property 'productManager': no matching editors or conversion strategy found

my code
---------

springapp-servlet.xml
---------------------------------





SimpleProductManager
------------------------------

12 years ago
i am closing this, since i got after moving inside the WEB-INF/jsp with redirect.jsp and accessing using the http://localhost:8080/SpringApp/Redirect.htm
12 years ago
Thanks for your email..

i created the webapplication project using the NETBEANS IDE..

when i tried to create the java file, it creates in the source package.. means (src/java).
12 years ago
I had created the simple spring MVC controller, when i tried to execute i am getting the error.

Error Message:

org.springframework.beans.factory.CannotLoadBeanCl assException: Cannot find class [SpringApp.web.java.HelloController] for bean with name 'Redirect.jsp' defined in ServletContext resource [/WEB-INF/springapp-servlet.xml]; nested exception is java.lang.ClassNotFoundException: SpringApp.web.java.HelloController


This is my application structure.

SpringApp
----Web Pages
----META-INF
----WEB-INF
----springapp-servlet.xml
----web.xml
----Redirect.jsp
----index1.jsp
----Source Packages
----java
----HelloController.java



web.xml
--------


springapp-servlet.xml
----------------------



index1.jsp
---------


Redirect.jsp
------------



HelloController.java
-------------------

12 years ago
Hi,

I tried with the web application development using the java beans, jsp , jdbc and it seems it does not seems to be useful.

reason: i need to create the java page and need to load the property and use it for the page...

Please find my codes attached for my simple application...

simple application name: log entry
brief: it updates the daily comments, and tracks the status completed or not, you can update and insert.. it..


Can you Please advice me the new, robust technology i can follow futher...
i'm not defining it.. using the existing..