Deploying QATrack+ with IIS, CherryPy & SQL Server¶
This guide is going to walk you through installing QATrack+ on a Windows Server server with IIS serving static assets (images, javascript and stylesheets) and acting as a reverse proxy for a CherryPy web server which serves our Django application (QATrack+). SQL Server 2008 will be used as the database.
The steps we will be undertaking are:
- Installing and configuring git
- Checkout the latest release of the QATrack+ source code from bitbucket.
- Setting up our Python environment (including virtualenv)
- Making sure everything is working up to this point
- Setting up a database with SQL Server
- Configuring CherryPy to serve our QATrack+ site.
- Configuring IIS
- Wrap up
I will be using Windows Server 2008R2, IIS & SQLServer for this guide but steps should be similar on other versions of Windows.
1. Installing git¶
Go to http://git-scm.com and download the latest version of git (msysgit) for Windows (Git-<IP_ADDRESS>-preview20130201 at the time of writing). Run the installer. I just leave all the settings on their defaults but you are free to modify them if you like.
Step 1 done ;)
2. Checkout the latest release of QATrack+ source code from bitbucket¶
From the Start Menu look for the Git folder under All Programs and select Git Bash. This will open up a console window which we will be using fairly heavily for the rest of the process. (Note: this is a fairly full featured bash shell and is a lot more powerful than the default windows command prompt).
To create a home for QATrack+ and check out the source code, use the following commands:
#!bash
mkdir /c/deploy
cd /c/deploy
git clone https://bitbucket.org/tohccmedphys/qatrackplus.git
3. Setting up our Python environment¶
Note all Python packages should be 32 bit versions even on 64 bit machines
Go to http://www.python.org/download/ and download the 32 bit Python 2.7.X Windows Installer for Python (current version is 2.7.3 at the time of writing – QATrack+ does not currently support Python3). Go through the installer using the default options (Install for all users).
Next go to http://pypi.python.org/pypi/setuptools#files and download and run the MS Windows Installer (setuptools-0.6c11.win32-py2.7.exe at the time of writing)
We now need to download Scipy, matplotlib and pywin32. Go to http://sourceforge.net/projects/scipy/files/scipy/0.11.0/ and download the win32 superpack (eg scipy-0.11.0-win32-superpack-python27.exe. Save it in C::raw-latex:`\deploy` or somewhere else you can remember. Likewise, visit http://matplotlib.org/downloads.html and download the latest 32 bit version of matplotlib for Windows (matplotlib-1.2.0.win32-py2.7.exe at the time of writing). Finally visit http://sourceforge.net/projects/pywin32/files/pywin32/Build%20218/ and download pywin32-218.win32-py2.7.exe.
You will also want to add Python to your PATH environment variable. The process is slightly different depending on if you are on XP or something newer but the gist of it is: * Right click on My Computer * Select Advanced (or Advanced System Settings) * Select Environment Variables * Select Path under the System variables section and then click edit * Append ;C::raw-latex:`\Python`27;C::raw-latex:`Python`27:raw-latex:`Scripts `to the end of the path. Don’t overwrite the existing value! * Click Ok/Ok/Ok
Close the git bash command prompt you had open before and then open a new one (this will give you access to the updated PATH variable).
In your new git bash window the command which python
should return
/c/Python27/python
. If it doesn’t then your PATH variable has not
been set correctly.
We’re now ready to install all the libraries QATrack+ depends on. To install them, run the following:
#!bash
cd /c/deploy
easy_install pip
pip install virtualenv==1.9
mkdir venvs
virtualenv venvs/qatrack
source venvs/qatrack/Scripts/activate
easy_install numpy==1.7
easy_install /c/deploy/scipy-0.11.0-win32-superpack-python2.7.exe
easy_install /c/deploy/matplotlib-1.2.0.win32-py2.7.exe
easy_install /c/deploy/pywin32-218.win32-py2.7.exe
cd qatrackplus
pip install -r requirements/base.txt
pip install -r requirements/optional.txt
pip install -r requirements/win.txt
Last but not least, for this guide, we are going to be using the CherryPy package to act as our WSGI server and django-mssql as our database driver so install them too:
#!bash
pip install cherrypy
pip install django-mssql
4. Checking everything is functional so far¶
Getting everything installed was a pain, so lets take a minute and check everything is now functioning as it should. Create a directory called ‘db’ in the main qatrackplus directory and then setup a temporary database for testing (answer ‘yes’ and create a super user when prompted).
#!bash
cd /c/deploy/qatrackplus
mkdir db
python manage.py syncdb
python manage.py migrate
python manage.py loaddata fixtures/defaults/*/*
python manage.py collectstatic
You should now be able to run the built in test server and access your QATrack+ site for the first time! At the command prompt type the following to start the server:
#!bash
python manage.py runserver
You should then be able to open a browser window and visit http://<IP_ADDRESS>:8000 where you will be redirected to a login page (you can login using the superuser you created earlier).
In the terminal hit Ctrl+C
to kill the server.
5. Creating a database with SQL Server¶
From the start menu find and open SQL Server Management Studio. Enter ‘localhost’ for the server name and click Connect.
In the Object Explorer frame, right click the Databases folder and select “New Database...”.
Enter ‘qatrackdb’ as the database name and click OK.
Back in the Object Explorer frame, right click on the main Security folder and click New Login... Set the login name to ‘qatrack’, select SQL Server Authentication. Enter ‘qatrackpass’ (or whatever you like) for the password fields and uncheck Enforce Password Policy. Click OK.
Back in the Object Explorer frame, expand the qatrackdb database, right click on Security and select New->User.
Enter ‘qatrack’ as the User name and Login name and then below in the Database Role Membership select ‘db_datawriter’, ‘db_datareader’ and ‘db_owner’. Click OK.
Configuring QATrack+ to use your new database¶
Create a file called local_settings.py in /c/deploy/qatrackplus/qatrack/ and add the following contents:
#!python
DEBUG = False
TEMPLATE_DEBUG = False
DATABASES = {
'default': {
'ENGINE': 'sqlserver_ado', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'qatrackdb', # Or path to database file if using sqlite3.
'USER': '', # Not used with sqlite3.
'PASSWORD': '', # Not used with sqlite3.
'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.
}
}
Once again, we will configure our new MS SQL database from the command prompt (answer ‘yes’ and create a super user when prompted):
#!bash
python manage.py syncdb
python manage.py migrate
python manage.py loaddata fixtures/defaults/*/*
6. Configuring CherryPy to Serve QATrack+¶
Django’s built in web server that we used earlier is not meant to be used in production. Instead we will be using CherryPy to serve QATrack+ (you could also use waitress or rocket if you prefer).
Create a file called cherrypy_deploy.py in /c/deploy/qatrackplus/ with the following content:
#!python
from qatrack import wsgi
from cherrypy import wsgiserver
server = wsgiserver.CherryPyWSGIServer(
('<IP_ADDRESS>', 8080), wsgi.application
)
server.start()
and then to test that our CherryPy server is working run the following from the command line:
#!bash
python cherrypy_deploy.py
that command won’t appear to do anything but you should be able to visit http://<IP_ADDRESS>:8080 in your browser and see the login screen. (Don’t worry if it looks different than before...CherryPy is not setup to serve the style sheets and images)
Back in the terminal window hit Ctrl+C
to kill the server.
Installing CherryPy as a Windows Service¶
In order to have CherryPy start when you reboot your server, or restart after a crash, you may wish to install your CherryPy server as a Windows service.
Create a file called QATrackCherryPyService.py and add the following contents to it:
#!python
"""
Basic CherryPy Windows service for QATrack+...cobbled together
from various places online.
Requires Mark Hammond's pywin32 package.
"""
import cherrypy
import win32serviceutil
import win32service
import win32event
import sys
import os
from qatrack import wsgi
DEPLOY_DIRECTORY = "C:/deploy/qatrackplus/"
ERROR_LOG = os.path.join(DEPLOY_DIRECTORY,"logs","cherry_py_err.log")
STD_ERR = os.path.join(DEPLOY_DIRECTORY,"logs","std_err.log")
STD_OUT = os.path.join(DEPLOY_DIRECTORY,"logs","std_out.log")
sys.stdout = open(STD_OUT,'a')
sys.stderr = open(STD_ERR,'a')
class QATrackService(win32serviceutil.ServiceFramework):
"""NT Service."""
_svc_name_ = "QATrackCherryPyService"
_svc_display_name_ = "QATrack CherryPy Service"
def SvcDoRun(self):
sys.path.append(DEPLOY_DIRECTORY)
os.environ['DJANGO_SETTINGS_MODULE'] = 'qatrack.settings'
os.chdir(DEPLOY_DIRECTORY)
cherrypy.tree.graft(wsgi.application)
cherrypy.config.update({
'global':{
'log.error_file':ERROR_LOG,
'log.screen': False,
'tools.log_tracebacks.on':True,
'engine.autoreload.on': False,
'engine.SIGHUP': None,
'engine.SIGTERM': None
}
})
cherrypy.engine.start()
cherrypy.engine.block()
def SvcStop(self):
self.ReportServiceStatus(win32service.SERVICE_STOP_PENDING)
cherrypy.engine.exit()
self.ReportServiceStatus(win32service.SERVICE_STOPPED)
# very important for use with py2exe
# otherwise the Service Controller never knows that it is stopped !
if __name__ == '__main__':
win32serviceutil.HandleCommandLine(QATrackService)
Then from the command line:
#!bash
mkdir /c/deploy/qatrackplus/logs
python QATrackCherryPyService.py install
python QATrackCherryPyService.py start
Your QATrack+ installation is now installed as a Windows Service. I would recommend configuring your service to auto start. Instructions on how to do that can be found on the Windows Service Wikipedia page. You may also wish to configure the service to email you in the event of a crash (see the Recovery tab of the QATrackCherryPyService configuration dialogue).
7. Setting up IIS¶
We are going to use IIS for two purposes: first, it is going to serve all of our static media (css, js and images) and second it is going to act as a reverse proxy to forward the QATrack+ specific requests to CherryPy.
Before starting please make sure you have the URL Rewrite and Application Request Routing IIS modules installed. Application Request Routing needs to have the reverse proxy setting enabled: for instructions see the section titled Enabling Reverse Proxy Functionality on this page.
Once you have the URL Rewrite extension installed, open the IIS Manager, select the default Web Site and click Stop on the right hand side.
Now right click on Sites and click Add Web Site
Enter QATrack Static for the Site Name and C::raw-latex:`\deploy`:raw-latex:`\qatrackplus`:raw-latex:`\qatrack` for the Physical Path then click OK and answer Yes to the warning.
To test that setup worked correctly open a browser on your server and enter the address http://localhost/static/img/tux.png You should see a picture of the Linux penguin.
Next, select the top level server in the Connections pane and then double click URL Rewrite
In the top right click Add Rule and select Blank Rule.
Give it a name of QATrack Static and enter ^(static|media)/.* for the
Pattern field, and select None for the Action type. Make sure
Stop processing of subsequent rules
is checked.
When finished click Back To Rules and then add another blank rule. Give it a name of QATrack Reverse Proxy, enter (.*) for the Pattern and http://localhost:8080/{R:1} for the Rewrite URL. Make sure both Append query string and Stop processing of subsequent rules are checked.
Your URL rewrites should look like the following (order is important!)
You should now be able to visit http://localhost/ in a browser on your server and see the QATrack+ login page. Congratulations, you now have a functional QATrack+ setup on your Windows Server!
there are many different ways to configure IIS. The method I’ve used above is simple and works well when QATrack+ is the only web service running on a server.
8. Wrap Up¶
This guide shows only one of many possible method of deploying QATrack+ on Windows. It is very similar to what we use at The Ottawa Hospital Cancer Centre and it has proven to be a very solid setup. If you’re stuck with a Windows stack it will likely work for you too. Hit me up on the QATrack+ Google Group if you want to discuss some other alternatives for deploying on Windows.
References:


