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

Document lightblue-migrator #77

Open
dcrissman opened this issue Mar 18, 2015 · 6 comments
Open

Document lightblue-migrator #77

dcrissman opened this issue Mar 18, 2015 · 6 comments

Comments

@dcrissman
Copy link
Member

This is a task to document the lightblue-migrator, and also a place to drop notes on to ensure it gets documented.

@dcrissman
Copy link
Member Author

Setting the job configuration field threadCount < 1 will result in no jobs being executed.

lightblue-platform/lightblue-migrator#103

@jewzaam
Copy link
Member

jewzaam commented Mar 18, 2015

Setting the job configuration field threadCount > 1 will result in no jobs being executed.
I assume you mean threadCount < 1

@jewzaam
Copy link
Member

jewzaam commented Mar 18, 2015

Some useful queries, for those with access to the mongo cli:


What jobs are running right now:

db.migrationJob.find(
{
    "jobExecutions#": {
        "$gt": 0
    },
    "jobExecutions.completedFlag": false
},
{_id:1}
).sort({_id:1})

Assuming you have a field to track when a record was migrated (migratedDate) for your entity (myEntity)...
How many records were migrated per minute:

db.myEntity.aggregate(
[
    {
        "$match": {
            "migratedDate": {
                "$exists": 1
            }
        }
    },
    {
        "$project": {
            "migratedDate": 1
        }
    },
    {
        "$group": {
            "_id": {
                "year": {
                    "$year": "$migratedDate"
                },
                "month": {
                    "$month": "$migratedDate"
                },
                "day": {
                    "$dayOfMonth": "$migratedDate"
                },
                "hour": {
                    "$hour": "$migratedDate"
                },
                "minute": {
                    "$minute": "$migratedDate"
                }
            },
            "count": {
                "$sum": 1
            }
        }
    },
    {
        "$sort": {"_id":-1}
    }
]
)

@dcrissman
Copy link
Member Author

Setting the job configuration field threadCount > 1 will result in no jobs being executed.

I assume you mean threadCount < 1

You are correct. I updated my earlier post to ensure no confusion later.

@dcrissman
Copy link
Member Author

Document how to configure GRAPHITE or STATSD

lightblue::application::migrator::serviceJvmOptions:
    - DSTATSD_PREFIX=myprefix
    - DSTATSD_HOSTNAME=localhost
    - DSTATSD_PORT=1234

lightblue-platform/lightblue-puppet#120

@dcrissman
Copy link
Member Author

Document how to set custom log4.properties

lightblue::application::migrator::serviceJvmOptions:
    - Dlog4j.configuration=file:/path/to/log4j.properties

lightblue-platform/lightblue-puppet#121

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

No branches or pull requests

2 participants