Saturday, 15 July 2017

ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt:


<dependency>
    <groupId>org.hsqldb</groupId>
    <artifactId>hsqldb</artifactId>
    <scope>runtime</scope>
</dependency>
or the following for mySQL
<dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <scope>runtime</scope>
</dependency>
Add any one jar dependency in pom.xml file for connecting spring boot with data base.


23:20:59.442 [main] DEBUG org.springframework.boot.devtools.settings.DevToolsSettings - Included patterns for restart : []
23:20:59.470 [main] DEBUG org.springframework.boot.devtools.settings.DevToolsSettings - Excluded patterns for restart : [/spring-boot-starter/target/classes/, /spring-boot-autoconfigure/target/classes/, /spring-boot-starter-[\w-]+/, /spring-boot/target/classes/, /spring-boot-actuator/target/classes/, /spring-boot-devtools/target/classes/]
23:20:59.471 [main] DEBUG org.springframework.boot.devtools.restart.ChangeableUrls - Matching URLs for reloading : [file:/C:/Users/Sandeep/Downloads/Compressed/spring-boot-demo/target/test-classes/, file:/C:/Users/Sandeep/Downloads/Compressed/spring-boot-demo/target/classes/]

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v1.5.2.RELEASE)

2017-07-15 23:21:05.656  INFO 5008 --- [  restartedMain] com.concretepage.MyApplication           : Starting MyApplication on vipul with PID 5008 (C:\Users\Sandeep\Downloads\Compressed\spring-boot-demo\target\classes started by Sandeep in C:\Users\Sandeep\Downloads\Compressed\spring-boot-demo)
2017-07-15 23:21:05.659  INFO 5008 --- [  restartedMain] com.concretepage.MyApplication           : No active profile set, falling back to default profiles: default
2017-07-15 23:21:07.248  INFO 5008 --- [  restartedMain] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@2d7f1219: startup date [Sat Jul 15 23:21:07 IST 2017]; root of context hierarchy
2017-07-15 23:21:29.290  INFO 5008 --- [  restartedMain] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$d24aa2e4] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-07-15 23:21:40.403  INFO 5008 --- [  restartedMain] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-07-15 23:21:40.857  INFO 5008 --- [  restartedMain] o.apache.catalina.core.StandardService   : Starting service Tomcat
2017-07-15 23:21:40.985  INFO 5008 --- [  restartedMain] org.apache.catalina.core.StandardEngine  : Starting Servlet Engine: Apache Tomcat/8.5.11
2017-07-15 23:21:45.455  INFO 5008 --- [ost-startStop-1] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2017-07-15 23:21:45.456  INFO 5008 --- [ost-startStop-1] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 38371 ms
2017-07-15 23:21:46.295  INFO 5008 --- [ost-startStop-1] o.s.b.w.servlet.ServletRegistrationBean  : Mapping servlet: 'dispatcherServlet' to [/]
2017-07-15 23:21:46.494  INFO 5008 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'characterEncodingFilter' to: [/*]
2017-07-15 23:21:46.569  INFO 5008 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'hiddenHttpMethodFilter' to: [/*]
2017-07-15 23:21:46.569  INFO 5008 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'httpPutFormContentFilter' to: [/*]
2017-07-15 23:21:46.570  INFO 5008 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean   : Mapping filter: 'requestContextFilter' to: [/*]
2017-07-15 23:21:47.836  WARN 5008 --- [  restartedMain] ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'inMemoryDatabaseShutdownExecutor' defined in class path resource [org/springframework/boot/devtools/autoconfigure/DevToolsDataSourceAutoConfiguration.class]: Unsatisfied dependency expressed through method 'inMemoryDatabaseShutdownExecutor' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Tomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.tomcat.jdbc.pool.DataSource]: Factory method 'dataSource' threw exception; nested exception is org.springframework.boot.autoconfigure.jdbc.DataSourceProperties$DataSourceBeanCreationException: Cannot determine embedded database driver class for database type NONE. If you want an embedded database please put a supported one on the classpath. If you have database settings to be loaded from a particular profile you may need to active it (no profiles are currently active).
2017-07-15 23:21:47.902  INFO 5008 --- [  restartedMain] o.apache.catalina.core.StandardService   : Stopping service Tomcat
2017-07-15 23:21:48.352  INFO 5008 --- [  restartedMain] utoConfigurationReportLoggingInitializer : 

Error starting ApplicationContext. To display the auto-configuration report re-run your application with 'debug' enabled.
2017-07-15 23:21:48.380 ERROR 5008 --- [  restartedMain] o.s.b.d.LoggingFailureAnalysisReporter   : 

***************************
APPLICATION FAILED TO START
***************************

Description:

Cannot determine embedded database driver class for database type NONE

Action:

If you want an embedded database please put a supported one on the classpath. If you have database settings to be loaded from a particular profile you may need to active it (no profiles are currently active).

Wednesday, 21 June 2017

sorry we couldn't connect to skype please check your internet connection

to fix this issue

sorry we couldn't connect to skype please check your internet connection

– Quit Skype from System Icon Tray
– Then press “Win + R” keys to open the Run command box.
– Type “%appdata%” (without quotes) and press OK.
– Delete Skype folder from there

AND 

in internrt explorer goto
  • Click the gear icon image_thumb3_thumb_thumb at the top right corner and choose Internet Options.

  • At the Advanced tab press the Reset button.
  • Check the Delete Personal Settings checkbox and press Reset.

Friday, 30 December 2016

cp command in unix

cp sourcefile  destinationfile

Disk space check in UNIX


df - h Human Readable formats by using ‘-h’
df -k Display info in File System in Bytes

How to Remove the Files Forcefully in Unix

How to Remove the Files Forcefully in Unix

/ Deleting all file from folder.

rm -rf directoryname

for example if we have "bin/logfile" directory and it have 10 log files and we want to delete then we can use this command to delete this entire folder.

rm -rf bin

Monday, 30 November 2015

java junit4

@Ignore("ignore this test")
@AfterClass
@BeforeClass
@After
@Before
@Test (expected =ArithmeticException.class)
@Test

Sunday, 29 November 2015

How get BigdecimalEnum value in java

package com.org.vipul;

import java.math.BigDecimal;

public class BigdecimalEnum {

public static void main(String[] args) {
System.out.println(Vat.FIVE.getValue());

}

public enum Vat {
ONE(new BigDecimal("1")), TWO(new BigDecimal("2")), THREE(
new BigDecimal("3")), FIVE(new BigDecimal("5"));

private final BigDecimal value;

Vat(BigDecimal val) {
value = val;
}

public BigDecimal getValue() {
return value;
}
}
}