PI (M). (Beyond Films) Director: Darren Aronofsky Stars: Sean Gullette, Mark Margolis, Ben Shenkman, Pamela Hart, Kristyn Mae-Anne Lao, Stephen Pearlman Running time: 85 minutes.
All of a sudden, movies like Good Will Hunting and Cube have made mathematics and mathematical theory both exciting and sexy. First time feature writer/director Darren Aronofsky uses complex mathematical theories as the basis for the plot of Pi, his ambitious, but off beat and unsettling low budget thriller.
Highly strung number theorist and computer whiz Max Cohen (Sean Gullette) sees patterns everywhere in nature. He is obsessed with discovering a code that will crack open the secrets of the stock market. His holy grail is the 216 digit number that will supposedly unlock the secrets of the universe. Max refuses to heed his ailing mentor (Mark Margolis), who warns him of the folly of pursuing his quest. Somehow his search brings him into contact with a shadowy Wall Street firm that want to use his expertise, and some renegade Hassidic Jews who want to unlock the centuries old key to their religion. They believe that Max's research will enable them to see the face of God. Gullette, who shares a screen writing credit for the film, gives an unnerving and edgy performance that captures the desperate and disturbed air of this unusual protagonist.
Pi is not an action thriller, despite a chase sequence filmed with the stop motion style of photography championed by Chris Doyle and Hong Kong cinema. Rather, this is a challenging and cerebral, paranoid sci-fi fable for our times. The film raises a number or questions about our soulless contemporary society and its obsession with technology. Pi also deftly mixes complex mathematical concepts with religion, but the film risks becoming inaccessible. Aronofsky seems to become too clever in exploring the film's intelligent yet complex themes, and he does not hand out easy answers. His deliberately allusive structure and elusive images will potentially alienate many within the audience. Much of the film takes place inside Max's cramped, over crowded apartment, where he hides from the real world behind his locked door. This gives the film a claustrophobic feel. The banks of computer equipment that line his apartment also lend something of an otherworldly feel to this environment. Aronofsky also imbues the film with an uneasy air of paranoia. Matthew Libatique's cool, sparse black and white cinematography evokes the look and feel of the film noir of the 50's and '60's.
** greg king http://www.netau.com.au/gregking
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


What triangle is it?
Input the values to know what type of triangle it is.
Side 1:
Side 2:
Side 3:
Submit


Quick style
Collect code
Thoughtful design
Uplaunch is an HTML5 pack of eye-catching coming soon pages that help to start your project extremely fast. Engage with your customers with the elegant ready-to-use solution.


Developing SCTP applications using SctpDrv
The SctpDrv installer adds libraries and headers during a standard installation which can be used to develop SCTP applications.
SctpDrv installs its files to C:\Program Files\SctpDrv: an import library can be found in lib\sctpsp.lib
The DLL which applications which use SCTP specific functionality (as opposed to using nothing but the standard Winsock/BSD socket calls) need to link against is sctpsp.dll and can be found in C:\Program Files\SctpDrv\bin; on 64-bit systems, a 32-bit version of sctpsp.dll is installed to C:\Program Files (x86)\SctpDrv\bin .
To use the SCPI API or the SCTP specific structures, include ws2sctp.h from C:\Program Files\SctpDrv\inc\ws2sctp.h .
Time: 13:16:10 GMT, June 29, 2010


| Pants Alteration Prices | |
|---|---|
| Hem | $20 and up |
| Hem with Cuffs | $25 and up |
| Zipper | $25 and up |
| Taper | $25 and up |
| Waist/Seat | $25 and up |
| Original Hem | $30 and up |
Pants Alterations With Ease
Thanks to BZ Tailor's fantastic, hassle-free service, it's easier than ever to get your clothing altered by a professional. Here's how it works: Give us a call to schedule an appointment with our professional tailor. He'll come to your home or office to take measurements and pick up your clothing. He'll make the necessary alterations at his office and then return your clothing back to you within three business days. It couldn't be easier than that. No other service in New York City provides door-to-door alterations like we do. Plus, with prices like ours, there's no reason you shouldn't have every item of clothing in your closet professionally tailored to the perfect custom fit.
Save Time and Money on Clothing with BZ Tailor
Imagine how much money you spend on new pants each season. Now imagine a closet full of pants that fit perfectly, without having to constantly shop for new items. Whether you've lost or gained weight, ripped a hole in your favorite pants, broke a zipper, or just aren't comfortable in your clothing, our tailors can help you achieve the perfect fit with every pair of pants you own. You'll save so much time on clothes shopping, not to mention hundreds of dollars, now that you don't need to buy new clothes every season. We're fast, affordable, and we want to help you.
 Call BZ Tailor to schedule an appointment today.


Scan Consistency Using the C SDK with Couchbase Server
You can balance performance against consistency in N1QL queries via the LCB client and the AtPlus option.
Using CONSISTENCY_REQUEST
guarantees that the query will include newly-inserted documents:
#include <libcouchbase/couchbase.h> #include <libcouchbase/api3.h> #include <libcouchbase/n1ql.h> #include <string> #include <vector> static int RandomNumber_g; typedef std::vector<std::string> RowList; static void query_callback(lcb_t, int, const lcb_RESPN1QL *resp) { if (resp->rc != LCB_SUCCESS) { fprintf(stderr, "N1QL query failed (%s)\n", lcb_strerror(NULL, resp->rc)); } if (resp->rflags & LCB_RESP_F_FINAL) { // We're simply notified here that the last row has already been returned. // no processing needed here. return; } // Add rows to the vector, we'll process the results in the calling // code. RowList *rowlist = reinterpret_cast<RowList*>(resp->cookie); rowlist->push_back(std::string(resp->row, resp->nrow)); } int main(int, char **) { lcb_t instance; lcb_create_st crst; lcb_error_t rc; memset(&crst, 0, sizeof crst); crst.version = 3; crst.v.v3.connstr = "couchbase://<IP_ADDRESS>/default"; rc = lcb_create(&instance, &crst); rc = lcb_connect(instance); lcb_wait(instance); rc = lcb_get_bootstrap_status(instance); // Initialize random seed to get a "random" value in our documents srand(time(NULL)); RandomNumber_g = rand() % 10000; char key[256]; sprintf(key, "user:%d", RandomNumber_g); char value[4096]; sprintf(value, "{" "\"name\":[\"Brass\",\"Doorknob\"]," "\"email\":\"brass.doorknob@juno.com\"," "\"random\":%d" "}", RandomNumber_g); printf("Will insert new document with random number %d\n", RandomNumber_g); lcb_CMDSTORE scmd = { 0 }; LCB_CMD_SET_KEY(&scmd, key, strlen(key)); LCB_CMD_SET_VALUE(&scmd, value, strlen(value)); scmd.operation = LCB_SET; lcb_sched_enter(instance); rc = lcb_store3(instance, NULL, &scmd); lcb_sched_leave(instance); lcb_wait(instance); // In real code, we'd also install a store callback so we can know if the // actual storage operation was a success. lcb_N1QLPARAMS *params = lcb_n1p_new(); lcb_CMDN1QL cmd = { 0 }; RowList rows; cmd.callback = query_callback; rc = lcb_n1p_setstmtz(params, "SELECT name, email, random FROM default WHERE $1 IN name"); // -1 for length indicates nul-terminated string rc = lcb_n1p_posparam(params, "\"Brass\"", -1); // This guarantess that the query will include the newly-inserted document. rc = lcb_n1p_setconsistency(params, LCB_N1P_CONSISTENCY_REQUEST); rc = lcb_n1p_mkcmd(params, &cmd); rc = lcb_n1ql_query(instance, &rows, &cmd); lcb_wait(instance); // To demonstrate the CONSISTENCY_REQUEST feature, we check each row for the // "random" value. Because the C standard library does not come with a JSON // parser, we are limited in how we can inspect the row (which is JSON). // For clarity, we print out only the row's "Random" field. When the // CONSISTENCY_REQUEST feature is enabled, one of the results should contain // the newest random number (the value of RandomNumber_g). When disabled, the // row may or may not appear. for (RowList::iterator ii = rows.begin(); ii != rows.end(); ++ii) { std::string& row = *ii; size_t begin_pos = row.find("\"random\""); size_t end_pos = row.find_first_of("},", begin_pos); std::string row_number = row.substr(begin_pos, end_pos - begin_pos); printf("Row has random number %s\n", row_number.c_str()); } lcb_n1p_free(params); lcb_destroy(instance); }
Setting a Scan Consistency, lets you choose between NotBounded (the default), for sharpest performance; RequestPlus, for strongest consistency; and AtPlus, for a good balance between increased performance and completeness of results:>
#include <libcouchbase/couchbase.h> #include <libcouchbase/n1ql.h> #include <string> #include <vector> #include <sstream> static int RandomNumber_g; typedef std::vector<std::string> RowList; static void query_callback(lcb_t, int, const lcb_RESPN1QL *resp) { if (resp->rc != LCB_SUCCESS) { fprintf(stderr, "N1QL query failed (%s)\n", lcb_strerror(NULL, resp->rc)); } if (resp->rflags & LCB_RESP_F_FINAL) { // We're simply notified here that the last row has already been returned. // no processing needed here. return; } // Add rows to the vector, we'll process the results in the calling // code. RowList *rowlist = reinterpret_cast<RowList*>(resp->cookie); rowlist->push_back(std::string(resp->row, resp->nrow)); } static void storage_callback(lcb_t, int cbtype, const lcb_RESPBASE *resp) { if (resp->rc != LCB_SUCCESS) { fprintf(stderr, "Failed to store document: %s\n", lcb_strerror(NULL, resp->rc)); exit(EXIT_FAILURE); } lcb_MUTATION_TOKEN *mt = reinterpret_cast<lcb_MUTATION_TOKEN*>(resp->cookie); *mt = *lcb_resp_get_mutation_token(cbtype, resp); } int main(int, char **) { lcb_t instance; lcb_create_st crst; lcb_error_t rc; memset(&crst, 0, sizeof crst); crst.version = 3; crst.v.v3.connstr = "couchbase://localhost/default?fetch_mutation_tokens=true"; rc = lcb_create(&instance, &crst); rc = lcb_connect(instance); lcb_wait(instance); rc = lcb_get_bootstrap_status(instance); // Initialize random seed to get a "random" value in our documents srand(time(NULL)); RandomNumber_g = rand() % 10000; // Install the storage callback which will be used to retrieve the // mutation token lcb_install_callback3(instance, LCB_CALLBACK_STORE, storage_callback); lcb_MUTATION_TOKEN mt; memset(&mt, 0, sizeof mt); char key[256]; sprintf(key, "user:%d", RandomNumber_g); char value[4096]; sprintf(value, "{" "\"name\":[\"Brass\",\"Doorknob\"]," "\"email\":\"brass.doorknob@juno.com\"," "\"random\":%d" "}", RandomNumber_g); printf("Will insert new document with random number %d\n", RandomNumber_g); lcb_CMDSTORE scmd = { 0 }; LCB_CMD_SET_KEY(&scmd, key, strlen(key)); LCB_CMD_SET_VALUE(&scmd, value, strlen(value)); rc = lcb_store3(instance, &mt, &scmd); lcb_wait(instance); lcb_CMDN1QL cmd = { 0 }; RowList rows; cmd.callback = query_callback; // At the time of writing, the lcb_N1QLPARAMS implementation has some // bugs in it with respect to adding mutation tokens. For this reason, we're // encoding the query manually. This would look a bit nicer if we were // using a real JSON library: const char *bucketname; lcb_cntl(instance, LCB_CNTL_GET, LCB_CNTL_BUCKETNAME, &bucketname); std::stringstream stmt; stmt << "{" "\"statement\":\"SELECT name, email, random FROM default WHERE $1 in name\"," "\"args\":[\"Brass\"]," "\"scan_consistency\":\"at_plus\","; stmt << "\"scan_vectors\":{" << "\"" << bucketname << "\":{" << "\"" < LCB_MUTATION_TOKEN_VB(&mt) < "\":[" << LCB_MUTATION_TOKEN_SEQ(&mt) << "," << "\"" < LCB_MUTATION_TOKEN_ID(&mt) << "\"" << "]" << "}" << "}" << "}"; /* The above expands to something like this: { "statement": "SELECT name, email, random FROM default WHERE $1 in name", "args": ["Brass"], "scan_consistency": "at_plus", "scan_vectors": { "default": { "29": [3, "88598346863273"] } } } */ std::string stmt_str = stmt.str(); cmd.query = stmt_str.c_str(); cmd.nquery = stmt_str.size(); rc = lcb_n1ql_query(instance, &rows, &cmd); assert(rc==LCB_SUCCESS); lcb_wait(instance); // To demonstrate the at_plus feature, // we check each row for the "random" value. // Because the C standard library does not come with a JSON // parser, we are limited in how we can inspect the row (which is JSON). // For clarity, we print out only the row's "Random" field. When the // at_plus feature is enabled, one of the results should contain // the newest random number (the value of RandomNumber_g). When disabled, the // row may or may not appear. for (RowList::iterator ii = rows.begin(); ii != rows.end(); ++ii) { std::string& row = *ii; size_t begin_pos = row.find("\"random\""); size_t end_pos = row.find_first_of("},", begin_pos); std::string row_number = row.substr(begin_pos, end_pos - begin_pos); printf("Row has random number %s\n", row_number.c_str()); } lcb_destroy(instance); }


