I'm trying to see the difference between default flask logger and stackdriver logger in GAE's sample application: https://cloud.google.com/python/getting-started/using-pub-sub
Code without StackDriver logger:
def create_app(config, debug=False, testing=False, config_overrides=None):
app = Flask(__name__)
app.config.from_object(config)
app.debug = debug
app.testing = testing
if config_overrides:
app.config.update(config_overrides)
# Configure logging
if not app.testing:
logging.basicConfig(level=logging.INFO)
Code with StackDriver logger:
def create_app(config, debug=False, testing=False, config_overrides=None):
app = Flask(__name__)
app.config.from_object(config)
app.debug = debug
app.testing = testing
if config_overrides:
app.config.update(config_overrides)
# [START setup_logging]
if not app.testing:
client = google.cloud.logging.Client(app.config['PROJECT_ID'])
# Attaches a Google Stackdriver logging handler to the root logger
client.setup_logging(logging.INFO)
There's some difference with the StackDriver code where a logger was imported from google cloud. However, the output of the logs seems similar:
Output Log without StackDriver:

Output Log with StackDriver:
These logs does not look that different with or without a StackDriver.
When I go to the StackDriver logs I get redirected to the default logs in GAE. Is there anything special with StackDriver loggers that the normal flask logger cannot do?
