Book Image

Scala for Java Developers

By : Thomas Alexandre
Book Image

Scala for Java Developers

By: Thomas Alexandre

Overview of this book

Table of Contents (19 chapters)
Scala for Java Developers
Credits
Foreword
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Practical tips when using Play


We will conclude this chapter with a couple of recommendations that will help with the daily usage of the Play Framework.

Debugging with Play

Due to the declarative nature of functional programming and the powerful type checking mechanism of the compiler, debugging should happen less often when dealing with Scala code. However, if you need to debug a Play application in a situation, you might as well run a remote debugging session as you would in Java. To achieve this, just start your Play application with an extra debug command:

> play debug run

You should see an extra information line in the output that displays the following command line:

Listening for transport dt_socket at address: 9999

From here, you can add break points in your code and start a remote debugging configuration in Eclipse by navigating to the menu named Run | Debug Configurations…

Right-click on Remote Java Application and select New. Just make sure that you enter Port:9999 in the Connection...