"
Get Yo Pizza!!!!

Pick a size for Your Damn Pizza!!
Pizza Size:
Select Size
JAKE SIZE!!!

Red Sauce
White Sauce
Pink Sauce
Pick some toppings for Your Damn Pizza!!
Toppings
Number of Pizza's:
Order
Add a new Pizza
Total Cost:


| Africana Studies Department |
Geosciences Department |
| American Studies Interdepartmental Major |
German Studies Department |
| Anthropology Department |
Health and Society Minor |
| Architecture Interdepartmental Major |
History Department |
| Art Department |
International Relations, see Economics, History, or Political Science tracks |
| Asian American Studies Minor |
Italian Studies Department |
| Astronomy Department |
Jewish Studies Interdepartmental Major & Minor |
| Astrophysics Interdepartmental Major |
Language Studies/Linguistics, see Cognitive & Linguistic Science |
| Athletics, see Physical Education |
Latin American Studies Interdepartmental Major |
| Biochemistry Interdepartmental Major |
Mathematics Department |
| Biological Sciences Department |
Media Arts and Sciences Interdepartmental Major |
| Chemical Physics Interdepartmental Major |
Medieval/Renaissance Studies Interdepartmental Major |
| Chemistry Department |
Middle Eastern Studies Interdepartmental Major & Minor |
| Cinema and Media Studies Interdepartmental Major |
Music Department |
| Classical Civilization, see Classical Studies Department |
Neuroscience Interdepartmental Major |
| Classical Studies Department |
Peace and Justice Studies Interdepartmental Major |
| Cognitive & Linguistic Science |
Philosophy Department |
| Cognitive and Linguistic Sciences Interdepartmental Major |
Physical Education and Athletics Department |
| Comparative Literature Interdepartmental Major |
Physics Department |
| Comparative Race and Ethnicity Minor |
Political Science Department |
| Computer Science Department |
Psychology Department |
| East Asian Languages and Cultures Department |
Religion Department |
| East Asian Studies Interdepartmental Major |
Russian Area Studies Interdepartmental Major |
| Economics Department |
Russian Department |
| Education Department |
Sociology Department |
| English Department |
South Asia Studies Interdepartmental Major & Minor |
| Environmental Studies Interdepartmental Major |
Spanish Department |
| French Cultural Studies Interdepartmental Major |
Theatre Studies Interdepartmental Major |
| French Department |
Women and Gender Studies Department |


Data Features
What are they?
Ceci n’est pas une pipe…
— Magritte
The objective of this chapter is to develop the information model into a fully populated data source for analysis. Beginning with the challenges of “wicked problems”. Use critical thinking techniques to provide structure to your analytic reasoning. What is a Visual Analyst? How can I learn to become a Visual Analyst?
A famous painting by René Magritte reads “This is not a pipe” below the picture of a pipe, insisting on the fact that the painting of a pipe may be useful for several purposes, but not to smoke tobacco. Likewise, the populating of a model will weigh heavily on how real to life and useful your painting will be for sense-making purposes. As important as the selection of paints may be for an artist to create realism, the analyst canvas will require a careful collection and collation of quality data assets.
In this Chapter we will examine the techniques used for painting our system-based information model with the color of data. The main purpose of this chapter is to defi ne the patterns used for creating an information rich source from which your analysis methods are applied. Our goal is to complete the Models of Information phase with an as real-to-life representation of the system as possible; a continuation of the process to transform the “wicked problem” into a petri dish from which we can analyze under the Methods of Analysis microscope in Part III.
Continuing our work in Chapter 4, we’ll expand the information model through a process of fi tting data to the entities and associations. information and knowledge discovery
Knowledge Discovery Roadmap
The knowledge discovery roadmap provides the framework and process for achieving the goals for populating the model. The roadmap is based on patterns which have been researched, developed, and widely implemented from decades of practice. The knowledge discovery process involves several stages: selecting the target data, preprocessing the data, transforming them if necessary, performing data mining to extract patterns and relationships, and then interpreting and assessing the discovered structures. The process is interactive and iterative, involving numerous steps with many decisions made by the analyst:
- Data Preparation and Preprocessing
- Data Integration and Fusion
- Data Shaping and Transformation
- Data Mining and Pattern Analysis
- Interpret and evaluate findings
This Data Preparation and Preprocessing stage is concerned with selecting the data that are relevant to the analysis task. The Data integration and Fusion stage is used to describe tjhe activity of combining disparate data sources to form a . The Data Shaping and Transformation stage involves fi nding useful features to represent the data depending on the goal of the task. With dimensionality reduction or transformation methods, the eff ective number of variables under consideration can be reduced, or invariant representations for the data can be found. The Data Mining and Pattern Analysis stage is concerned with revealing patterns of interest in a particular representational form or a set of such representations, including classifi cation rules or trees, regression, and clustering.
Interpretation and evaluation is interpreting mined patterns, possibly returning to any of steps for further iteration. This step can also involve visualization of the extracted patterns and models or visualization of the data given the extracted models. The fi nal stage involves the acting on the discovered knowledge: using the knowledge directly, incorporating the knowledge into another system for further action, or simply documenting it and reporting it to interested parties. This process also includes checking for and resolving potential conflicts with previously believed (or extracted) knowledge.
Data Preparation and Preprocessing
Data preparation and preprocessing is the exploration of structured and unstructured data to discover, gather and integrate information into your model. It is the sub-process for gathering source data and organizing it to suit the needs of analysis. By following the Visualytica process, we begin this activity with the advantage of fully defining our focal questions and creating a system model. The system model created in Chapter 4 will serve as our guide for collecting and fi tting data sources to the objects and relations defined in our system.
The collation process is based on nine steps:
- Identify Essential Elements of Information
- Gathering source data
- Information Extraction
- Define entities
- Define relations
- Describe entities
- Describe relations
- Assign Metadata
- Populate the information model
These tasks are based on patterns from information architecture, database design, data mining and other information intensive disciplines. These patterns have gained widespread use …
Gathering and Working with Source Data
…the world contains an unimaginably vast amount of digital information which is getting ever vaster ever more rapidly. This makes it possible to do many things that previously could not be done: spot business trends, prevent diseases, combat crime and so on. (Economist) We’re getting better and better at collecting data, but we lag in what we can do with it. Lots of data is out there, but it’s not being used to its greatest potential because it’s not being visualized as well as it could be. With all the data we’ve collected, we still don’t have many satisfactory answers to the sort of questions that we started with. This is the greatest challenge of our information rich era: how can these questions be answered quickly, if not instantaneously? We’re getting so good at measuring and recording things, why haven’t we kept up with the methods to understand and communicate this information?
The quality, content and structure of source data are critical success factors to supporting analysis and the design of meaningful visuals.
Quality
Data are of varying quality, and most data have levels of uncertainty associated with them. As data are combined and transformed, the uncertainties may become magnifi ed. These uncertainties may have profound eff ects on the analytical process and must be portrayed to users to inform their thinking. They will also make their own judgments of data quality, uncertainty, and reliability, based upon their expertise.
Gathering relevant, timely, and accurate source data is a critical success factor to the process.
- Relevance: the usefulness of the data in the context of the focal questions.
- Clarity: the availability of a clear and shared defi nition for the data.
- Consistency: the compatibility of the same type of data from diff erent sources.
- Timeliness: the availability of data at the time required and how up to date that data is.
- Accuracy: the confi dence level of how credible and close to reality the data is, for example is the data observed and factual, or is it estimated.
- Completeness: how much of the required data is available.
In a US Government prepared publication titled A Tradecraft Primer: Structured Analytic Techniques for Improving Intelligence Analysis among the many “patterns” presented is an approach called the Quality of Information Check.
Content
Form, Dimension and Measure.
Form In The Eyes Have It: A Task by Data Type Taxonomy for Information Visualizations, author Ben Shneiderman describes seven data types: 1-dimensional, 2-dimensional, 3-dimensional, Multidimensional, Temporal, Tree, and Network.
Dimension one-dimensional (1d), two-dimensional (2d), and multi-dimensional (nD).A dimension will have a measure(s) which signifies the analytical “nature” of the variable. Measures are described in terms of quantitative or qualitative. Quantitative data are measurable and expressed as quantities which can be manipulated by arithmatic. Qualitative data is often described as nominal or ordinal type variables for which certain comparisons can be made, but can not be manipulated by arithmetic.
Structure
Structured data refers to sources which are readily formatted for analysis tasks. Typically, structured data comes in the form of tables with identifi able record sets. Unstructured data refers to sources that either do not have a data model or has one that is not easily usable for analytic purposes. The term distinguishes such information from data stored in fi elded form in tables, databases or annotated documents. Both structured and unstructured data may require manipulation and “fi tting” to meet the requirements for the desired processing task. The process of preparing collected data for analysis is called information extraction.
Data Types and Characteristics
In conventional data model design, data types are defi ned as either entities or relations. We’ll preserve this syntax to maintain reference to the origin of the pattern, but you can think of entities as being similar, if not the same as, the objects described in Chapter 3.
Entities are the data objects about which information is to be collected. Entities are usually recognizable concepts such as person, places, things, or events which have relevance to the system. There are various definitions of an entity:
“A thing which can be distinctly identified” [CHEN76] “Any distinguishable object that is to be represented in a database” [DATE86] “…anything about which we store information. For each entity type, certain attributes are stored”. [MART89]
Extending these defi nitions to our earlier example, we can make a few observations. First, countries can be distinctly identifi ed. Secondly, a country is distinguishable from another country. Lastly, each country has certain attributes such as a capital city and population.
The signifi cance of the entity concept is its relation to the objects we defi ned in our system model. Recalling that country , we now have an entity mapping to this object based on a well-defi ned data typing. It is possible however, depending on the complexity of a system object, that several entities would be required to capture the “nature” of the object. It may also be the case that you defi ne an entity where a related object does not explicitly exist. This will become more clear when we “map” our system model to a data model.
Entity attributes describe the entity of which they are associated. A particular instance of an attribute is a value. For example, “Switzerland” is one value of the attribute Name for our country entity defi ned earlier. Attributes can be classifi ed as identifi ers or descriptors. Identifi ers, more commonly called keys, uniquely identify an instance of an entity. A descriptor describes a non-unique characteristic of an entity instance. Countries have attributes such as total_area, population, population_growth, infant_mortality, infl ation, gdp_total, government, and capital.
A relationship represents an association between two or more entities. These associations may occur in several forms such as similarity, explicit reference, value co-occurrence, parent-child relations, spatial, or temporal. The identifi cation of relationships is often accomplished by relation extraction or association analysis. Relation extraction is based on free text analysis… Association analysis is a pattern of data mining that is based on “rules”. Typically, a relationship is indicated by a verb connecting the entities. For example: Countries have borders to other countries
Relationship attributes include concepts such as degree, connectivity, cardinality, direction, type, and existence. The degree of a relationship is the number of entities associated with the relationship. The connectivity of a relationship describes the mapping of associated entity instances in the relationship. The cardinality of a relationship is the actual number of related occurences for each of the two entities. The direction of a relationship indicates the originating entity of a binary relationship. The entity from which a relationship originates is the parent entity; the entity where the relationship terminates is the child entity.
Let’s look at an example. Each year the United Nations Refugee Agency conducts a statistical survey of x.
These statistics measure the flows of refugee status persons from an origin to a destination. Sudan has x degrees, meaning z countries are included in the relationship. These relations are based on (from this perspective) one-to-many. For each relation, the cardinality or weight is based on the “flow” signified by the number of refugees. The direction is from Sudan to other. The relations are independent. The existence of one entity is not dependent on the existence of others.
Declared and Derived
Relationships among information objects must be explicitly captured in a computer-manipulable form. Once this is achieved, interactive graphical representations of the relationships can be generated for analytical purposes. By this, we mean that, ideally, the model will capture relationships in a form that mimics the way humans naturally relate information.
Once relationships have been explicitly captured, specialized visual representations can be employed to discover the underlying relationships. General Similarity Explicit Reference Field/Value Co-occurrence Parent-Child Spatial-Temporal Entity to Entity via association, affiliation, and ownership. A Person or Organization relation to a Location Entity to establish physical location of a given entity Entity to Event
As illustrated in Figure X with our 1995 Dayton Peace Accords example, the entity extractions serve as the basis for establishing the relational connections. For example, Slobodan Milonevic of Serbia attended the Dayton Conference on November 21, 1995.
Scenario construction. Establishing a connection between entities, relations and an event in space and time. The intersection of the entity, relational, event and temporal elements serves as the basis for developing a scenario to support an analytic story.
We’ll explore this in fuller detail with the Data Integration and Fusion Pattern


