이 콘텐츠는 선택한 언어로 제공되지 않습니다.
Chapter 10. Run Red Hat JBoss Data Grid in Library Mode (Single-Node Setup)
10.1. Run the Quickstart Class 링크 복사링크가 클립보드에 복사되었습니다!
링크 복사링크가 클립보드에 복사되었습니다!
Prerequisites
These quickstarts use the Infinispan quickstarts located at https://github.com/infinispan/infinispan-quickstart. The following procedure uses the infinispan-quickstart/embedded-cache quickstart.
Procedure 10.1. Run the Quickstart Class
Open the Quickstart.java File
Open the file calledQuickstart.javain theinfinispan-quickstart/embedded-cache.Add the Quickstart Class
Examining theQuickstart.javafile we can see that this class creates aDefaultCacheManagerand then obtains a local reference to thedefaultcache, as no cache name is specified:Copy to Clipboard Copied! Toggle word wrap Toggle overflow Copy Dependencies and Compile Java Classes
Use the following command to copy all project dependencies to a directory and compile the Java classes from your project:mvn clean compile dependency:copy-dependencies -DstripVersion
$ mvn clean compile dependency:copy-dependencies -DstripVersionCopy to Clipboard Copied! Toggle word wrap Toggle overflow Run the Main Method
Use the following command to run the main method:java -cp target/classes/:target/dependency/* package org.infinispan.quickstart.embeddedcache.Quickstart
$ java -cp target/classes/:target/dependency/* package org.infinispan.quickstart.embeddedcache.QuickstartCopy to Clipboard Copied! Toggle word wrap Toggle overflow