iOS开发总结-搜索功能实现--使用SKTag
TagsTableViewController.h 文件 #import <UIKit/UIKit.h>
#import "personSearch.h" @interface TagsTableViewController : UITableViewController<UITableViewDataSource,UITableViewDelegate> @property (nonatomic,retain) personSearch *searchBar; @property (nonatomic, strong) NSString *key; @end TagsTableViewController.m 文件 #import "TagsTableViewController.h"
#import "TagsTableCell.h"
#import "SKTagView.h"
#import "SKTagButton.h"
#import "FTMacro.h"
#import "SearchResultViewController.h"
#import "DBStrore.h"
#import "Utilities.h"
//#import "guideInfoViewController.h"
//#import "reviewInfoViewController.h"
//#import "mShopInfoViewController.h"
//#import "tempModel.h"
#import "BaseSVRRequestOperator.h"
//#import "pointRuleViewController.h"
//#import "ALBBTradeObject.h"
#import "HttpConnect.h"
#import "PicViewController.h" #define SCREEN_WIDTH ([UIScreen mainScreen].bounds.size.width)
//Cell
static NSString *const kTagsTableCellReuseIdentifier = @"TagsTableCell"; @interface UIImage (SKTagView)
+ (UIImage *)imageWithColor:(UIColor *)color;
@end @interface TagsTableViewController ()<UISearchBarDelegate,SearchResultViewControllerDelegate> @property (nonatomic, strong) SearchResultViewController *searchResultView;
@property (nonatomic, strong) NSMutableArray *hotKeyArray;
@property (nonatomic, strong) NSMutableArray *historySearchArray; @property (nonatomic, strong) NSMutableArray *guideArray;
@property (nonatomic, strong) NSMutableArray *shopArray; @property (nonatomic, strong) BaseSVRRequestOperator *netWorking;
@property (strong, nonatomic) UIButton *mLookPicButton;
@end @implementation TagsTableViewController - (void)viewDidLoad
{
[super viewDidLoad];
NSLog(@"TagsTableViewController viewDidLoad ...");
self.view.backgroundColor =[UIColor colorWithRed:1.00 green:1.00 blue:1.00 alpha:1.00];
self.hotKeyArray = [[NSMutableArray alloc] init]; self.netWorking = [BaseSVRRequestOperator new];
self.guideArray = [NSMutableArray new];
self.shopArray = [NSMutableArray new]; [self initLeftBarButtonItem];
/*
[self initRightBarButtonItem000];
[self searchBarInit000];
*/
[self initRightBarButtonItem];
[self searchBarInit]; [self setHeadView]; if([DBStrore sharedDBStore].HistorySearchArray.count > )
{
self.historySearchArray = [[NSMutableArray alloc] initWithArray:[DBStrore sharedDBStore].HistorySearchArray];
}
else
{
self.historySearchArray = [NSMutableArray new];
} if([DBStrore sharedDBStore].hotKeyArray.count > )
{
self.hotKeyArray = [DBStrore sharedDBStore].hotKeyArray;
}
else
{
[self getHotSearchKeyword]; } [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(hideBarSearch:) name:@"hideBarSearch" object:nil]; [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(freshCapPicCount:) name:@"freshCapPicCount" object:nil];
} - (void)hideBarSearch:(id)notification
{
[self.searchBar resignFirstResponder];
} - (void)setHeadView
{
} - (void)detailBtn
{
[self.searchBar resignFirstResponder];
} - (void)viewWillAppear:(BOOL)animated
{
[super viewWillAppear:YES];
self.navigationController.navigationBarHidden = NO;
//开启定时器
// [scrollView.myTimer setFireDate:[NSDate distantPast]];
NSLog(@"search viewWillAppear:%d",[DBStrore sharedDBStore].CapPicArray.count);
[_mLookPicButton setTitle:[NSString stringWithFormat:@"对比(%d)",[DBStrore sharedDBStore].CapPicArray.count] forState: UIControlStateNormal];
} - (void)lookPicBtnClick
{
PicViewController *picVC = (PicViewController *)[[UIStoryboard storyboardWithName:@"picview" bundle:nil] instantiateViewControllerWithIdentifier:@"PicViewController"]; [self.navigationController pushViewController:picVC animated:YES]; } -(void) freshCapPicCount:(NSNotification*)notify
{
NSLog(@"search view freshCapPicCount:%d",[DBStrore sharedDBStore].CapPicArray.count);
[_mLookPicButton setTitle:[NSString stringWithFormat:@"对比(%d)",[DBStrore sharedDBStore].CapPicArray.count] forState: UIControlStateNormal];
} //导航栏左边按钮
- (void)initLeftBarButtonItem
{
NSLog(@"返回"); UIButton *backimgbtn = [[UIButton alloc] initWithFrame:CGRectMake(,,,)];
[backimgbtn setImage:[UIImage imageNamed:@"back_b.png"]forState:UIControlStateNormal];
[backimgbtn setContentHorizontalAlignment:UIControlContentHorizontalAlignmentLeft];
[backimgbtn setContentVerticalAlignment:UIControlContentVerticalAlignmentCenter];
backimgbtn.backgroundColor = [UIColor clearColor];
[backimgbtn setTitleColor:[UIColor redColor]forState:UIControlStateNormal];
backimgbtn.titleLabel.font = [UIFont systemFontOfSize: 15.0];
[backimgbtn addTarget:self action:@selector(cancelNav) forControlEvents:UIControlEventTouchUpInside]; UIButton *leftButton = [UIButton buttonWithType:UIButtonTypeCustom];
[leftButton setTitle:@"返回" forState:UIControlStateNormal];
[leftButton setTitle:@"返回" forState:UIControlStateHighlighted];
[leftButton setContentHorizontalAlignment:UIControlContentHorizontalAlignmentLeft];
[leftButton setContentVerticalAlignment:UIControlContentVerticalAlignmentCenter];
[leftButton setTitleColor:self.view.tintColor forState:UIControlStateNormal];
leftButton.titleLabel.font = [UIFont systemFontOfSize:];
[leftButton addTarget:self action:@selector(cancelNav) forControlEvents:UIControlEventTouchUpInside];
[leftButton setFrame:CGRectMake(,,,)]; UIView *leftView = [[UIView alloc] initWithFrame:CGRectMake(, , , )]; [leftView addSubview:backimgbtn];
[leftView addSubview:leftButton]; UIBarButtonItem *leftBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:leftView]; if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0)
{
UIBarButtonItem *negativeSeperator = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil];
negativeSeperator.width = -;
[self.navigationItem setLeftBarButtonItems:@[negativeSeperator, leftBarButtonItem]];
}
else
{
[self.navigationItem setLeftBarButtonItem:leftBarButtonItem animated:NO];
} }
//导航栏右边按钮
- (void)initRightBarButtonItem
{
NSLog(@"对比");
UIButton *rightButton = [UIButton buttonWithType:UIButtonTypeCustom];
[rightButton setTitle:@"对比(..)" forState:UIControlStateNormal];
[rightButton setContentHorizontalAlignment:UIControlContentHorizontalAlignmentCenter];
[rightButton setTitleColor:self.view.tintColor forState:UIControlStateNormal];
rightButton.titleLabel.font = [UIFont systemFontOfSize:];
[rightButton addTarget:self action:@selector(lookPicBtnClick) forControlEvents:UIControlEventTouchUpInside];
[rightButton setFrame:CGRectMake(, , , )];
UIBarButtonItem *rightBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:rightButton]; if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0)
{
UIBarButtonItem *negativeSeperator = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemFixedSpace target:nil action:nil];
negativeSeperator.width = -;
[self.navigationItem setRightBarButtonItems:@[negativeSeperator, rightBarButtonItem]];
}
else
{
[self.navigationItem setRightBarButtonItem:rightBarButtonItem animated:NO];
}
_mLookPicButton=rightButton; /*
[self.navigationItem setLeftBarButtonItem:nil];
UIButton *leftButton = [UIButton buttonWithType:UIButtonTypeCustom];
[leftButton setFrame:CGRectMake(0, 0, 0, 0)];
// [leftButton setBackgroundImage:[UIImage imageNamed:@""] forState:UIControlStateNormal];
UIBarButtonItem *leftBarButtonItem = [[UIBarButtonItem alloc] initWithCustomView:leftButton];
[self.navigationItem setLeftBarButtonItem:leftBarButtonItem];
*/
} //初始化搜索栏
- (void)searchBarInit { UIView *searchView = [[UIView alloc] initWithFrame:CGRectMake(, , kScreenWidth - , )];
searchView.backgroundColor = [UIColor clearColor]; self.searchBar = [[personSearch alloc] initWithFrame:CGRectMake(, , searchView.frame.size.width, searchView.frame.size.height)];
self.searchBar.backgroundColor = [UIColor clearColor];
self.searchBar.showsScopeBar = NO;
if(IsiOS8Later)
{
self.searchBar.returnKeyType = UIReturnKeySearch;
}
self.searchBar.delegate = self;
[self.searchBar becomeFirstResponder];
[searchView addSubview:self.searchBar]; self.navigationItem.titleView = searchView; } - (void)cancelNav{
[self.searchBar resignFirstResponder];
[[NSNotificationCenter defaultCenter] removeObserver:self];
[self.navigationController popViewControllerAnimated:YES];
} - (void)cleanHis:(id)sender{ [self.historySearchArray removeAllObjects];
[[DBStrore sharedDBStore].HistorySearchSet removeAllObjects];
[[DBStrore sharedDBStore].HistorySearchArray removeAllObjects];
[self.tableView reloadData]; [self saveSearchHistory]; }
- (void)getHotSearchKeyword
{
HttpConnect * connect = [[HttpConnect alloc] init];
connect.delegate = self;
// NSNumber *lastid = [NSNumber numberWithInt:self.last_id];
NSMutableDictionary * dic = [NSMutableDictionary dictionary];
// [dic setObject:lastid forKey:@"lastid"]; [connect postRequestForPostValue:dic url:@"gethotkey.php" requestTag:]; }
-(void)postRequestStarted:(AFHTTPRequestOperation*)request manage:(AFHTTPRequestOperationManager*)manage{ NSLog(@"REQ START");
}
// 从服务器取热门搜索关键字的回调
-(void)postRequestFinished:(AFHTTPRequestOperation*)request manage:(AFHTTPRequestOperationManager*)manage{ NSLog(@"REQ FINISHED"); NSDictionary * dictionary = [NSJSONSerialization JSONObjectWithData:request.responseData options:NSJSONReadingMutableLeaves error:nil ];
NSString * status = [NSString stringWithFormat:@"%@",[dictionary objectForKey:@"status"]];
// NSLog(@"status=%@",status);
if([status isEqualToString: @""]){
NSArray *dataArray = [request.responseObject objectForKey:@"data"];
NSLog(@"count=%d",dataArray.count);
if(dataArray)
{
for(int i=;i<dataArray.count;i++)
{
[self.hotKeyArray addObject:[dataArray objectAtIndex:i]];
}
} [self.tableView reloadData]; [DBStrore sharedDBStore].hotKeyArray = self.hotKeyArray; }
}
-(void)postRequestFailed:(AFHTTPRequestOperation*)request manage:(AFHTTPRequestOperationManager*)manage{ NSLog(@"REQ FAILED");
// [self.view addSubview:[CustomAlertView alertWith:@"0" message:NSLocalizedString(@"error", @"错误")]];
} #pragma mark - UISearchBar delegate
- (void)searchBarTextDidBeginEditing:(UISearchBar *)searchBar
{
NSLog(@"searchBarTextDidBeginEditing");
[self.searchBar becomeFirstResponder];
} - (void)searchBarTextDidEndEditing:(UISearchBar *)searchBar
{
NSLog(@"searchBarTextDidEndEditing");
[self.searchBar resignFirstResponder];
} - (void)searchBarSearchButtonClicked:(UISearchBar *)searchBar
{
NSLog(@"searchBarSearchButtonClicked");
[self.searchBar resignFirstResponder];
[self starSearch:self.searchBar.text];
}
//
- (void)starSearch:(NSString *)key
{ if(key.length > )
{
key = [NSString stringWithFormat:@"%@...",[key substringToIndex:]];
} if (![[DBStrore sharedDBStore].HistorySearchSet containsObject:key]) { if([DBStrore sharedDBStore].HistorySearchArray.count == )
{
NSString *name = [DBStrore sharedDBStore].HistorySearchArray[];
[[DBStrore sharedDBStore].HistorySearchSet removeObject:name];
[[DBStrore sharedDBStore].HistorySearchArray removeObjectAtIndex:];
[self.historySearchArray removeObjectAtIndex:];
} [[DBStrore sharedDBStore].HistorySearchSet addObject:key];
[[DBStrore sharedDBStore].HistorySearchArray insertObject:key atIndex:];
[self.historySearchArray insertObject:key atIndex:]; [self saveSearchHistory]; [self.tableView reloadData]; } [self getSearchMessage:key];
} - (void)saveSearchHistory
{
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSData *bindUserLocalSettingDictionaryData = [NSKeyedArchiver archivedDataWithRootObject:[DBStrore sharedDBStore].HistorySearchArray];
[defaults setObject:bindUserLocalSettingDictionaryData forKey:FTsearchHistory];
[defaults synchronize]; } - (void)getSearchMessage:(NSString *)keyName
{ [DBStrore sharedDBStore].searchKey = keyName; [self.hotKeyArray removeAllObjects];
self.tableView.tableHeaderView = nil;
[self.tableView reloadData]; if(!self.searchResultView)
{
self.searchResultView = [[SearchResultViewController alloc] initWithNibName:@"SearchResultViewController" bundle:nil];
self.searchResultView.view.frame = CGRectMake(, , kScreenWidth, kScreenHeight - );
self.searchResultView.delegate = self;
[self.view addSubview:self.searchResultView.view]; } [self.searchResultView getSearchListByKey:keyName]; } - (void)scrollViewDidScroll:(UIScrollView *)scrollView
{
[self.searchBar resignFirstResponder];
} #pragma mark - Table view data source
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
return ;
} - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView{ if(self.hotKeyArray.count > )
{
return ;
}
else
{
return ;
} } - (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{ UIView *view = [[UIView alloc] initWithFrame:CGRectMake(, , SCREEN_WIDTH, )];
view.backgroundColor = [UIColor clearColor];
UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(, , SCREEN_WIDTH-, )];
label.textColor = [UIColor colorWithRed:0.77 green:0.77 blue:0.78 alpha:1.00];
if (section == ) { if(self.historySearchArray.count > )
{
label.text = @"历史搜索";
} }else{ if(self.hotKeyArray.count > )
{
label.text = @"热门搜索";
} }
[view addSubview:label]; return view;
} - (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section{
UIView *view = [[UIView alloc] initWithFrame:CGRectMake(, , SCREEN_WIDTH, )];
view.backgroundColor = [UIColor clearColor];
if (section == ) {
return view;
} if(self.historySearchArray.count > )
{
UIButton *button = [[UIButton alloc] initWithFrame:CGRectMake(, , , )];
button.layer.cornerRadius = ;
button.layer.borderWidth = 0.5;
button.layer.borderColor = [UIColor lightGrayColor].CGColor;
[button setTitleColor:[UIColor colorWithRed:0.98 green:0.32 blue:0.32 alpha:1.00] forState:UIControlStateNormal];
[button setTitle:@"清除历史记录" forState:UIControlStateNormal];
[button addTarget:self action:@selector(cleanHis:) forControlEvents:UIControlEventTouchUpInside];
[button.titleLabel setFont:[UIFont systemFontOfSize:]];
[button setBackgroundColor:[UIColor whiteColor]];
[button setImage:[UIImage imageNamed:@"clear"] forState:UIControlStateNormal]; [view addSubview:button];
} return view;
} - (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
return ;
} - (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
if(section == ){
return ;
}
return ;
} - (void)configureCell:(TagsTableCell *)cell atIndexPath:(NSIndexPath *)indexPath
{
cell.tagView.preferredMaxLayoutWidth = SCREEN_WIDTH;
cell.tagView.padding = UIEdgeInsetsMake(, , , );
cell.tagView.insets = ;
cell.tagView.lineSpace = ; [cell.tagView removeAllTags]; NSArray *array = nil;
if(indexPath.section == ){
array = self.historySearchArray;
}
else
{
array = self.hotKeyArray;
} //Add Tags
[array enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop)
{
SKTag *tag = [SKTag tagWithText:obj];
tag.textColor = [UIColor blackColor];
tag.fontSize = ;
tag.padding = UIEdgeInsetsMake(, , , );
tag.bgImg = [UIImage imageWithColor:[UIColor clearColor]];
tag.cornerRadius = ;
tag.borderColor = [UIColor colorWithRed:0.89 green:0.89 blue:0.89 alpha:1.00];
tag.borderWidth = ;
tag.tag = idx;
[cell.tagView addTag:tag];
}];
cell.tagView.backgroundColor = [UIColor clearColor];
cell.backgroundColor = [UIColor clearColor];
cell.tagView.tag = indexPath.section;
__weak TagsTableViewController *weakSelf = self;
cell.tagView.didClickTagAtIndex = ^(NSUInteger index,NSUInteger tag){
[weakSelf handleBtn:tag index:index];
}; } - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
TagsTableCell *cell = [tableView dequeueReusableCellWithIdentifier:kTagsTableCellReuseIdentifier forIndexPath:indexPath];
[self configureCell:cell atIndexPath:indexPath]; return cell;
} #pragma mark - Table view delegate
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
TagsTableCell *cell = nil;
if (!cell)
{
cell = [tableView dequeueReusableCellWithIdentifier:kTagsTableCellReuseIdentifier];
cell.selectionStyle = UITableViewCellSelectionStyleNone;
} [self configureCell:cell atIndexPath:indexPath];
return [cell.contentView systemLayoutSizeFittingSize:UILayoutFittingCompressedSize].height + ;
} - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
[tableView deselectRowAtIndexPath:indexPath animated:YES];
} #pragma mark - User interactions
//写点击事件。。。
- (void)handleBtn:(NSUInteger)section index:(NSUInteger)index
{
NSString *searchName = nil;
if(section == )
{
searchName = self.hotKeyArray[index];
}
else
{
searchName = self.historySearchArray[index];
} self.searchBar.text = searchName;
[self.searchBar resignFirstResponder]; [self starSearch:searchName];
} @end @implementation UIImage (SKTagView) + (UIImage *)imageWithColor:(UIColor *)color
{
CGRect rect = CGRectMake(0.0f, 0.0f, 1.0f, 1.0f);
UIGraphicsBeginImageContext(rect.size);
CGContextRef context = UIGraphicsGetCurrentContext(); CGContextSetFillColorWithColor(context, [color CGColor]);
CGContextFillRect(context, rect); UIImage *image = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext(); return image;
} @end
加扣群385378208即可下载工程源码,先看群信息
iOS开发总结-搜索功能实现--使用SKTag的更多相关文章
- IOS开发之支付功能概述
前言:本随笔将对IOS开发的支付功能进行一个概述. 内容大纲: 一.常见的支付方案简介 二.第三方支付SDK 三.苹果官方支付方案 四.Web支付方案 正文: 一.常见的支付方案简介 在微信支付中 微 ...
- Yii 1开发日记 -- 搜索功能及Checkbox的实现
用yii 1实现后台的搜索功能,效果如下图: 1.模型中: public function search() { $criteria = new CDbCriteria; //独立高级搜索 if(is ...
- ios开发之--搜索框的使用(PYSearchViewController的使用)
最近需要开发搜索框,比较了以前的各个版本的搜索框,UISearchDisplayController和UISearchController的使用,以后再做记录,随着ios11的更新,一些控件发生了,改 ...
- iOS开发之语音功能实现
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launc ...
- 【IOS开发】搜索和排序(好友列表,通讯录的实现,searchbar)
一.效果图: 二.概述 实现一个好友列表,可以分为男女两个选项,并且实现搜索和排序功能.我的数据是放在plist文件中. 三.代码简述 代码结构如图,首先自定义一个Cell. cell.h #impo ...
- iOS开发: 向右滑动手势功能实现
在navigationController中实现向右滑动 返回功能 系统提供的backbarbuttonitem,不用添加任何代码即可实现向右滑动后退功能,但是往往要对按钮修改样式等时,就需要自定义l ...
- iOS开发-清理缓存功能的实现
移动应用在处理网络资源时,一般都会做离线缓存处理,其中以图片缓存最为典型,其中很流行的离线缓存框架为SDWebImage. 但是,离线缓存会占用手机存储空间,所以缓存清理功能基本成为资讯.购物.阅读类 ...
- iOS开发系统类功能划分
0.OC语法基础 CHOCBase Object C语法学习笔记(一) Object C语法学习笔记(二) 1.UI类 自定义控件程序运行流程 setNeedsLayOut和setNeedsDispl ...
- iOS开发打电话的功能
1,这种方法,拨打完电话回不到原来的应用,会停留在通讯录里,而且是直接拨打,不弹出提示 NSMutableString * phoneStr=[[NSMutableString alloc] init ...
随机推荐
- Ext.Array 方法
1. Ext.Array.clean(arr); 过滤数组中的空元素 var arr = [1,"",2,"",3]; Ext.clean(arr); // [ ...
- 17173php招聘
学历要求:大专工作经历:4年↑薪资待遇:面议工作地点:北京市 资深PHP工程师岗位职责\\\"1.独立负责公司互联网产品的开发与测试2.主导负责相关系统维护,确保系统运行稳定可靠3.主导推动 ...
- Android 网络通信 HTTP
摘要 1. Http GET 方法访问网站 2. Http POST访问网站 3. HttpClient进行Get方式通信 4. HttpClient进行Post方式通信 -------------- ...
- uboot的mtd功能支持
一.概述 1.MTD MTD是Flash的一种管理方法,将Flash划分成几个分区,便于管理. u-boot的MTD功能是在文件cmd_jffs2.c中实现的,由此我们可以知道怎样打开u-boot的M ...
- encodeURL() vs encodeRedirectURL()
当用URL重写方式来管理Session的时候,通过以上两个方法把session ID写到URL中.不同点是:两个方法确定是否需要包含session ID的逻辑不同.在调用HttpServletResp ...
- Google提议使用Jsonnet来增强JSON
Google开源了一门配置语言Jsonnet来取代JSON,它完全向后兼容并加入了一些新特性:注释.引用.算术运算.条件操作符,数组和对象内含,引入,函数,局部变量,继承等.Jsonnet程序被翻译为 ...
- android的原理,为什么不需要手动关闭程序
转自android的原理,为什么不需要手动关闭程序 不用在意剩余内存的大小,其实很多人都是把使用其他系统的习惯带过来来了. Andoird大多应用没有退出的设计其实是有道理的,这和系统对进程的调度机制 ...
- 用 Webgoat 撬动地球,看安全测试的引路石!
测试工程师是很多人迈进软件行业的起点.从负责很小的局部到把握整个产品的质量,每个人花费的时间长短不一--从功能到性能.可用性到容错性.从兼容性到扩展性.稳定性到健壮性--方方面面逐渐做广做深. 不过, ...
- 提升 DevOps 效率,试试 ChatOps 吧!
本文翻译自文章 To Boost DevOps, Try ChatOps,文中用简单易懂的方式介绍了 ChatOps 的发展和价值,由 OneAPM 工程师编译整理. 当我们谈论 DevOps 时,总 ...
- 使用mysql-proxy代理实现msyql数据库读写分离
要实现读写分离,可以先看看如何实现mysql数据库主从:http://www.cnblogs.com/sustudy/p/4174189.html mysql-proxy下载地址(要看好对应版本):h ...