| Home | Trees | Indices | Help |
|
|---|
|
|
Minimization and maximization algorithms.
| Functions | |||
| list |
|
||
| dictionary |
|
||
| tuple |
|
||
| tuple |
|
||
| tuple |
|
||
| float |
|
||
| dictionary |
|
| Variables | |
__package__ =
|
| Function Details |
A* search algorithm. A set of heuristics is available under
|
Minimal spanning tree.
Attention: Minimal spanning tree is meaningful only for weighted graphs. |
Return the shortest path distance between source and all other nodes using Dijkstra's algorithm.
Attention: All weights must be nonnegative. See Also: shortest_path_bellman_ford |
Return the shortest path distance between the source node and all other nodes in the graph using Bellman-Ford's algorithm. This algorithm is useful when you have a weighted (and obviously a directed) graph with negative weights.
Attention: The algorithm can detect negative weight cycles and will raise an exception. It's meaningful only for directed weighted graphs. See Also: shortest_path |
Find a maximum flow and minimum cut of a directed graph by the Edmonds-Karp algorithm.
|
Calculate the value of a cut.
|
Construct a Gomory-Hu cut tree by applying the algorithm of Gusfield.
|
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Sat Aug 25 09:56:10 2012 | http://epydoc.sourceforge.net |


There are no investments in the library.
{% if type_count > 0 %} Add an investment {% else %} Please add an investment type before you add an investment. {% endif %}
View different types of investments ({{ type_count }}) | Add an investment type


The Cthulhu Mythos is a shared fictional universe, originating in the works of American horror writer H. P. Lovecraft. The term was coined by August Derleth, a contemporary correspondent and protégé of Lovecraft, to identify the settings, tropes, and lore that were employed by Lovecraft and his literary successors. The name Cthulhu derives from the central creature in Lovecraft's seminal short story, "The Call of Cthulhu", first published in the pulp magazine Weird Tales in 1928.
Richard L. Tierney, a writer who also wrote Mythos tales, later applied the term "Derleth Mythos" to distinguish Lovecraft's works from Derleth's later stories, which modify key tenets of the Mythos. Authors of Lovecraftian horror in particular frequently use elements of the Cthulhu Mythos.
In his essay "H. P. Lovecraft and the Cthulhu Mythos", Robert M. Price described two stages in the development of the Cthulhu Mythos. Price called the first stage the "Cthulhu Mythos proper." This stage was formulated during Lovecraft's lifetime and was subject to his guidance. The second stage was guided by August Derleth who, in addition to publishing Lovecraft's stories after his death, attempted to categorize and expand the Mythos.
An ongoing theme in Lovecraft's work is the complete irrelevance of mankind in the face of the cosmic horrors that apparently exist in the universe. Lovecraft made frequent references to the "Great Old Ones", a loose pantheon of ancient, powerful deities from space who once ruled the Earth and have since fallen into a deathlike sleep. While these monstrous deities have been present in almost all of Lovecraft's published work (his second short story "Dagon," published in 1919, is considered the start of the mythos), the first story to really expand the pantheon of Great Old Ones and its themes is "The Call of Cthulhu," which was published in 1928.
Lovecraft broke with other pulp writers of the time by having his main characters' minds deteriorate when afforded a glimpse of what exists outside their perceived reality. He emphasized the point by stating in the opening sentence of the story that "The most merciful thing in the world, I think, is the inability of the human mind to correlate all its contents."
Writer Dirk W. Mosig notes that Lovecraft was a "mechanistic materialist" who embraced the philosophy of cosmic indifference (Cosmicism). Lovecraft believed in a purposeless, mechanical, and uncaring universe. Human beings, with their limited faculties, can never fully understand this universe, and the cognitive dissonance caused by this revelation leads to insanity, in his view. This perspective made no allowance for religious belief which could not be supported scientifically, with the incomprehensible, cosmic forces of his tales having as little regard for humanity as humans have for insects.
There have been attempts at categorizing this fictional group of beings. Phillip A. Schreffler argues that by carefully scrutinizing Lovecraft's writings, a workable framework emerges that outlines the entire "pantheon"—from the unreachable "Outer Ones" (e.g. Azathoth, who occupies the centre of the universe) and "Great Old Ones" (e.g. Cthulhu, imprisoned on Earth in the sunken city of R'lyeh) to the lesser castes (the lowly slave shoggoths and the Mi-go).
David E. Schultz, however, believes that Lovecraft never meant to create a canonical Mythos but rather intended his imaginary pantheon to merely serve as a background element. Lovecraft himself humorously referred to his Mythos as "Yog Sothothery" (Dirk W. Mosig coincidentally suggested the term Yog-Sothoth Cycle of Myth be substituted for Cthulhu Mythos). At times, Lovecraft even had to remind his readers that his Mythos creations were entirely fictional.
The view that there was no rigid structure is expounded upon by S. T. Joshi, who said "Lovecraft's imaginary cosmogony was never a static system but rather a sort of aesthetic construct that remained ever adaptable to its creator's developing personality and altering interests. . . . There was never a rigid system that might be posthumously appropriated. . . . The essence of the mythos lies not in a pantheon of imaginary deities nor in a cobwebby collection of forgotten tomes, but rather in a certain convincing cosmic attitude."
Price, however, believed that Lovecraft's writings could at least be divided into categories and identified three distinct themes: the "Dunsanian" (written a similar style as Lord Dunsany), "Arkham" (occurring in Lovecraft's fictionalized New England setting), and "Cthulhu" (the cosmic tales) cycles. Writer Will Murray noted that while Lovecraft often used his fictional pantheon in the stories he ghostwrote for other authors, he reserved Arkham and its environs exclusively for those tales he wrote under his own name.
Although the Mythos was not formalized or acknowledged between them, Lovecraft did correspond and share story elements with other contemporary writers including Clark Ashton Smith, Robert E. Howard, Robert Bloch, Frank Belknap Long, Henry Kuttner, Henry S. Whitehead, and Fritz Leiber—a group referred to as the "Lovecraft Circle."
For example, Robert E. Howard's character Friedrich Von Junzt reads Lovecraft's Necronomicon in the short story "The Children of the Night" (1931), and in turn Lovecraft mentions Howard's Unaussprechlichen Kulten in the stories "Out of the Aeons" (1935) and "The Shadow Out of Time" (1936). Many of Howard's original unedited Conan stories also involve parts of the Cthulhu Mythos.
Price denotes the second stage's commencement with August Derleth. The principal difference between Lovecraft and Derleth being Derleth's use of hope and development of the idea that the Cthulhu mythos essentially represented a struggle between good and evil. Derleth is credited with creating the "Elder Gods." He stated: As Lovecraft conceived the deities or forces of his mythos, there were, initially, the Elder Gods. These Elder Gods were benign deities, representing the forces of good, and existed peacefully, very rarely stirring forth to intervene in the unceasing struggle between the powers of evil and the races of Earth. These powers of evil were variously known as the Great Old Ones or the Ancient Ones.
Price believes that the basis for Derleth's system is found in Lovecraft: "Was Derleth's use of the rubric 'Elder Gods' so alien to Lovecraft's in At the Mountains of Madness? Perhaps not. In fact, this very story, along with some hints from "The Shadow over Innsmouth", provides the key to the origin of the 'Derleth Mythos'. For in At the Mountains of Madness is shown the history of a conflict between interstellar races, first among them the Elder Ones and the Cthulhu-spawn.
Derleth himself believed that Lovecraft wished for other authors to actively write about the Mythos as opposed to it being a discrete plot device within Lovecraft's own stories. Derleth expanded the boundaries of the Mythos by including any passing reference to another author's story elements by Lovecraft as part of the genre. Just as Lovecraft made passing reference to Clark Ashton Smith's Book of Eibon, Derleth in turn added Smith's Ubbo-Sathla to the Mythos.
Derleth also attempted to connect the deities of the Mythos to the four elements ("air", "earth", "fire", and "water"), creating new beings representative of certain elements in order to legitimize his system of classification. Derleth created "Cthugha" as a sort of fire elemental when a fan, Francis Towner Laney, complained that he had neglected to include the element in his schema. Laney, the editor of The Acolyte, had categorized the Mythos in an essay that first appeared in the Winter 1942 issue of the magazine.
Impressed by the glossary, Derleth asked Laney to rewrite it for publication in the Arkham House collection Beyond the Wall of Sleep (1943). Laney's essay ("The Cthulhu Mythos") was later republished in Crypt of Cthulhu #32 (1985). In applying the elemental theory to beings that function on a cosmic scale (e.g. Yog-Sothoth) some authors created a fifth element that they termed aethyr.


*Be certain to double-check which volunteer you want to delete before submitting!
Validate by pasting .xhtml copy's URL into https://html5.validator.nu/


Becca Lee
Get to Know Me
Nice to meet you! My name's Becca and I'm a Seattle-based JavaScript student and tech marketer. I'm a voracious
learner who loves to translate my knowledge and intuition into thoughtful coding and marketing strategies. When
I'm not working, you can find me cuddling cats, baking pies, eating ice cream, playing pinball, getting excited
about neighborhood dogs, going on hikes, and watching pro wrestling (but you already know some of that from our
Q & A fun!).
Goals
I'm excited to be learning JavaScript and looking forward to having enough mastery to be able to help others
learn. All in good time!
Education
- I'm currently in Code Fellows 201 working on my Certificate of Software Development.
- In 2016 I completed my Bachelor of Science in Marketing Management from WGU Washington.
- Back in another life, I completed my AAS in Apparel Design and Services in 2007.
Career History
| Job Title |
Company |
Dates |
| Marketing Manager |
Formidable |
Feb 2017 - Jul 2018 |
| Marketing Coordinator |
Marx Foods |
Sep 2014 - Aug 2016 |
| Administrative Coordinator |
Ada Developers Academy |
Mar 2014 - Sep 2014 |
For more info on my career visit my LinkedIn page.
10 Fun Facts About Me
- I didn't get my first driver's license until I was 29
- I've never been stung by a bee
- I've never broken a bone
- I can do an extremely good single eyebrow raise (The Rock would be proud)
- I can trace my path to learning to code through a series of events dating back to 2013
- I've never had a dog, but desperately want one someday
- London is my favorite place I've ever travelled to
- I love baking, especially pies
- I got really into canning one summer and did a different fruit or vegetable every weekend. It was... a lot.
- I like going on walks around Green Lake, partially for the exercise, and partially for the dog watching


TIFFFlush
Section: Misc. Reference Manual Pages (3T)
Updated: December 16, 1991
Index
Return to Main Contents
NAME
TIFFFlush, TIFFFlushData - flush pending writes to an open
TIFF
file
SYNOPSIS
#include <tiffio.h>
int TIFFFlush(TIFF* tif)
int TIFFFlushData(TIFF* tif)
DESCRIPTION
TIFFFlush
causes any pending writes for the specified file (including writes
for the current directory)
to be done.
In normal operation this call is never needed- the library
automatically does any flushing required.
TIFFFlushData
flushes any pending image data for the specified file to be written out;
directory-related data are not flushed.
In normal operation this call is never needed- the library
automatically does any flushing required.
RETURN VALUES
0 is returned if an error is encountered, otherwise 1 is returned.
DIAGNOSTICS
All error messages are directed to the
TIFFError(3T)
routine.
SEE ALSO
libtiff(3T),
TIFFOpen(3T),
TIFFWriteEncodedStrip(3T),
TIFFWriteEncodedTile(3T),
TIFFWriteRawStrip(3T),
TIFFWriteRawTile(3T),
TIFFWriteScanline(3T),
TIFFWriteTile(3T)
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- RETURN VALUES
-
- DIAGNOSTICS
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 01:31:37 GMT, November 23, 1999


Toggle first element Toggle second element Toggle both elements
I am trying to make a nice website.
I hope you like it.


OpenStack setup without the aid of a deployment tool can be a damper for people taking their baby steps in to the world of OpenStack. There are multiple options available in OpenStack today for this kind of setup like Devstack, Packstack which make it easier to setup OpenStack.
RDO and Packstack
In this blog I would like share my experience deploying a multi-node OpenStack PoC (Proof of Concept) setup using RDO and Packstack.
-
RDO is simply a distribution of OpenStack for Red Hat Enterprise Linux (RHEL), Fedora and derivatives (e.g.: CentOS).
-
PackStack is a Puppet based tool that simplifies the deployment of RDO.
Most of the documentation about RDO and PackStack was related to all-in-one setup which lets you setup OpenStack on a single machine Physical or Virtual.
All right, lets get started with a description of OpenStack Mitaka components we are going to setup.
Controller
The Controller node is where most of the shared OpenStack services and other tools run. The Controller node supplies API, scheduling, and other shared services for the cloud. The Controller node has the dashboard, the image store, and the identity service. Additionally, Nova compute management service as well as the Neutron server are also configured in this node.
System Requirements
1 GB Ram
30 GB HDD
Networking - Single NIC card
Management (eth0)
Networking
The Network node provides virtual networking and networking services to Nova instances using the Neutron Layer 3 and DHCP network services.
System Requirements
1 GB Ram
30 GB HDD
Networking - Three NIC card
Management (eth0)
Guest Data (eth1)
External Network (eth2)
Compute
The Compute node is where the VM instances (Nova compute instances) are installed. The VM instances use iSCSI targets provisioned by the Cinder volume service. There are multiple options for compute node like KVM, Hyper-v and even docker. KVM was used in this particular case.
System Requirements
4 GB Ram
60 GB HDD (excluding OS)
Networking - Two NIC card
Management (eth0)
Guest Data (eth1)
Networking
Few words on networking. Although there are many other options available for networking, OVS was considered for this setup. Ideally Management network should be isolated from the rest of the Network for security purposes. This being a PoC setup all the networking was done on a single VLAN although they are physically separated.
Management (eth0 on all hosts)
This network is used for management only.
Guest data (eth1 on all hosts)
This is used by guests to communicate with each other. We will be using a single VLAN for this PoC.
Public (eth2 on all hosts)
This is used by hosts to communicate with external network routed through the Network node. External hosts will be able to reach the guests(instances) on the basis of external ip and security groups.
Host configuration
Server Hostname
-
stack-pocbox-controller
-
stack-pocbox-network
-
stack-pocbox-compute
Network
This being a PoC setup all the networking was done on a
single VLAN although they are physically separated.
VLAN 150
<IP_ADDRESS> - <IP_ADDRESS>
<IP_ADDRESS>/22
Note You can use any Network Subnet or VLAN ID as per your requirement.
Operating System
CentOS 7
Server configuration (repeat this on all nodes)
Update OS to latest
$ yum update
Disable FirewallD, NetworkManager:
$ systemctl disable Firewalld
$ systemctl disable NetworkManager
$ systemctl mask Firewalld
Set Hostname
systemctl set-hostname
Disable selinux
/etc/sysconfig/selinux
set to “permissive”
Enable iptables
$ yum install iptables-services
$ systemctl enable iptables
Create hosts file and copy this to all hosts Note
-
Management (eth0) ip is used for hostname on the nodes
-
Static IP
-
I prefer updating /etc/hosts even though i have a working DNS
cat /etc/hosts <IP_ADDRESS> localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 <IP_ADDRESS> stack-pocbox-controller.local stack-pocbox-controller <IP_ADDRESS> stack-pocbox-network.local stack-pocbox-network <IP_ADDRESS> stack-pocbox-compute.local stack-pocbox-compute
If you are using non-English locale make sure your /etc/environment is populated:
LANG=en_US.utf-8
LC_ALL=en_US.utf-8
Network Configuration
Repeat the same for eth0, eth1 and eth2 on all the nodes
cat /etc/sysconfig/network-scripts/ifcfg-eth0
TYPE="Ethernet"
BOOTPROTO="static"
DEFROUTE="yes"
PEERDNS="yes"
PEERROUTES="yes"
IPV4_FAILURE_FATAL="no"
IPV6INIT="no"
NAME="eth0"
UUID="9c31d94b-d0d1-45bc-90c3-3c2bfb6c166b"
DEVICE="eth0"
ONBOOT="yes"
IPADDR=<IP_ADDRESS>
NETMASK=<IP_ADDRESS>
GATEWAY=<IP_ADDRESS>
DOMAIN="bedford.progress.com"
DNS1=<IP_ADDRESS>
DNS2=<IP_ADDRESS>
Configure Chrony NTP for server and clients
Server (Controller Node)
$ chkconfig ntp off
$ yum remove ntp
$ yum install chrony
Open chrony.conf and replace ‘allow <IP/CIDR>’ with your Management network
Enable chrony
$ systemctl enable chronyd.service
$ systemctl start chronyd.service
$ systemctl restart chronyd.service
Reboot
init 6
Install OpenStack
Install PackStack (Controller Node)
$ sudo yum install -y centos-release-openstack-mitaka
$ sudo yum update -y
$ sudo yum install -y openstack-packstack
Generate answer file (Controller Node)
$ packstack --gen-answer-file=packstack_answers.conf
Modify answer file to change ip address of Network and Compute node
CONFIG_COMPUTE_HOSTS=<IP_ADDRESS>
CONFIG_NETWORK_HOSTS=<IP_ADDRESS>
Answer is already populated with random passwords for all your services, change them as required
(Optional) I choose to installHeat* as well*
CONFIG_HEAT_INSTALL=y
Install openstack
$ packstack --answer-file=packstack_answers.conf
Once install is successful you will see a screen similar to this
*** Installation completed successfully ***
Additional information:
* Time synchronization installation was skipped. Please note that unsynchronized time on server instances might be problem for some OpenStack components.
* File /root/keystonerc_admin has been created on OpenStack client host <IP_ADDRESS>. To use the command line tools you need to source the file.
* To access the OpenStack Dashboard browse to http://<IP_ADDRESS>/dashboard .
Please, find your login credentials stored in the keystonerc_admin in your home directory.
* To use Nagios, browse to http://<IP_ADDRESS>/nagios username: nagiosadmin, password: 8908d16396354aa4
* The installation log file is available at: /var/tmp/packstack/20160621-160219-uCI8ju/openstack-setup.log
* The generated manifests are available at: /var/tmp/packstack/20160621-160219-uCI8ju/manifests
Open Horizon Dashboard
http://<IP_ADDRESS>/dashboard
The root password setup by PackStack script is available in /root/keystonerc_admin
Source /root/keystonerc_admin file
$ . /root/keystonerc_admin
Configure OpenStack
The following tasks were performed as a part of initial configuration.
- Network Configuration
- Clean up default network created by PackStack script
- Create new Public, Private network and its subnet
- Create a new router
- Upload a CentOS qcow2 image
- Create a Key pair
- Configure Security Group
- Deploy an instance from CentOS image
- Attach floating IP
- Login to instance
Network Configuration (Network Node)
$ ovs-vsctl show
Bridge "br-eth1”
Port "br-eth1”
Interface "br-eth1”
type: internal
Port “eth1”
Interface “eth1”
Bridge br-int
fail_mode: secure
Port br-int
Interface br-int
type: internal
Port patch-tun
Interface patch-tun
type: patch
options: {peer=patch-int}
Port "tap15df1b42-06"
tag: 1
Interface "tap15df1b42-06"
type: internal
Port "qr-494def92-bc"
tag: 1
Interface "qr-494def92-bc"
type: internal
Bridge br-ex
Port “eth2”
Note that eth1 is a port on Bridge br-eth1 and eth2 is a port on Bridge br-ex. This would be missing in your Network node at this point. Let’s go ahead and add this.
Networking
Management (eth0)
Guest Data (eth1)
External Network (eth2)
$ ovs-vsctl add-br br-eth1
$ ovs-vsctl add-port br-eth1 eth1
$ ovs-vsctl add-port br-ex eth2
Repeat the steps for Compute Node
$ ovs-vsctl add-br br-eth1
$ ovs-vsctl add-port br-eth1 eth1
Clean up default network created by PackStack script
Open Horizon Dashboard
http://<IP_ADDRESS>/dashboard
The admin password setup by PackStack script is available in /root/keystonerc_admin
Source /root/keystonerc_admin file
$ . /root/keystonerc_admin
Delete existing network and routers
Create new Public Network
This network will have access to the outside (external) network. I am using the same as VLAN 150 mentioned before. The public-subnet(more about this in a moment) will be created by using a subgroup of ip’s from the <IP_ADDRESS>/22 subnet.
Create Public Subnet
I have assigned a subgroup of IP from VLAN 150 to the public Sidney. This will be used by OpenStack to assign elastic IP for the VM’s
Note that DNS server although a different subnet is routable on VLAN 150 and this is done on the network side.
Ideally the external Network should be able to reach Internet. This needs to be configured on the network end
Create new Private Network
Create Private Subnet
You can choose a Private IP range appropriate to your organisation.
Configure Security Group
Note: The following security group configuration was done with PoC in mind. DO NOT USE THIS FOR PRODUCTION
We will create a security group that will allow all Incoming and Outgoing traffic.
From Project -> Access and Security -> Security Groups Select default and click on Manage rules.
Configure the group to look like this.
Create a Key Pair
From Project -> Access and Security -> Key Pairs select +Create Key Pair
Download the .pem file for later use
You can also create your own RSA key and upload if you prefer doing so
Upload CentOS 7 image
The default Cirros image does not do much.Lets upload create a CentOS image for creating our first instance.
Copy the url CentOS latest version ISO image from here
Copy the ISO url.There is no need to download the ISO Image.
From Admin -> Images select Create Image
Paste the URL in to the field for Image Location.
(https://cloud.githubusercontent.com/assets/10396579/16555562/0460c1b2-41f3-11e6-9b0a-e05855e02819.png)
Launch instance and attach floating ip
Now that we uploaded a CentOS image. Let’s go ahead and Launch Instance and attach a floating IP
From Project -> Instances -> Launch Instance
- Details
Provide Instance name(Leave rest to defaults)
- Source
Select the CentOS image that was created
- Flavour
Select Flavour(depending on the compute instance)
- Networks
Select "Private Network"
- Network Ports
Leave default
- Security Groups
Select "default" security group that was configured
- Key pair
Select the key pair that created(Might be the only option unless you have created multiple
Launch Instance to create instance.
Attach floating IP
From Project -> Instances -> Instance Name -> Action drop down select Associate Floating IP
Login to instance
Once the instance is up and running. You should be able to login with the floating IP assigned.
$ ssh -l CentOS -i <pem _key> <floating_ip>
Part 2
In Part 2 of this blog we will explore how to add a Second Compute node


An object-oriented language with eager evaluation, first-class functions, and dynamic types. It is based on a notion of objects as mutable and extensible records. There are no classes.
An interesting feature of the language is that, since "everything is an object", a value may behave simultaneously as an integer, boolean, function, and a record. This is reminiscent of intersection types.


The installml script moves a heap image . arch- osname to ../../bin/.heap/sml. arch- osname. Moreover, it moves the libraries under .lib to ../../lib and updates ../../lib/pathconfig accordingly.
The script takes one optional argument which specifies . If no argument is given, defaults to sml.


class BingAdsApi::Reporting
Public : This class represents the Reporting Services defined in the Bing Ads API, to request and download reports
- Author
-
<EMAIL_ADDRESS>Examples
options = { :environment => :sandbox, :username => "username", :password => "pass", :developer_token => "SOME_TOKEN", :customer_id => "1234567", :account_id => "9876543" } service = BingAdsApi::Reporting.new(options)
Public Instance Methods
poll_generate_report(report_request_id)
click to toggle source
Public : Get the status of a report request
- Author
-
<EMAIL_ADDRESS>Parameters¶ ↑
report_request_id
- Identifier of the report request
Examples ¶ ↑
service.poll_generate_report("12345") # => Hash
- Returns
-
Hash with the PollGenerateReportResponse structure
- Raises
-
exception
# File lib/bing-ads-api/service/reporting.rb, line 34 def poll_generate_report(report_request_id) response = call(:poll_generate_report, {report_request_id: report_request_id} ) response_hash = get_response_hash(response, __method__) report_request_status = BingAdsApi::ReportRequestStatus.new( response_hash[:report_request_status]) return report_request_status end
submit_generate_report(report_request)
click to toggle source
Public : Submits a report request
- Author
-
<EMAIL_ADDRESS>Parameters¶ ↑
report_request
- a BingAdsApi::ReportRequest subclass instance
Examples ¶ ↑
CampaignPerformanceReportRequest¶ ↑
report_request = BingAdsApi::CampaignPerformanceReportRequest.new(:format => :xml, :language => :english, :report_name => "My Report", :aggregation => :hourly, :columns => [:account_name, :account_number, :time_period, :campaign_name, :campaign_id, :status, :currency_code, :impressions, :clicks, :ctr, :average_cpc, :spend, :conversions, :conversion_rate, :cost_per_conversion, :average_cpm ], :filter => { # String as bing expected :ad_distribution => "Search", :device_os => "Windows", # snake case symbol :device_type => :computer, # nil criteria :status => nil }, :scope => {:account_ids => 5978083, :campaigns => [ {:account_id => 5978083, :campaign_id =><PHONE_NUMBER>}, {:account_id => 5978083, :campaign_id =><PHONE_NUMBER>}, {:account_id => 5978083, :campaign_id =><PHONE_NUMBER>}] }, :time => { :custom_date_range_end => {:day => 31, :month => 12, :year => 2013}, :custom_date_range_start => {:day => 1, :month => 12, :year => 2013}, }) report_request_id = reporting_service.submit_generate_report(report_request) # => "1234567890"
- Returns
-
String with the requested report id
- Raises
-
Exception if report_request is invalid or SOAP request failed
# File lib/bing-ads-api/service/reporting.rb, line 85 def submit_generate_report(report_request) response = call(:submit_generate_report, {report_request: report_request.to_hash(:camelcase)}) response_hash = get_response_hash(response, __method__) report_request_id = response_hash[:report_request_id] return report_request_id end


The Hasselt University house style provides a PowerPoint template, but no alternative for the LaTeX document class Beamer. This project aims to provide this alternative.
Example:
Code:
\begin{frame}{boxes}
\greybox{123}
\greenbox{456}{789}
\bluebox{101}{112}
\end{frame}
Output:
Dark theme:
Light theme:


I am a senior software developer and technical leader at Solace, a high-tech startup specializing in enterprise message and event broker software. I am self-driven and passionate about what I do, with 6 years of experience developing a Linux high-performance multi-threaded application using C++, as well as an internal Python framework for data processing and code generation. I received a national Schulich Leader Scholarship to attend McGill University where I earned a bachelor of computer engineering, graduating with distinction.
In my spare time, I enjoy working on personal programming projects. Take a look at my GitHub profile or check out:
- VoIP.ms SMS: popular Android messaging app that has become the de facto SMS app for the VoIP.ms platform
- js2xmlparser: popular Node.js module for parsing JavaScript objects into XML; downloaded 200 million times
- xmlcreate: Node.js module for building XML using a simple API; used to implement js2xmlparser
If you'd like to contact me, please send me an email at michael [at] kourlas [dot] com.


Transfer
You can send money to another account
Amount to transfer:
UAH
UAH
Destination account number:
Transfer money


FM Qureshi visits ailing Naeemul Haque to inquire after health
by https://www.facebook.com/dunyanewsISLAMABAD (Dunya News) – Foreign Minister Shah Mehmood Qureshi Thursday visited a private hospital in Islamabad to inquire after the health of ailing Naeemul Haque, Special Assistant to the Prime Minister.
The Pakistan Tehreek-e-Insaf (PTI) leader is undergoing cancer treatment at the hospital. The foreign minister prayed for Naeemul Haque’s health and wished that he once again takes charge of his responsibilities after recuperating.
“Naeemul Haque is a valuable asset of PTI and his immense services for the party are not hidden from anyone. He is one of the founding leaders of Pakistan Tehreek-e-Insaf,” Shah Mehmood Qureshi maintained.


About
Quality Assured: We at Stuff Dressmakers pride ourselves in providing you with quality and yet affording clothing. Our materials are carefully selected to suit your comfort; Light but not transparent and importantly comfortable.
On-time delivery: For that occasion you got your (Aso Ebi) materials late, we have got you covered! We sew the best style and get them ready at your door step.
Dresses & Order
Your Choice, Our priority
Full Length Jilbab #20,000
Half Khimar #15000


Source code for Solid.StochasticHillClimb
from abc import ABCMeta, abstractmethod
from copy import deepcopy
from math import exp
from random import random
[docs]class StochasticHillClimb:
"""
Conducts stochastic hill climb
"""
__metaclass__ = ABCMeta
initial_state = None
current_state = None
best_state = None
cur_steps = 0
max_steps = None
best_objective = None
max_objective = None
temp = None
def __init__(self, initial_state, temp, max_steps, max_objective=None):
"""
:param initial_state: initial state of hill climbing
:param max_steps: maximum steps to run hill climbing for
:param temp: temperature in probabilistic acceptance of transition
:param max_objective: objective function to stop algorithm once reached
"""
self.initial_state = initial_state
if isinstance(max_steps, int) and max_steps > 0:
self.max_steps = max_steps
else:
raise ValueError('Max steps must be a positive integer')
if max_objective is not None:
if isinstance(max_objective, (float, int)):
self.max_objective = float(max_objective)
else:
raise ValueError('Maximum objective must be a numeric type')
if isinstance(temp, (float, int)):
self.temp = float(temp)
else:
raise ValueError('Temperature must be a numeric type')
def __str__(self):
return ('STOCHASTIC HILL CLIMB: \n' +
'CURRENT STEPS: %d \n' +
'BEST OBJECTIVE: %f \n' +
'BEST STATE: %s \n\n') % \
(self.cur_steps, self.best_objective, str(self.best_state))
def __repr__(self):
return self.__str__()
def _clear(self):
"""
Resets the variables that are altered on a per-run basis of the algorithm
:return: None
"""
self.cur_steps = 0
self.current_state = None
self.best_state = None
self.best_objective = None
@abstractmethod
def _neighbor(self):
"""
Returns a random member of the neighbor of the current state
:return: a random neighbor, given access to self.current_state
"""
pass
@abstractmethod
def _objective(self, state):
"""
Evaluates a given state
:param state: a state
:return: objective function value of state
"""
pass
def _accept_neighbor(self, neighbor):
"""
Probabilistically determines whether or not to accept a transition to a neighbor
:param neighbor: a state
:return: boolean indicating whether or not transition was accepted
"""
try:
p = 1. / (1 + (exp((self._objective(self.current_state) - self._objective(neighbor)) / self.temp)))
except OverflowError:
return True
return True if p >= 1 else p >= random()
[docs] def run(self, verbose=True):
"""
Conducts hill climb
:param verbose: indicates whether or not to print progress regularly
:return: best state and best objective function value
"""
self._clear()
self.current_state = self.initial_state
for i in range(self.max_steps):
self.cur_steps += 1
if ((i + 1) % 100 == 0) and verbose:
print self
neighbor = self._neighbor()
if self._accept_neighbor(neighbor):
self.current_state = neighbor
if self._objective(self.current_state) > self.best_objective:
self.best_objective = self._objective(self.current_state)
self.best_state = deepcopy(self.current_state)
if self.max_objective is not None and self.best_objective > self.max_objective:
print "TERMINATING - REACHED MAXIMUM OBJECTIVE"
return self.best_state, self.best_objective
print "TERMINATING - REACHED MAXIMUM STEPS"
return self.best_state, self.best_objective


Resetting WiFi Configuration
Your Keg Cop's WiFi connection settings are being reset which will cause it to forget your network configuration. After this is complete, it will reboot, and will create the configuration Access Point. To reconnect your Keg Cop to your network you will need to connect to the configuration Access Point and provide new WiFi settings.
You may close this web page.


{% extends "base.html" %} {% block title %}500 | Instant Census{% endblock %} {% block page_name %}Error: (500){% endblock %} {% block content %}
Looks like something broke. Don't panic.
We track these errors automatically and should have it fixed in a jiffy.
Send us an email at<EMAIL_ADDRESS>if you would like assistance.


|
|||||||||
| PREV NEXT | FRAMES NO FRAMES |
Args
object.
InputDefinition
.
Element
object representing this argument that can be added to another XML document for the Scheme
.
ServiceArgs.setApp(String)
instead.
Application
class represents a locally-installed Splunk app.ApplicationArchive
class represents an archive of a Splunk app.ApplicationSetup
class represents the setup information for a
Splunk app.ApplicationUpdate
class represents information for an update
to a locally-installed Splunk app.Args
class is a helper class for working with Splunk REST API
arguments.Argument
class represents an argument to a modular input kind.AtomEntry
class represents an Atom <entry>
element.AtomFeed
class represents an Atom feed.AtomObject
class represents a generic Atom object.IOException
on this EventWriter.
EventWriter
.
CollectionArgs
class contains arguments for retrieving and
listing entities from a collection, such as the number of entities to return
and how to sort them.ConfCollection
class represents a collection of configuration
files.<content>
element.
Args
.
Args
instance and initializes it with a single
key-value pair.
Args
instance and initializes it with a
pre-existing hash map.
InputKind
object from a String
giving
the relative path from data/inputs/ to the kind.
DeploymentClient
class represents a Splunk deployment client,
providing access to deployment client configuration and status.DeploymentServer
class represents a Splunk deployment server,
and provides access to the configurations of all deployment servers.DeploymentServerClass
class represents a Splunk deployment server
class, providing access to the configuration of a server class.DeploymentTenant
class represents a Splunk deployment tenant, and
provides access to the multi-tenants configuration for this Splunk instance.DistributedConfiguration
class represents a Splunk distributed
search configuration, providing access to Splunk's distributed search
options.DistributedPeer
class represents a Splunk distributed peer,
providing distributed peer server management.String:String
or String:String[]
into a single UTF8-encoded string.
Args
instance into a UTF8-encoded string.
Entity
class represents a Splunk entity.EntityCollection
class represents a collection of Splunk
entities.EntityMetadata
class provides access to the metadata properties
of a corresponding entity.AtomFeed
object.
Event
class wraps an individual event or result that was returned
by the ResultsReader.getNextEvent()
method.Event
class represents an event or fragment of an event to be written by this modular input to Splunk.EventType
class represents an event type.EventTypeCollection
class represents a collection of event types.EventWriter
class encapsulates writing events and error messages to Splunk from a modular input.search/jobs/export
endpoint),
and streams results back in an input stream.
search/jobs/export
endpoint), and streams results back in an input stream.
search/jobs/export
endpoint), and streams results back in an input stream.
FiredAlert
class represents a fired alert.FiredAlertGroup
class represents a group of fired alerts, which
are the alerts for a given saved search.FiredAlertGroupCollection
class represents a collection of fired
alert groups.null
if the specified field is not present.
ActionEmailSendPdf
is
enabled.
AlertSuppress
is enabled.
Service
instance.
ModularInputKindArgument
s as corresponding values.
system
if it was inherited from the default system setting.
SavedSearch.getDispatchRealTimeBackfill()
instead.
rt_queue_size
(the number of events that the indexer should use
for this search).
InputStream
IO handle for this job's events.
InputStream
IO handle for this job's events.
InputStream
IO handle for this job's events.
Role.getImportedRealTimeSearchJobsQuota()
instead.
InputKind
representing this input's type.
Service
instance.
scheme://host[:port]
.
_rcvbuf
attribute for this
monitor input.
_rcvbuf
attribute for this
scripted input.
_rcvbuf
attribute for this
TCP input.
_rcvbuf
attribute for this
cooked TCP input.
InputStream
IO handle for the results from this job.
InputStream
IO handle for the results from this job.
InputStream
IO handle for the results from this job.
InputStream
IO handle for the preview results from
this job.
InputStream
IO handle for the preview results from
this job.
InputStream
IO handle for the preview results from
this job.
Role.getRealTimeSearchJobsQuota()
instead.
InputStream
IO handle to the search log for this job.
InputStream
IO handle to the search log for this job.
Role.getSearchTimeWindow()
instead.
"_raw"
field value.
host:port
of this server.
getConnectionTimeout
,
getReceiveTimeout
, and getSendTimeout
.
Returns the server time-out period.
Service
instance this resource is connected to.
Event
comes from.
InputStream
IO handle for the summary for this job.
InputStream
IO handle for the summary for this job.
InputStream
IO handle for the summary for this job.
java.util.Date
object giving the timestamp that should be sent with this event.
InputStream
IO handle for the timeline for this job.
InputStream
IO handle for the timeline for this job.
<title>
element.
DisplayView
attribute.
ServiceArgs.setHost(String)
instead.
HttpService
class represents a generic HTTP service at a given
address (host:port
), accessed using a given protocol scheme
(http
or https
).HttpService
instance.
HttpService
instance at the given host.
HttpService
instance at the given host and port.
HttpService
instance using the given host,
port, and scheme.
HttpService
instance using the given host,
port, and scheme, and instructing it to use the specified HTTPS handler.
<id>
element.
Index
class represents an index.IndexCollection
class represents a collection of indexes.IndexCollectionArgs
class contains arguments for retrieving
indexes from a collection (see Service.getIndexes()
).Input
class represents a data input.InputCollection
class represents a collection of inputs.InputDefinition
class encodes the XML defining inputs that Splunk passes to
a modular input script as a Java object.InputKind
enumeration defines the different types of Splunk data
inputs (input kinds).Event
objects.
Entity.update(java.util.Map)
.
Event
object.
<itemsPerPage>
element.
Job
class represents a job, which is an individual
instance of a running or completed search or report, along with its related
output.JobArgs
class contains arguments for creating a Job
.JobCollection.create(java.lang.String)
method.JobCollection.create(java.lang.String)
method.JobCollection
class represents a collection of jobs.JobEventsArgs
class contains arguments for getting events using
the Job.getEvents()
method.JobEventsArgs.setMaximumLines(int)
.JobExportArgs
class contains arguments for exporting events using
the Service.export(java.lang.String)
method.JobCollection.create(java.lang.String)
method.JobExportArgs.setMaximumLines(int)
.JobResultsArgs
class contains arguments for getting job results
using the Job.getResults()
method.JobResultsPreviewArgs
class contains arguments for getting job
results previews using the Job.getResultsPreview()
method.JobSummaryArgs
class contains arguments for getting a job summary
using the Job.getSummary()
method.License
class represents a license, providing access to the
licenses for this Splunk instance.LicenseGroup
class represents a license group, which is a
collection of one or more license stacks.LicenseMessage
class represents a license message.LicensePool
class represents a license pool, which is made up
of a single license master and zero or more license slave instances of Splunk
that are configured to use the licensing volume from a set license or license
stack.LicensePoolCollection
class represents a collection of license
pools.LicenseSlave
class represents a license slave, which is a member
of one or more license pools.LicenseStack
class represents a license stack, which is
a collection of licenses of the same type.<link>
elements in this AtomObject
.
Logger
class represents a specific Splunkd logging category.Service
instance with the username and password
that were specified when the instance was created.
Service
instance with a specified username and
password.
Message
class represents a message.MessageCollection
class represents a collection of messages,
providing access to Splunk system messages.ModularInputKind
class represents a particular modular input.ModularInputKindArgument
class is a map-like object that is
specialized to represent arguments for modular input kinds.MonitorInput
class represents a monitor input, which is a file,
directory, script, or network port that is monitored for new data.MultiResultsReader
class represents a streaming reader
for Splunk search results.MultiResultsReaderJson
class represents a streaming JSON reader
for Splunk search results.MultiResultsReaderXml
class represents a streaming XML reader for
Splunk search results.MultiValueParameter
class represents a parameter containing multiple values that is passed as part of a definition
of a modular input instance.Parameter
objects from an org.w3c.dom.Node
object containing a set of parameters.
NonblockingInputStream
class is a stream wrapper that acts as though
the underlying stream has terminated every time it blocks.OutputDefault
class represents the default TCP output
configuration, providing access to global TCP output properties.OutputGroup
class represents an output group, providing
access to the configuration of a group of one or more data-forwarding
destinations.OutputServer
class represents an output server, providing access
to data-forwarding configurations.OutputServerAllConnections
class represents all the connections
of an output server.OutputSyslog
class represents a syslog output, providing access
to properties of a forwarding server that provides data in standard syslog
format.ServiceArgs.setOwner(String)
instead.
Parameter
class is a base class for parameters of modular inputs.AtomEntry
instance based on a given stream.
AtomFeed
instance based on the given stream.
Password
class represents a saved credential.PasswordCollection
class represents a collection of credentials.ServiceArgs.setPort(int)
instead.
<published>
element.
Receiver
class represents a named index and unnamed index
receivers.ReceiverBehavior
interface represents actions to be taken given
an output stream connected to Splunk over which a program can stream events.Record
class represents an extension of HashMap
that
contains a variety of value-converting access methods.RequestMessage
class represents an HTTP request message including
method, headers, and body content.RequestMessage
instance.
RequestMessage
instance with a given method
Resource
abstract base class represents a Splunk resource.ResourceCollection
abstract base class represents a collection of
Splunk resources.ResponseMessage
class represents an HTTP response message that
includes status codes, response headers, and body content.ResultsReader
class is a base class for the streaming readers
for Splunk search results.ResultsReaderCsv
class represents a streaming CSV reader for
Splunk search results.ResultsReaderJson
class represents a streaming JSON reader for
Splunk search results.ResultsReaderXml
class represents a streaming XML reader for
Splunk search results.Role
class represents a Splunk role, which is a collection of
permissions and capabilities.SavedSearch
class represents a saved search.SavedSearchCollection
class represents a collection of saved
searches.SavedSearchCollectionArgs
class contains arguments getting a
collection of saved searches.SavedSearchDispatchArgs
class contains arguments for dispatching
a saved search using the SavedSearch.dispatch()
method.Scheme
class represents the metadata for a modular input kind.ServiceArgs.setScheme(String)
instead.
Script
class is an abstract base class for implementing modular inputs.ScriptInput
class represents a scripted data input.SearchResults
interface represents Splunk search results.Service
class represents a Splunk service instance at a given
address (host:port), accessed using the http
or https
protocol scheme.Service
instance using a host.
Service
instance using a host and port.
Service
instance using a host, port, and
scheme for accessing the service (http
or https
).
Service
instance using the given host,
port, and scheme, and instructing it to use the specified HTTPS handler.
Service
instance using a collection of arguments.
Service
instance using a map of arguments.
ServiceArgs
class contains a collection of arguments that are
used to initialize a Splunk Service
instance.ServiceInfo
class contains information about a running Splunk
Service
instance (Splunkd).ActionEmailSendPdf
is
enabled.
index
value is checked to ensure that it is the
name of a valid index.
name
value is checked to ensure that it exists.
SavedSearch.setDispatchBuckets(int)
instead.
Event
objects.
EventWriter
had an IOException
.
setSynchronizeBundleReplication
) bundle synchronization with all search peers.
setSynchronizeBundleReplication
) bundle synchronization with all search peers.
Parameter
objects giving the proposed configuration.
connectionTimeout
,
sendTimeout
, or receiveTimeout
.
SavedSearch.setRestartOnSearchPeerAdd(boolean)
instead.
host:port
where the syslog data is sent.
Event
comes from.
ALL:!aNULL:!eNULL:!LOW:!EXP:RC4+RSA:+HIGH:+MEDIUM
java.util.Date
object giving the timestamp that should be sent with this event.
Settings
class represents configuration information for an
instance of Splunk.Service
instance.
JobEventsArgs.setMaximumLines(int)
.
JobExportArgs.setMaximumLines(int)
.
Event
object.
DisplayView
attribute.
SingleValueParameter
class represents a parameter as part of a modular input instance that
contains only a single value.<startIndex>
element.
log
.
writeEvent
.
TcpConnections
class represents a raw or cooked TCP connection.TcpInput
class represents a raw TCP data input.TcpSplunkInput
class represents a Splunk-processed "cooked" TCP
data input.<title>
element.
ServiceArgs.setToken(String)
instead.
<totalResults>
element.
UdpConnections
class represents a UDP connection.UdpInput
class represents a UDP data input.<updated>
element.
Upload
class represents an in-progress oneshot upload.User
class represents a Splunk user who is registered on the
current Splunk server.UserCollection
class represents a collection of Splunk users who
are registered on the current Splunk server.refresh
if necessary.
refresh
if necessary.
refresh
if necessary.
ValidationDefinition
class represents the XML sent by Splunk for external validation of a new modular input.-1
if this version < the given version
0
if this version = the given version
1
if this version > the given version
WindowsActiveDirectoryInput
class represents a Windows Active
Directory data input.WindowsEventLogInput
class represents a Windows Event Log data
input.WindowsPerfmonInput
class represents a Windows Performance
Monitor (Perfmon) data input.WindowsRegistryInput
class represents a Windows Registry data
input.WindowsWmiInput
class represents a Windows Management
Instrumentation (WMI) data input.Event
object to Splunk.
XMLStreamWriter
.
Xml
class represents a collection of XML utilities.
|
|||||||||
| PREV NEXT | FRAMES NO FRAMES |


Packages and classes: l Class: A blueprint of an object. There must be at least one in a java program. It must have the main method. Package: A group of classes Java.lang: This package, which contains many useful classes, is always given already when you create a Java program. Import: To use any other packages, use import. When you import a package you can use all the objects and methods in that package. Importing all the classes in a package: import packagename.*; Importing one class from the package: import packagename. (ClassName); Importing classes from subpackages: import packagename.subpackage name.(ClassName); Source files: The java files that make up the program. Compiler: a thing that converts source code into a format machines can read called bytecode. Java methods must be in a class, and program statements must be put inside a method Classes that have the main method usually do not contain many other methods Keywords: class, public, static, void, main Public: everyone can access Private: only you can access Static: methods that will not have access to objects of the class. The main method is always static. Types and identifiers: Identifier:A specific name used to represent any user defined data set, such as a class or method. Primitive variable:An integer, boolean, or double. Integer:Any whole number, and does not include any decimals with the value. Boolean:A value that is either True or False. Double:Any number, and includes decimals as well as negative numbers. Float:A value that contains 32 bits(definition of bit is explained later..) IMPORTANT:Always use declaration when trying to introduce a new variable ALSO IMPORTANT:It is impossible to assign a double to an int, as it cannot hold this value.However, it is possible to assign an int to a double, since the double has the capacity to contain that value. Bit:Also known as binary digit, this value is named as the smallest value in Java. Floating Point Number: A type of decimal. Round off Error:When an error occurs in rounding a decimal value. Final variable: a variable declared by final, which makes it permanent. Operators: By Michael Arithmetic Operators Precedence: 1: parentheses 2: *, /, % 3: +,- Operator Meaning Example + addition 3 + x - subtraction P - q * multiplication 6 * i / division 10/4: (returns 2, not 2.5) % mod(remainder) 11%8: (returns 3) Can be applied to int and double (double) ¾ = 0.75 (double)(¾) = 0 Relational Operators: used in boolean expressions for true or false Int is promoted to a double Do not compare floating values with relational operators Operator Meaning Example == Equal to If (x == 100) != Not equal to If (age != 21) > Greater than If (salary > 30000) Less than If (grade less than symbol 65) >= Greater than or equal to If (age >= 16) less than equal symbol Less than or equal to If (height less than equal to symbol 6) Logical Operators Operator Meaning Example ! NOT If (!found) double and symbol AND If (x less than symbol 3 double and symbol || OR If (age less than symbol 2 || height less than symbol 4) Connected to Boolean Expressions Assignment Operators Operator Example Meaning = x equal symbol 2 Simple assignment += X += 4 X = x+4 -= Y -= 6 Y = y -6 *= P *= 5 P = p*5 /= n/=10 N = n/10 %= N %= 10 N = Increment and Decrement Operators Operator Example Meaning ++ I++ or ++i I is incremented by 1 -- K-- or --k K is decremented by 1 Operator Precedence highest to lowest !, ++, -- *, /, % +,- less than symbol,greater than symbol,greater than or equal to symbol,less than or equal to symbol double equal symbol,!= double and symbol || =, +=, -=, *=, /=, %= Input/output: IMPORTANT NOTES 1.System.out prints the output on a displayed line 2.Print.ln outputs result, then moves to the next line. 3.Input is given by the user’s choice. 4.Output items include strings, boolean values, or a number. 5.Use toString() when attempting to print user input data 6.Escape Sequence is a letter, with a backlash behind it, to print special output. Storage of numbers: Binary and hexadecimal numbers: Hexadecimal Number:An exponent that uses an exponent base of 16 instead of the usual 10. Binary Number: A number represented as 0 or 1. Control structures: Two types: decision making and iteration Decision-Making: boolean expression, if, if else, switch If Statement: If (boolean) { Statement } The if else statement: If (boolean) { Statement } Else { Statements } Nested if statement: if in an if statement Iteration: for, while, and do while loop For loop: for( some condition) { Statements } For-each loop: for(some element) { Statements } The while loop while(boolean test) { Statements } Errors and exceptions: Exception:When an error occurs during the process of the code. TYPES OF EXCEPTION Unchecked Exception:When you do not get ready to advise the error that might occur by implementing the correct code. Checked Exception:When code is given to advise the exception, but an unexpected error occurs.
Toggle Menu


Professional Projects
- I'm working on Storm Impact Analytics, a machine-learning-driven tool to help utilities know much damage a storm is likely to cause
- I built a lot of Advantage Acre, a django-backed tool to help farmers make better data-driven decisions


--- layout: post title: Tell me about couples and surfing! date: 2006-05-31 00:00:00 categories: interfaces-&-interaction personal social ---
Tell me about couples and surfing!: "I know that I don't really watch TV any more. I'm online all the time. But whereas a couple watching TV, curled up on a sofa together, may have felt "together", a couple surfing on two wifi laptops are visiting different sites, having different experiences. They seem more apart than together. The internet age feels less communal than the TV age did."
Cough, cough.