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

Fix curl error #7

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open

Fix curl error #7

wants to merge 17 commits into from

Conversation

akringwood
Copy link
Collaborator

No description provided.

agent/agent.ml Outdated Show resolved Hide resolved
@jeska
Copy link

jeska commented Mar 24, 2021

@UnrealAkama Can you merge this in? 👀

@akringwood
Copy link
Collaborator Author

Sorry about this, life has been a bit crazy, I fixed what I think is the last bug in this and have updated test release. I'm going to give it a try this weekend and make sure everything works but you should be able to use the binaries in that release to replace the current ones and test it out.

@jeska
Copy link

jeska commented Apr 1, 2021

@akringwood thanks! we set it up yesterday to initially great success, but now we're getting this error pretty frequently:

mc: internal error, uncaught exception:
    (Failure
      "Can't talk to an agent, this probably means the agent failed to install.")
    Raised at Engine__Runner.main.(fun) in file "engine/runner.ml", line 467, characters 6-13
    Called from Lwt.Sequential_composition.try_bind.create_result_promise_and_callback_if_deferred.callback in file "src/core/lwt.ml", line 2160, characters 23-28
    Re-raised at Lwt.Miscellaneous.poll in file "src/core/lwt.ml", line 3072, characters 20-29
    Called from Lwt_main.run.run_loop in file "src/unix/lwt_main.ml", line 31, characters 10-20
    Called from Lwt_main.run in file "src/unix/lwt_main.ml", line 118, characters 8-13
    Re-raised at Lwt_main.run in file "src/unix/lwt_main.ml", line 124, characters 4-13
    Called from Cmdliner_term.app.(fun) in file "cmdliner_term.ml", line 25, characters 19-24
    Called from Cmdliner.Term.run in file "cmdliner.ml", line 117, characters 32-39
Something has gone wrong for run f130c267-8ea7-4a63-a82a-e1b3a660a8cf, we received in exception:
 (Failure
  "Can't talk to an agent, this probably means the agent failed to install.") 

Any ideas?

@akringwood
Copy link
Collaborator Author

Hmmm, that's odd, it seems like the agent isn't starting reliably. Normally that's due to me forgetting to set the bins acl to public so that the agents can access it cause they have to bootstrap themselves. We are using this as well and aren't seeing it so let me do some testing and figure out what I can see. You can also log onto the makecloud nodes themselves by adjusting the key in the mc_settings file and then sshing into the box once you've left it alive with --dont-delete. Trying to run the agent, it should be in / might also illuminate somethings.

@@ -229,13 +229,14 @@ module Aws : Provider_template.Provider = struct
process_response resp
in
let%lwt _resp, body =
match%lwt repeat_until_ok send_command 10 with
match%lwt repeat_until_ok send_command 60 with
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is good!

Copy link
Contributor

@donaherc donaherc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM when I scanned it, we shipped this out to before right? or are we not using this?

@hcarty
Copy link
Contributor

hcarty commented Apr 19, 2021

Yeah, we've been using a build from this branch, built before this timing change

| Error _ ->
failwith
| Error (`Msg message, note) ->
Lwt.fail_with (Fmt.str

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we leave this as failwith (or even Fmt.failwith)? The lwt docs mention that it might be better to prefer failwith over Lwt.fail_with if we don't attempt to store or catch the rejected promise further up the chain since failwith will result in the runtime recording the backtrace.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair question. In theory using the Lwt ppx should give decent backtraces. But that's not happening here so something is missing somewhere.

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

Successfully merging this pull request may close these issues.

6 participants