Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Macro expansion to provide URL for preview and etc. is not happening in some circumstances #1133

Closed
larrytalley opened this issue Nov 11, 2016 · 3 comments

Comments

@larrytalley
Copy link

I have a fairly simple workspace, and when I edit command definitions and use suggested macros, even the basic ${current.project.path}, it seems that macro expansion is not happening. I'm thinking this might have something to do with my having one workspace but two "servers", that is, my workspace has a custom stack recipe that is a Docker compose file that gives me a "dev-machine" environment and a "messagebus" environment.

Here is my recipe for my custom stack:

version: '2'

services:
messagebus:
image: larrytalley/activemq-docker-deployable
environment:
ACTIVEMQ_NAME: "messagebus1"
ACTIVEMQ_REMOVE_DEFAULT_ACCOUNT: "true"
ACTIVEMQ_ADMIN_LOGIN: "admin"
ACTIVEMQ_ADMIN_PASSWORD: "admin"
ACTIVEMQ_WRITE_LOGIN: "producer_login"
ACTIVEMQ_WRITE_PASSWORD: "producer_password"
ACTIVEMQ_READ_LOGIN: "consumer_login"
ACTIVEMQ_READ_PASSWORD: "consumer_password"
ACTIVEMQ_JMX_LOGIN: "jmx_login"
ACTIVEMQ_JMX_PASSWORD: "jmx_password"
ACTIVEMQ_STATIC_TOPICS: "log;auth;akfish"
ACTIVEMQ_STATIC_QUEUES: "queue1;queue2;queue3"
ACTIVEMQ_MIN_MEMORY: "1024"
ACTIVEMQ_MAX_MEMORY: "1024"
ACTIVEMQ_ENABLED_SCHEDULER: "true"
mem_limit: 1073741824
command: ["/bin/sh", "-c", "bin/activemq console"]

dev-machine:
image: codenvy/ubuntu_jdk8
mem_limit: 1073741824
depends_on:
- messagebus


One command I have seen fail to expand macros are:
MAVEN
Name
build
Working directory
${current.project.path}
Command line clean install
Preview URL
http://${server.port.8161}/admin

My first clue that macro expansion is not working is that Maven finds no POM.

Here is the output of my "build" command:

command: mvn -f clean install
preview: http://${server.port.8161}/admin

[INFO] Scanning for projects...
[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[FATAL] Non-readable POM /projects/clean: /projects/clean (No such file or directory) @
@
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project (/projects/clean) has 1 error
[ERROR] Non-readable POM /projects/clean: /projects/clean (No such file or directory)


If I open terminal myself, and cd down into my project, then run
mvn clean install

it finds my POM and all is well. But when the command is executed the macro expansion of ${current.project.path} must result in nothing, so the command never gets into the project sub-directory.


Problem only started happening recently, but, I only succeeded in configuring my workspace with the two environments recently.

Diagnostic bundle

@TylerJewell
Copy link
Contributor

Interesting scenario. @ashumilova @vzhukovskii - please, can someone on team/plugin take a look.

@larrytalley
Copy link
Author

larrytalley commented Nov 14, 2016

Here is a link to report.tar from today. https://drive.google.com/a/noaa.gov/file/d/0BxSE58USMoUCZzlWQTAtdExwc2s/view?usp=sharing

By the way, the issue still exists today. As you can see from the logs I've updated my onprem codenvy to the latest stable release.

@larrytalley
Copy link
Author

Problem has resolved itself. I don't know what is different, but, now the macro expansion is working, I can find no evidence of the failure mode that I was seeing a few days ago.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants