Skip to content
This repository has been archived by the owner on May 17, 2022. It is now read-only.

Commit

Permalink
Changes
Browse files Browse the repository at this point in the history
  • Loading branch information
krishnan-r committed Aug 1, 2017
1 parent 6bd8b10 commit 53d63a4
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 361 deletions.
9 changes: 4 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ after_success:
- cd $TRAVIS_BUILD_DIR/
- 'docker login -u=$DOCKER_USER -p=$DOCKER_PASS && docker build -f Dockerfile -t krishnanr/sparkmonitor
. && docker push krishnanr/sparkmonitor'
- 'docker build -f swanimage.Dockerfile -t krishnanr/sparkmonitorhub . && docker push krishnanr/sparkmonitorhub'

deploy:

- provider: releases
skip_cleanup: true
file:
Expand All @@ -54,7 +54,6 @@ deploy:
on:
tags: true
script: 'docker tag krishnanr/sparkmonitor krishnanr/sparkmonitor:$TRAVIS_TAG &&
docker push krishnanr/sparkmonitor:$TRAVIS_TAG &&
docker tag krishnanr/sparkmonitorhub krishnanr/sparkmonitorhub:$TRAVIS_TAG &&
docker push krishnanr/sparkmonitorhub:$TRAVIS_TAG'
docker push krishnanr/sparkmonitor:$TRAVIS_TAG
6 changes: 5 additions & 1 deletion extension/sparkmonitor/serverextension.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# SparkMonitor Jupyter Serverextension
# This module adds a request handler to jupyter webserver. It proxies the spark UI assumed to be running at 127.0.0.1:4040
# to the endpoint [notebook rooturl]/sparkmonitor
# TODO Create unique endpoints for different kernels or spark applications.

from notebook.base.handlers import IPythonHandler

Expand Down Expand Up @@ -54,7 +58,7 @@ def handle_response(self, response):
self.write(content)
self.finish()


# Called when the serverextension is loaded
def load_jupyter_server_extension(nb_server_app):
"""
Called when the extension is loaded.
Expand Down
5 changes: 4 additions & 1 deletion extension/sparkmonitor/sparkmonitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,8 @@ def load_ipython_extension(ipython):
logger = logging.getLogger('sparkscalamonitor')
logger.setLevel(logging.DEBUG)
logger.propagate = False
fh = logging.FileHandler('scalamonitorextension.log') # ,mode='w')
# For debugging this module - Writes logs to a file
fh = logging.FileHandler('sparkmonitor_kernelextension.log',mode='w')
fh.setLevel(logging.DEBUG)
formatter = logging.Formatter(
'%(levelname)s: %(asctime)s - %(name)s - %(process)d - %(processName)s - \
Expand All @@ -138,7 +139,9 @@ def load_ipython_extension(ipython):
# Injecting conf into users namespace
if(spark_imported):
conf = ipython.user_ns.get('conf')

if(conf):
logger.info("Conf: "+conf.toDebugString())
if(isinstance(conf, SparkConf)):
configure(conf)
else:
Expand Down
166 changes: 0 additions & 166 deletions notebooks/swantest.ipynb

This file was deleted.

16 changes: 0 additions & 16 deletions swanimage.Dockerfile

This file was deleted.

Loading

0 comments on commit 53d63a4

Please sign in to comment.