How can a war file be deployed in Tomcat 7?

0 votes
I have copied the sample.war file into the webapps directory of Tomcat, and I can access localhost:8080.

Now how will Tomcat deploy it, do I need to open it in browser? How can I access the application?
Apr 20, 2018 in Java by Akrati
• 3,150 points
568 views

1 answer to this question.

0 votes
You can access your application from: http://localhost:8080/sample

Deploying of war files is automatic by default - after copying the file sample.war, check your webapps folder for an extracted folder sample.

If it doesn't open properly, check the log files (e.g. tomcat/logs/catalina.out) for problems with deployment.
answered Apr 20, 2018 by sophia
• 1,400 points

Related Questions In Java

0 votes
1 answer

Can quotes be added in a java string.how?

In Java, you can escape quotes with \: String ...READ MORE

answered Jun 14, 2018 in Java by Akrati
• 960 points
30 views
0 votes
2 answers

How can I convert a String variable to a primitive int in Java

 Here are two ways illustrating this: Integer x ...READ MORE

answered Aug 20 in Java by Sirajul
• 39,540 points
190 views
0 votes
2 answers

How can I create File and write data in it using Java?

import java.io.BufferedWriter; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Paths; public class WriteFiles{ ...READ MORE

answered Jul 26, 2018 in Java by samarth295
• 2,190 points
118 views
0 votes
3 answers

How to read a Text File in Java?

You can use readAllLines and the join method to ...READ MORE

answered Jul 27, 2018 in Java by samarth295
• 2,190 points
114 views
0 votes
1 answer
0 votes
1 answer

can i run two tomcat servers on the same linux VM machine?

Yes its possible. I had installed tomcat ...READ MORE

answered May 28 in Java by arvind.phulare1911
• 180 points
40 views
+5 votes
3 answers

How to execute a python file with few arguments in java?

You can use Java Runtime.exec() to run python script, ...READ MORE

answered Mar 27, 2018 in Java by DragonLord999
• 8,380 points

edited Nov 6, 2018 by Omkar 10,455 views
0 votes
1 answer

How to handle drop downs using Selenium WebDriver in Java

First, find an XPath which will return ...READ MORE

answered Mar 27, 2018 in Selenium by nsv999
• 5,110 points
2,311 views
0 votes
2 answers

How a static map can be initialized?

public class Test { ...READ MORE

answered Sep 12, 2018 in Java by Sushmita
• 6,880 points
94 views
0 votes
2 answers

How an object array can be converted to string array in java?

System.arraycopy is the most efficient way, but ...READ MORE

answered Aug 8, 2018 in Java by Sushmita
• 6,880 points
108 views