I am new to Apache beam, I have been following https://cloud.google.com/docs/authentication/getting-started#setting_the_environment_variable to run tests over Cloud Data flow.
When I execute ./gradlew :runners:google-cloud-dataflow-java:validatesRunnerLegacyWorkerTest --tests "org.apache.beam.sdk.transforms.ParDoTest$OnWindowExpirationTests" --scan
I have been getting
org.apache.beam.sdk.transforms.ParDoTest$OnWindowExpirationTests > testOnWindowExpirationSimpleBounded FAILED
java.lang.RuntimeException at ParDoTest.java:5544
Caused by: java.lang.reflect.InvocationTargetException at ParDoTest.java:5544
Caused by: java.lang.RuntimeException at ParDoTest.java:5544
Task :runners:google-cloud-dataflow-java:validatesRunnerLegacyWorkerTest FAILED
The problem was i did not set GOOGLE_APPLICATION_CREDENTIALS values. After setting the value properly, i worked for me.
export GOOGLE_APPLICATION_CREDENTIALS="/home/vend/Downloads/credentials.json"
Related
I'm getting this error while trying to build my Hybris project via ant clean all && ./hybrisserver.sh debug:
Error occurred during initialization of VM
java.lang.Error: Could not create SecurityManager
at java.lang.System.initPhase3(java.base#11.0.9.1/System.java:2065)
Caused by: java.lang.ClassNotFoundException: allow
at jdk.internal.loader.BuiltinClassLoader.loadClass(java.base#11.0.9.1/BuiltinClassLoader.java:581)
at jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(java.base#11.0.9.1/ClassLoaders.java:178)
at java.lang.ClassLoader.loadClass(java.base#11.0.9.1/ClassLoader.java:522)
at java.lang.Class.forName0(java.base#11.0.9.1/Native Method)
at java.lang.Class.forName(java.base#11.0.9.1/Class.java:398)
at java.lang.System.initPhase3(java.base#11.0.9.1/System.java:2050)
Maybe I put a typo somewhere (see Caused by: java.lang.ClassNotFoundException: allow
) but I can't find anything and my repo's up to date with master which is correctly working, Is there a way to find the problem?
Note: i have Ubuntu 20.04.5 LTS
Thank you
Solution was simple:
Somehow I lost my setantenv.sh configuration, i had to re-run it in /platform
I came into an error of NoClassFound Error when I exec cmd 'bash gerrit.sh run'.
Before that I have make my Gerrit version upgraded from 3.2.3 to 3.4.1 by
jar -jar gerrit.3.4.1.jar init -d ${MY-GerritSite}.
And it returned Initialized success.
Here is my Error log when start Gerrit server.
Any help is appreciate.
Thank you.
com.google.inject.CreationException: Unable to create injector, see the following errors:
1) [Guice/ErrorInjectingConstructor]: NoClassDefFoundError: com/google/gerrit/server/change/ChangeKeyAdapter
at Log4jMessageLogger.<init>(Log4jMessageLogger.java:38)
at Log4jMessageLogger.class(Log4jMessageLogger.java:38)
while locating Log4jMessageLogger
while locating LifecycleListener annotated with #UniqueAnnotations$Internal(value=59)
Learn more:
https://github.com/google/guice/wiki/ERROR_INJECTING_CONSTRUCTOR
Caused by: NoClassDefFoundError: com/google/gerrit/server/change/ChangeKeyAdapter
at EventGsonProvider.get(EventGsonProvider.java:80)
at Log4jMessageLogger.<init>(Log4jMessageLogger.java:40)
at Log4jMessageLogger$$FastClassByGuice$$745685493.GUICE$TRAMPOLINE(<generated>)
at Log4jMessageLogger$$FastClassByGuice$$745685493.apply(<generated>)
at DefaultConstructionProxyFactory$FastClassProxy.newInstance(DefaultConstructionProxyFactory.java:82)
at ConstructorInjector.provision(ConstructorInjector.java:114)
at ConstructorInjector.construct(ConstructorInjector.java:91)
at ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:296)
at ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at SingletonScope$1.get(SingletonScope.java:169)
at InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:45)
at FactoryProxy.get(FactoryProxy.java:60)
at InternalInjectorCreator.loadEagerSingletons(InternalInjectorCreator.java:213)
at InternalInjectorCreator.injectDynamically(InternalInjectorCreator.java:186)
at InternalInjectorCreator.build(InternalInjectorCreator.java:113)
at InjectorImpl.createChildInjector(InjectorImpl.java:239)
at Daemon.createSysInjector(Daemon.java:521)
at Daemon.start(Daemon.java:361)
at Daemon.run(Daemon.java:279)
at AbstractProgram.main(AbstractProgram.java:61)
at java.base/NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/Method.invoke(Method.java:566)
at GerritLauncher.invokeProgram(GerritLauncher.java:224)
at GerritLauncher.mainImpl(GerritLauncher.java:120)
at GerritLauncher.main(GerritLauncher.java:65)
at Main.main(Main.java:28)
Caused by: ClassNotFoundException: ChangeKeyAdapter
at java.base/URLClassLoader.findClass(URLClassLoader.java:471)
at java.base/ClassLoader.loadClass(ClassLoader.java:588)
at java.base/FactoryURLClassLoader.loadClass(URLClassLoader.java:899)
at java.base/ClassLoader.loadClass(ClassLoader.java:521)
... 28 more
I have an issue with starting my project after the upgrade of IDEA.
Current error is the following:
CONFIGURE SUCCESSFUL in 2s
|Running application...
> Task :compileJava NO-SOURCE
startup failed:
General error during semantic analysis: java.lang.NoClassDefFoundError: org.springframework.security.authentication.encoding.PasswordEncoder
java.lang.RuntimeException: java.lang.NoClassDefFoundError: org.springframework.security.authentication.encoding.PasswordEncoder
at org.codehaus.groovy.control.CompilationUnit.convertUncaughtExceptionToCompilationError(CompilationUnit.java:1118)
at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1098)
at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:645)
1 error
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':compileGroovy'.
> Compilation failed; see the compiler error output for details.
* Try:
Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Exception is:
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':compileGroovy'.
> Task :compileGroovy FAILED
Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1(ExecuteActionsTaskExecuter.java:207)
* Get more help at https://help.gradle.org
BUILD FAILED in 3s
If I try to clean and run-app I get the following:
| Running application...
<-------------> 0% WAITING
IDLE
startup failed:
General error during semantic analysis: java.lang.NoClassDefFoundError: org.springframework.security.authentication.encoding.PasswordEncoder
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':compileGroovy'.
Compilation failed; see the compiler error output for details.
Tried everything I know, project settings, clean cache, invalidate cache and restart... nothing is helping.
I have found a solution:
grails.plugin.springsecurity.authentication.encoding.BCryptPasswordEncoder - using deprecated classes
class CryptoEncoderWrapper implements org.springframework.security.authentication.encoding.PasswordEncoder
you need to change build.gradle to:
compile 'org.grails.plugins:spring-security-core:4.0.0'
BCrypt now has this import
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder
Now, this issue is resolved but leads to other issues.
I was just getting started with react native and I encountered some problem while building the app.
Here's the error:
(Complete log)
Starting JS server...
Building and installing the app on the device (cd android && ./gradlew installDebug)...
AAPT err(Facade for 33021040): /home/srijan/Android/build-tools/27.0.3/aapt2: 1: /home/srijan/Android/build-tools/27.0.3/aapt2: Syntax error: "(" unexpected
Slave 33021040 failed to start
java.lang.RuntimeException: AAPT slave failed to start. Please make sure the current build tools (located at /home/srijan/Android/build-tools/27.0.3/aapt2) are not corrupted.
at com.android.builder.png.AaptProcess.waitForReadyOrFail(AaptProcess.java:193)
at com.android.builder.internal.aapt.AaptQueueThreadContext.creation(AaptQueueThreadContext.java:56)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:250)
at java.lang.Thread.run(Thread.java:748)
AAPT err(Facade for 26937763): /home/srijan/Android/build-tools/27.0.3/aapt2: 1: /home/srijan/Android/build-tools/27.0.3/aapt2: Syntax error: "(" unexpected
Slave 26937763 failed to start
java.lang.RuntimeException: AAPT slave failed to start. Please make sure the current build tools (located at /home/srijan/Android/build-tools/27.0.3/aapt2) are not corrupted.
at com.android.builder.png.AaptProcess.waitForReadyOrFail(AaptProcess.java:193)
at com.android.builder.internal.aapt.AaptQueueThreadContext.creation(AaptQueueThreadContext.java:56)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:250)
at java.lang.Thread.run(Thread.java:748)
Exception in thread "queued-resource-processor_2" java.util.MissingFormatArgumentException: Format specifier '%1$s'
at java.util.Formatter.format(Formatter.java:2525)
at java.util.Formatter.format(Formatter.java:2455)
at java.lang.String.format(String.java:2940)
at com.android.build.gradle.internal.aapt.AaptGradleFactory$FilteringLogger.shouldDowngrade(AaptGradleFactory.java:156)
at com.android.build.gradle.internal.aapt.AaptGradleFactory$FilteringLogger.error(AaptGradleFactory.java:122)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:253)
at java.lang.Thread.run(Thread.java:748)
Exception in thread "queued-resource-processor_1"
java.util.MissingFormatArgumentException: Format specifier '%1$s'
at java.util.Formatter.format(Formatter.java:2525)
at java.util.Formatter.format(Formatter.java:2455)
at java.lang.String.format(String.java:2940)
at com.android.build.gradle.internal.aapt.AaptGradleFactory$FilteringLogger.shouldDowngrade(AaptGradleFactory.java:156)
at com.android.build.gradle.internal.aapt.AaptGradleFactory$FilteringLogger.error(AaptGradleFactory.java:122)
at com.android.builder.tasks.WorkQueue.run(WorkQueue.java:253)
at java.lang.Thread.run(Thread.java:748)
> Task :app:mergeDebugResources FAILED
Error: java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:mergeDebugResources'.
> Error: java.util.concurrent.ExecutionException: java.lang.RuntimeException: No server to serve request. Check logs for details.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 4s
9 actionable tasks: 1 executed, 8 up-to-date
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/getting-started.html
So this is the error
Kindly help me troubleshoot this thing.
Also I tried, re-downloading build-tools 27.0.3 with the sdkmanager cli.
You are trying to run the tools on linux 32 bit, but it is not supported. The supported systems are Windows (both 32 and 64 bit), Mac OS 64 bit and Linux 64 bit.
Here's more info one the Android Studio's page: https://developer.android.com/studio/#downloads
I recommend using https://expo.io, especially if you're just starting out.
It would also fix your resources' problem; you don't need an emulator, as you can test on your actual phone with hot reloading and all the good stuff.
I am trying to run my backend project to invoke an API to get the data of a patient within our HOMOL environment
Unfortunately when in try to run the command "gradle bootrun/bootdebug/runapp", my gradle throws up the following error.
This is bugging me from a week now and still i am clueless as of what i am missing here.
Any help to solve this?
"Exception:
C:\Java\Projects\process tasy\tasy-tws\tasy-tws-backend\tws-backend\philips-ms-exam>gradle runapp
:philips-ms-commons:compileJava UP-TO-DATE
:philips-ms-commons:processResources UP-TO-DATE
:philips-ms-commons:classes UP-TO-DATE
:philips-ms-commons:jar
:philips-ms-app-boot:compileJava
:philips-ms-app-boot:processResources UP-TO-DATE`enter code here`
:philips-ms-app-boot:classes
:philips-ms-app-boot:jar
:philips-ms-exam:compileBootJava UP-TO-DATE
:philips-ms-exam:processBootResources UP-TO-DATE
:philips-ms-exam:bootClasses UP-TO-DATE
:philips-ms-exam:compileJava
:philips-ms-exam:processResources UP-TO-DATE
:philips-ms-exam:classes
:philips-ms-exam:pathingJar
:philips-ms-exam:bootRun
Exception in thread "main" com.google.inject.ProvisionException: Unable to provision, see the following errors:
1) Error instantiating application
1 error
at com.philips.app.boot.PhilipsBoot.main(PhilipsBoot.java:33)
Caused by: com.google.inject.ProvisionException: Unable to provision, see the following errors:
1) Error instantiating main module
1 error
at com.philips.app.boot.PhilipsInjector.loadMainModule(PhilipsInjector.java:174)
at com.philips.app.boot.PhilipsInjector.<init>(PhilipsInjector.java:35)
at com.philips.app.boot.PhilipsInjector.fromParams(PhilipsInjector.java:45)
at com.philips.app.boot.PhilipsBoot.main(PhilipsBoot.java:29)
Caused by: java.lang.ClassNotFoundException: com.philips.tws.boot.GuiceModule
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at com.philips.app.boot.PhilipsInjector.loadMainModule(PhilipsInjector.java:170)
... 3 more
:philips-ms-exam:bootRun FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':philips-ms-exam:bootRun'.
> Process 'command 'C:\Program Files\Java\jdk1.8.0_60\bin\java.exe'' finished with non-zero exit value 1
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 45.38 secs"